August 26, 2019

Linear Algebra and Optimization- MCQS

Note: We have tried to upload as much as we can, all the question and answers might be shuffled - Please find the answer below each question, some answers might be wrong please review on the last date(some answers might be changed) if you find any of the answer is wrong please comment down below. 


Question 1:
When using a graphical solution procedure, the region bounded by the set of constraints is called the
Select one:
A.feasible region
B.infeasible region
C.maximum profit region
D.none of the above
Correct Answer is : A

Question 2:
An LP problem has a bounded feasible region. If this problem has an equality constraint, then
Select one:
A.this must be a minimization problem
B.the feasible region must consist of a line segment
C.the problem must be degenerate
D.the problem must have more than one optimal solution
Correct Answer is : B

Question 3:
If two constraints do not intersect in the positive quadrant of the graph, then
Select one:
A.The Problem is infeasible
B.The solution is unbounded
C.One of the constraints is redundant.
D.The solution is optimal
Correct Answer is : A

Question 4:
For a maximization problem, the coefficient for an artificial variable in the objective function while using two phase simplex method is
Select one:
A.+1
B.-1
C.+M
D.–M
Correct Answer is : B

Question 5:
When alternate optimal solutions exist in an LP problem, then
Select one:
A.the objective function will be parallel to one of the constraints
B.one of the constraints will be redundant
C.two constraints will be parallel
D.the problem will also be unbounded
Correct Answer is : A

Question 6:
A optimum solution to an LP problem
Select one:
A.Must satisfy all of the problem’s constraints simultaneously
B.Need not satisfy all of the constraints, only some of them
C.Must be corner point of the feasible region
D.Must optimize the value of the objective function
Correct Answer is :  D

Question 7:
If the constraint has ‘≥’ sign, then we introduce
Select one:
A.Surplus variable
B.Slack variable
C.artificial variable
D.Slack and surplus variables
Correct Answer is : A

Question 8:
If the feasible region gets larger due to a change in one of the constraints, the optimal value of the objective function
Select one:
A.must increase or remain the same for a maximization problem
B.must decrease or remain the same for a maximization problem
C.must increase or remain the same for a minimization problem
D.cannot change
Correct Answer is : A

Question 9:
If there is no feasible region in a LPP, then we say that the problem has
Select one:
A.Infinite solution
B.No solution
C.Unbounded solution
D.None of these
Correct Answer is : B

Question 10:
A graphical method should only be used to solve an LP problem when
Select one:
A.there are only two constraints
B.there are more than two constraints
C.there are only two variables
D.there are more than two variables
Correct Answer is : C

Question 11:
Which of the following is true with respect to the optimal solution of an LPP
Select one:
A.Every LPP has an optimal solution
B.Optimal solution of an LPP always occurs at an extreme point
C.At optimal solution all resources are used completely
D.If an optimal solution exists, there will always be at least one at a corner
Correct Answer is : D

Question 12:
If a linear program is unbounded, the problem probably has not been formulated correctly. Which of the following would most likely cause this?
Select one:
A.a constraint was inadvertently omitted
B.an unnecessary constraint was added to the problem
C.the objective function coefficients are too large
D.the objective function coefficients are too small
Correct Answer is : A

Question 13:
A linear program has been solved and sensitivity analysis has been performed. The ranges for the objective function coefficients have been found. For the profit on the upper bound is 80, the lower bound is 60, and the current value is 75. Which of the following must be true if the profit on this  variable is lowered to 70 and the optimal? Solution is found?
Select one:
A.a new corner point will become optimal
B.the maximum possible total profit may increase
C.the values for all the decision variables will remain the same
D.all of the above are possible
Correct Answer is : C

Question 14:
Maximize z = 3x + 4y subject to the constraints: 4x + 2y  80 , 2x + 5y  180 , x , y ≥ 0
Select one:
A.0 at (0, 0)
B.180 at (20, 30)
C.115 at (35, 2.5)
D.147.5 at (2.5, 35)
Correct Answer is : D

Question 15:
Which of the following would cause a change in the feasible region?
Select one:
A.increasing an objective function coefficient in a maximization problem
B.adding a redundant constraint
C.changing the right-hand side of a no redundant constraint
D.increasing an objective function coefficient in a minimization problem
Correct Answer is : C

Question 16:
A constraint that does not affect the feasible solution is a
Select one:
A.non-negative constraint
B.a redundant constraint
C.standard constraint
D.slack constraint
Correct Answer is : B

Question 17:
Which of the following is a valid objective function for  LPP?
Select one:
A.maximize 6xyz
B.maximize  3x +4y – z
C.minimize 5x2+7y3
D.none of these
Correct Answer is : B

Question 18:
In the optimal solution to a linear program, there are 20 units of slack for a constraint. From this we know that
Select one:
A.the dual price for this constraint is 20
B.the dual price for this constraint is 0
C.this constraint must be redundant
D.the problem must be a maximization problem
Correct Answer is : B

Question 19:
Lower and upper bounds in case of an unbounded variable is
Select one:
A.0 and ∞
B.– ∞ and 
C.0 and - ∞
D.none of these
Correct Answer is : A

Question 20:
Mathematical model of LP problem is important because
Select one:
A.It helps in converting the verbal description and numerical data into mathematical expression
B.Decision – makers prefer to work with formal models
C.It captures the relevant relationship among decision factors
D.It enables the use of algebraic techniques
Correct Answer is : A

Question 21:
From a set of equations x + 4y – z = 3 and 5x + 2y + 3z = 4 the basic feasible solution involving x, y is
Select one:
A.(5/9, 11/18, 0)
B.(5/9, 0, 0)
C.(0, 11/18, 0)
D.none of these
Correct Answer is : A

Question 22:
If a negative value appears in the solution values column of the simplex table, then
Select one:
A.the solution is optimal
B.the solution is infeasible
C.the solution is unbounded
D.all of the above
Correct Answer is : C

Question 23:
In solving a linear program, no feasible solution exists. To resolve this problem we might
Select one:
A.add another variable
B.add another constraint
C.remove or relax a constraint
D.try a different computer program
Correct Answer is : C

Question 24:
In LP, variables do not have to be integer valued and may take on any fractional value This assumption is called
Select one:
A.proportionality
B.divisibility
C.additivity
D.certainty
Correct Answer is : B

Question 25:
The role of artificial variable in the simplex method is
Select one:
A.To find optimal dual prices in the final simplex table
B.to start phases of simple method
C.to aid in finding an initial solution
D.convert inequality constraints into equality
Correct Answer is : C

Question 26:
Which of the following subroutines does a computer implementation in LPP by the simplex method use?
Select one:
A.Finding a root of a polynomial
B.Finding the determinant of a matrix
C.Finding the Eigen value of a matrix
D.Solving a system of linear equations
Correct Answer is : D

Question 27:
A feasible solution to an LP problem
Select one:
A.must satisfy all of the problem’s constraints simultaneously.
B.need not satisfy all of the constraints, only some of them
C.must be a corner point of the feasible region
D.must give the maximum possible profit
Correct Answer is : A

Question 28:
Let S1- The slack and surplus variables can be unrestricted in sign
S2 – A basic feasible solution cannot have zero value for any of the variables
Select one:
A.S1 – True, S2 – True
B.S1 – False, S2 - True
C.S1 – True, S2 – False
D.S1 – False, S2 – False
Correct Answer is : D

Question 29:
If dual has an unbounded solution, primal has
Select one:
A.Unbounded solution
B.Feasible solution
C.Infeasible solution
D.Optimum solution
Correct Answer is : C

Question 30:
If a non redundant constraint is removed from an LP problem, then
Select one:
A.the feasible region will get larger
B.the feasible region will get smaller
C.the problem would become nonlinear
D.the problem would become infeasible
Correct Answer is : A


Digital Electronics and Microprocessors - MCQS



Note: We have tried to upload as much as we can, all the question and answers might be shuffled - Please find the answer below each question, some answers might be wrong please review on the last date(some answers might be changed) if you find any of the answer is wrong please comment down below. 

Question 1
DMA interface unit eliminates the need to use CPU registers to transfer data From
(A)  MAR to MBR (B) MBR to MAR (C) I/O units to memory (D) Memory to I/O units
Select one:
a. c
b. a
c. b
d. d
Correct Answer: D

Question 2
Out of the 4 operations listed below , which do you find not to be taking place during the execution cycle?
(A) ALU performs the arithmetic & logical operation.
(B) Effective address is calculated.
(C) Next instruction is fetched.
(D) Branch address is calculated & Branching conditions are checked.
Select one:
a. a
b. c
c. b
d. d
Correct Answer: D

Question 3
For an 8086 find the physical memory address of the data stored in following memory locations
DS: BX   = 1000h:1200h
A. 11200 H   B. 13000H   C.  2200H     D. 22000H
Select one:
a. c
b. d
c. a
d. b
Correct Answer: C

Question 4
How many (128 x 8) RAM chips are needed to provide a memory capacity of
2048 X 16 ?
(A)  8 (B) 16 (C) 24 (D) 32
Select one:
a. a
b. c
c. b
d. d
Correct Answer: D

Question 5
1.If In addition of two signed numbers, represented in 2' s complement, A is the carry in to the sign bit position and B is the carry out of the Sign bit position then what logic will show an overflow condition?
(A)  A. B = 0 (B) A = 0 (C) A xor B = 1 (D) A + B = 1
Select one:
a. d
b. b
c. c
d. a
Correct Answer: C

Question 6
1.How many flip-flops are required for a divide by 32 counter?
A.3 B. 4 C.32 D.5
Select one:
a. a
b. b
c. d
d. c
Correct Answer: C

Question 7
A JK flip-flop can be implemented using D flip-flop connected such that
(A)D=JQ’+K’Q (B) D=J'Q+KQ (C)D=JQ+K'Q' (D) D=JQ+KQ'
Select one:
a. c
b. b
c. d
d. a
Correct Answer: D

Question 8
What will be the ending addresses of a 64 K Byte memory segment as in 8086 if the segment register contains AB11H
A. DCBF0H  B. ABBA0H  C. BB10F H  D. AB110H
Select one:
a. c
b. b
c. a
d. d
Correct Answer: C

Question 9
How does the CMP B instruction affect the flags? chose the best option
A. Only sign flag affected   B. Only Carry flag affected   C. All flags affected   D. None of the flags affected
Select one:
a. d
b. b
c. c
d. a
Correct Answer: C

Question 10
For 8086 What will be the content of Accumulator and the carry flag after executing the instruction RAR if the accumulator and carry flag contained  10100111 & 0 respectively before executing the instruction
A.11010011 & 1         B. 01010011 & 0
C.01010011 & 1         D.  11010011 & 0
Select one:
a. d
b. c
c. b
d. a
Correct Answer: B

Question 11
What are the basic steps for the execution of an instruction?
A.Fetch, Decode, Execute         B. Decode, Fetch, Execute
C.Decode, Execute, Fetch         D. Execute Decode, Fetch,
Select one:
a. c
b. a
c. d
d. b
Correct Answer: B

Question 12
For 8086  What is the length of the instruction POP D
A.4 Byte        B. 3 Byte
C.1 Byte        D. 2 Byte
Select one:
a. a
b. d
c. b
d. c
Correct Answer: D

Question 13
What register is used for reading status of  Flag Registers?
A. Flag Register        B. Status Register
C. Control register     D. Buffer Register
Select one:
a. a
b. b
c. d
d. c
Correct Answer: B

Question 14
IMUL is
A.Signed  Multiplication         B. Unsigned  Multiplication
C.Multiplication                 D. Inverse Multiplication
Select one:
a. b
b. d
c. c
d. a
Correct Answer: D


Computer Programming - MCQS

Note: We have tried to upload as much as we can, all the question and answers might be shuffled - Please find the answer below each question, some answers might be wrong please review on the last date(some answers might be changed) if you find any wrong answer please comment down below.


Question 1
Which among the following is not an usage of structure?
Select one:
A. Changing the size of the cursor
B. Receiving a key from the keyboard
C. Placing the cursor at an appropriate position on screen
D. Drawing any graphics shape on the screen
E. None of the options
Correct Answer: E

Question 2
#include <stdio.h>
struct sample
{
                int a=0;
                char b='A';
                float c=10.5;
};
int main()
{
                struct sample s;
                printf("%d,%c,%f",s.a,s.b,s.c);
                return 0;
}
Select one:
A. No Error, No Output
B. 0, A, 10.5
C. Error
D. 0, A, 10.500000
Correct Answer: C

Question 3
What will be the output of the program ?
#include<stdio.h>
#include<string.h>
int main()
{
    char str1[20] = "Hello", str2[20] = " Program";
    printf("%s\n", strcpy(str2, strcat(str1, str2)));
    return 0;
}
Select one:
A. ProgramHello
B. Program
C. Hello Program
D. Hello
Correct Answer: C

Question 4
What will be the output of the program?
#include<stdio.h>
int main()
{
    static char s[25] = "C-Programming-skills";
    int i=0;
    char ch;
    ch = s[++i];
    printf("%c", ch);
    ch = s[i++];
    printf("%c", ch);
    ch = i++[s];
    printf("%c", ch);
    ch = ++i[s];
    printf("%c", ch);
    return 0;
}
Select one:
A. --Ps
B. C--s
C. C-Pr
D. -Pro
Correct Answer: A

Question 5
Which among the following is true about srtcmpi()?
Select one:
A. Compares two strings
B. Compares two strings with regard to case
C. Compares first n characters of two strings
D. Compares two strings without regard to case
Correct Answer: D

Question 6
Can you combine the following two statements into one?
char *p;
p = (char*) malloc(100);
Select one:
A. char p = *malloc(100);
B. char *p = (char *)(malloc*)(100);
C. char *p = (char) malloc(100);
D. char *p = (char*)malloc(100)
Correct Answer: D

Question 7
# include <stdio.h>
void print(int arr[])
{
   int n = sizeof(arr)/sizeof(arr[0]);
   int i;
   for (i = 0; i < n; i++)
   printf("%d ", arr[i]);
}
int main()
{
   int arr[] = {4,5,7,1,2,6,7,8};
   print(arr);
   return 0;
}
Select one:
A. 4,5,7,1,2,6,7,8
B. Compile error
C. Run time error
D. 4 5
Correct Answer: D

Question 8
#include<stdio.h>
int i;
int fun();
int main()
{
    while(i)
    {
        fun();
        main();
    }
    printf("Hello");
    return 0;
}
int fun()
{
    printf("Hi");
}
Select one:
A. Infinite loop
B. Hello
C. No output
D. Hi Hello
Correct Answer: B

Question 9
#include&lt;stdio.h&gt;
void fun(int*, int*);
int main()
{
int i=5, j=2;
fun(&amp;i, &amp;j);
printf(&quot;%d, %d&quot;, i, j);
return 0;
}
void fun(int *i, int *j)
{
*i = *i**i;
*j = *j**j;
}
Select one:
A. 2, 5
B. 25, 4
C. 5, 2
D. 10, 4
Correct Answer: B

Question 10
Find the odd man out in the following:
Select one:
A. N[i]
B. *N+i
C. *(i+N)
D. *(N+i)
Correct Answer: B

Question 11
What will be the output of the program?
#include<stdio.h>
    struct course
    {
        int courseno;
        char coursename[25];
    };
int main()
{
    struct course c[] = { {102, "Ruby"},
                          {103, "Scala"},
                          {104, "Python"}     };
    printf("%d ", c[1].courseno);
    return 0;
}
Select one:
A. 104
B. 102
C. 103
D. Error
Correct Answer: C

Question 12
int main()
{
    int i;
    int arr[5] = {1};
    for (i = 0; i < 5; i++)
    printf("%d ", arr[i]);
    return 0;
}
Select one:
A. 11111
B. error
C. 10000
D. 00000
Correct Answer: C

Question 13
How will you free the allocated memory ?
Select one:
A. delete(var-name);
B. free(var-name);
C. remove(var-name);
D. dalloc(var-name);
Correct Answer: B

Question 14
___________is a macro which returns a 0 if end of file is not reached.
Select one:
A. Feof()
B. Ferror()
C. Fscanf()
D. Fprintf()
Correct Answer: A

Question 15
Can we receive input from keyboard for the array of pointers to strings?
Select one:
A. Yes
B. Rarely
C. No
D. May be
Correct Answer: C

Question 16
Accessing array elements by pointers is _____________ faster than accessing them
by subscripts.
Select one:
A. Not
B. Always
C. Sometimes
D. Probably
Correct Answer: B

Question 17
Which among the following is the drawback of putch, putchar, fputchar()?
Select one:
A. Outputs only one character at a time
B. None of the above
C. Comes out of the screen
D. Outputs more than one character at a time
Correct Answer: A

Question 18
What will be the output of the program?
#include<stdio.h>
#include<string.h>
int main()
{
    char sentence[80];
    int i;
    printf("Enter a line of text\n");
    gets(sentence);
    for(i=strlen(sentence)-1; i >=0; i--)
    putchar(sentence[i]);
    return 0;
}
Select one:
A. The sentence will get printed in same order as it entered
B. The sentence will get printed in reverse order
C. Half of the sentence will get printed
D. None of above
Correct Answer: B

Question 19
#include <stdio.h>
int main()
{
    int arr[10];
    // Assume that base address of arr is 4000 and size of integer
    // is 32 bit
    arr++;
    printf("%u", arr);
    return 0;
}
Select one:
A. 4020
B. 4002
C. lvalue required
D. 4004
Correct Answer: C
.
Question 20
What is the output of the following program?
int main()
{
    int i;
    int arr[4] = {0};
    for (i = 0; i <= 4; i++)
    printf("%d ", arr[i]);
    return 0;
}
Select one:
A. crash
B. prints 0 four times 1
C. Error
D. The program may print 0 four times followed by garbage value, or may crash if address (arr+5) is invalid.
Correct Answer: D


July 11, 2019

Software Architectures - Comprehensive Reference Solution

Question 
Choose the most appropriate architectural pattern (one) for the 5 descriptions below. Motivate for your choices (give reasons for choosing the pattern):
1. Wants to split a system into a number of computationally independent execution structures (groups of software and hardware) such as database, business logic, web interface and client, connected by some communication media. The structure is chosen to provide a specific server environment optimized for operational requirements and resource usage.

2. Wants to set up a set of equal distributed computational entities that are connected via a common protocol to share their services and provide high availability and scalability.

3. Wants a system that can be divided into reusable, loosely coupled components that can be flexibly combined and arranged to transform between various data formats.

4. Wants a distributed system with a structure that enables that service users do not need to know the nature or location of service providers.

5. Wants a system that quickly can analyze enormous volumes of data by sorting the data and then analyzing the grouped data.

Answer:
1 .Multi-tier
2. Peer-to-peer
3.Pipe-and-filter
4. Broker
5. Map-Reduce

Question
Present a general and a specific scalability requirement in the form of a Quality Attribute Scenario

Answer
A concrete scalability quality attribute scenario:

  • Source system owner 
  • Stimulus request to accommodate five times more concurrent users 
  • Artifact the main server cluster 
  • Environment normal operation 
  • Response increase the number of servers no more than sixfold, without recompiling the software 
  • Response measure performance as measured by average number of typical requests processed per minute may not drop more than 10%


Question 
In the Service Oriented Architecture style there is a strong decoupling between functionality and implementation, throughout the application life-cycle. Applications are built by combining or connecting services. Explain why and how this architecture facilitates
a. (1) reuse of existing software components;
b. (1) independent development.

Answer:
 In SOA, application components depend on each other only through the service interface. No details of an implementation may be used or be visible.
(a) There are two elements of reuse. Once a service (interface) is defined, the only thing that needs to be done to use an existing piece of software is to map the service interface to this software, typically by building an adapter. Secondly, services can be reused in many different applications since they do not contain knowledge about their application context. One remark on the latter is in place: a service may use other services.
(b) This relies on the same separation between service definition and implementation. By defining and using only the service interface, the implementation of the service becomes irrelevant for the service user. For example, by defining the UPnP interface, the implementation behind is it entirely invisible and can be developed by independent parties. One might also replace one implementation by the other.

Question
Read the description of the Cricket-Ticket system below and do an architectural design using the attribute-driven design (ADD) method.
Your answer should include: • Architectural drivers • Architectural tactics and patterns • A logical view • Interfaces • Verification of the architecture
Note that you should only describe the logical view and only do one level of decomposition!
Motivate for your choices and state your assumptions.

The Cricket-Ticket System (CTS) is a system where the users can buy tickets using credit cards to cricket matches in India over the Internet using a Web-browser. The user can look at information about future matches from cricket teams from all over India, and see if there are any available seats. The information about the cricket matches is retrieved from various servers with different interfaces provided by the different teams. Note that the teams in India will change every year. It is critical that the TSS is available to the users all the time, and it cannot be unavailable for more than 2 minutes a week. Before important games, such as Champion League games, it is important that the system does not break down even if over 40000 users try to get tickets at the same time

Answer:
Step 1. Choose module to decompose: The CTS

Step 2a. Choose architectural drivers: AD1: The system cannot be down more than 2 minutes a week (availability) AD2: The system should provide secure electronic payment (security) AD3: The system should be able to communicate with various team servers (modifiability) AD4: The system must handle 40,000 simultaneous users (performance)

Step 2b. Choose architectural patterns: Tactics for security: Firewall for server, autorize users, authenticate users, Payment handled by third-party and usage of secure connection (e.g. https) Tactics for modifiability: Divide the functionality into coherent units and plan for changeable interfaces for external systems. Tactics for performance: Use replication of the server to ensure support for many users, and cache data from team servers. Tactics for availability: Use replication of the server to cope with downtime.
Architectural patterns: Use a kind of a model-view controller pattern where the view and the controller is represented in the user interface part and the model is the database. Replication is used on server and database for higher performance and availability. Separation of concern is used to provide modifiability (separate core functionality and external interfaces), and a separate part dealing with secure computation and interfaces.

Step 2c. Instantiate Modules and Allocate Functionality Applied architectural patterns and instantiated functionality for match browsing, seats browsing, and ticket booking. Also added a data manager that takes care of caching of data from external systems (stored in database).

Step 2d. Define Interfaces of the Child Modules Interfaces between the server and the external parts of the system: • Between User interface and user clients: HTML over HTTP • Between External system interface and External Team server: XML over HTTP • Between Data manager and Database server: SQL over HTTP • Between Ticket payment and External payment service: encrypted binary over HTTPS Interfaces within the server: • The User interface class provides display methods that uses other classes: • displayMatch() • displaySeats() • displayBooking() The Ticket payment class offer the method payTicket (used by the Ticket booking class) The Data manager class offers methods that are used by three other classes: • getMatchInformation() • getSeatsInformation() • getBookingInformation() The External system interface class, offers a more general method for accessing information from external team servers: • getInformation()

Step 2e. Verify Use Cases and Quality Scenarios Check that functional requirements are covered: • The user can get information about future matches: Match browsing class • The user can get information about available seats: Seats browsing class • The users can buy tickets: Ticket booking and Ticket payment classes Check architectural drivers: • AD1: The system cannot be down more than 2 minutes a week (availability): Replication of the server and the database, and caching of external servers. • AD2: The system should provide secure electronic payment (security): Use secure computation in Ticket payment class, use secure transfer (https) and secure external payment service. • AD3: The system should be able to communicate with various team servers (modifiability): Supported through the External system interface class. • AD4: The system must handle 40,000 simultaneous users (performance): Replication of the server and database, and caching of external servers.

Question
Read the description below and do the following:
1.Identify the most important quality attribute(s) and the architectural drivers for the system described below.
2.Choose and describe suitable architectural tactics for the problem described below, and describe how the tactics affect the quality attributes.
3.Create architecture views of the system described below. The architecture must be described in two views according to the 4+1 view model: Process and Logical view
Motivate for your choice of quality attributes, architectural drivers and the architectural tactics used in your architecture.
Software for House Alarm System: The software described here is software for controlling an alarm system sold to households. The software should be able to run different configurations consisting of sensors from various producers, variations in types of displays and keyboard/button configurations. The different configurations also represent different price segments from the very simple and cheap alarm systems to the expensive and advanced. The software system is supports both smoke (fire) and movement sensors (theft). In normal mode, the system is running on electrical power from a standard power socket in the wall. However, in case a power outage, the system can operate on battery power. All the sensors are powered by the system. In case of a detection of fire or theft, the system will start a siren (alarm sound) and the display information about what caused the alarm, in what area of the house. How the information is shown is dependent on the capabilities of the display used in the system from only simple text to graphical description of the situation. For the more expensive configurations, the system can call the fire department or a security company through a telephone connection. The system can also be set up to call the mobile phone of the owner of the house. The system will also warn the security company if the alarm system is running on battery. The software is running on custom made computer with a CPU, memory and various input/output interfaces.

Answer:
1.Most important quality attribute(s) and architectural drivers for the system: This system is a product line system with many variations of configurations. In addition, such a system must be reliable as it concerns safety of the users. The two most important quality attributes for this system are availability and modifiability. Architectural drivers for the system:
• The architecture must provide high availability because the system can possibly save lives or keep people out of danger.
• The architecture must provide interfaces that can handle various types of sensors.
• The architecture must be able to support various types of displays and keyboard/button configurations.
• The architecture must be flexible in such way that it provides different types of functionality based on the price segment of the product.
• The architecture must be able to automatically switch to battery-operated mode in case of a power outage.

Data Storage Technologies and Networks - Comprehensive Reference Solutions

Question 
Why is SCSI performance superior to that of IDE/ATA? Explain the reasons from an architectural perspective

Answer :
SCSI offers improved performance and expandability and compatibility  options, making it suitable for high-end computers.
- Number of devices supported is 16
- SCSI architecture derives its base from the client-server relationship
- SCSI initiator, or a client, sends a request to a SCSI target, or a server.
- The target performs the tasks requested and sends the output to the initiator
- When a device is initialized, SCSI allows for automatic assignment of device IDs on the bus, which prevents two or more devices using the same SCSI IDs

Question 
What is a difference between a Cluster and a geographically-dispersed Cluster from administrative perspective?

Answer :
Geographically dispersed clusters, also called stretched clusters or extended clusters, are clusters comprised of nodes that are placed in different physical sites. Geographically dispersed clusters are designed to provide failover in the event of a site loss due to power issues, natural disasters or other unforeseen events.
From administrative perspective the difference would come up due to the storage that will be used. It won't be a common storage available at the respective locations instead a replication between the two will have to be set up and managed accordingly. Managing failover will also be different than a normal
cluster.

Question
DAS provides an economically viable alternative to other storage networking Solutions. Justify this statement

Answer :
- Setup requires a relatively lower initial investment
- Setup is managed using host-based tools, such as the host OS, which makes storage management tasks easy for small and medium enterprises.
- Requires fewer management tasks, and less hardware and software elements to set up and operate.

Question

i.Write the type of networks in place of N1 and N2. Write the type of ports in place of P1 and P2.
ii. What is meant by FC network is lossless? How FC achieve this ? How can we achieve losslessness in FCoE?

Answer
(i)N1 – IP Network. N2 – FC SAN. P1- Native SCSI port. N2- FC port

(ii) An FC network is lossless, meaning that the protocol has a built-in mechanism that prevents frame drops caused by congestion. Fibre Channel manages congestion through link level, credit based flow control. With credit-based flow control, the receiver sends credits to the sender to indicate the availability of receive buffers; the sender waits for credits before transmitting messages to the receiver Busy receive port can send the control frame to the transmit port for pause in transmission. This is called PAUSE capability of ethernet. Using this FCoE supports losslessness which is required in FC transmission.

Question
i.Write Server Configuration for the following:
Export src and ports to client01 and client02, but only, client01 has root privileges on it.
The client machines have root and can mount anywhere  on /exports. Anyone in the world can mount /exports/obj read-only.

ii.How do you recover the data from backup in following scenarios :      
(a) Full backup taken on Monday, Incremental backup taken on Tuesday, Wednesday and Thursday. You have to restore system on Friday.
(b) Full backup taken on Monday, Cumulative backup taken on Tuesday, Wednesday and Thursday. You have to restore system on Friday.

Answer
i)
# Export src and ports to client01 and client02, but only
# client01 has root privileges on it
/usr/src /usr/ports -maproot=root    client01
/usr/src /usr/ports               client02
# The client machines have root and can mount anywhere
# on /exports. Anyone in the world can mount /exports/obj read-only
/exports -alldirs -maproot=root      client01 client02
/exports/obj –ro

ii)
First restore Mondays full backup. 
(a) Then restore backup of Tuesday, wednesday and Thursday. 
(b) After restoration of Monday’s, restore Thursday’s backup

Question 
A host generates 8,000 I/Os at peak utilization with an average I/O size of 32 KB.  The response time is currently measured at an average of 12 ms during peak utilizations. When synchronous replication is implemented with a Fiber Channel ink to a remote site, what is the response time experienced by the host if the network latency is 6 ms per I/O?

Answer
Actual response time = 12+ (6*4) + (32*1024/8000) = 40.096 
Where 12 ms = current response time 
6 ms per I/O = latency 
                   32*1024/8000 = data transfer time
Question 
We have 6 nodes running a cluster. If suddenly 5 nodes found that they can communicate with each other but they cannot communicate with one specific node.
i. What steps the cluster should take to prevent data corruption? What is this phenomena called?
ii. Now if it is found that cluster is split in two groups with 3 nodes in each group. Nodes in one group can communicate with each other but can not communicate with nodes of other group. What is this situation called? Explain in brief about the steps the cluster will take to resolve the problem. 
Answer :
(i) The node will be forced to shut down through some managed Switch. This is called fencing.
(ii)This is called as split brain. To prevent data corruption cluster should shut down the group with lesser number of nodes. Since here the number of nodes are equal, cluster will take the help of quorum disk to decide the group of nodes to be shut down

Question
A host generates 8,000 I/Os at peak utilization with an average I/O size of 32 KB.  The response time is currently measured at an average of 12 ms during peak utilizations. When synchronous replication is implemented with a Fiber Channel ink to a remote site, what is the response time experienced by the host if the network latency is 6 ms per I/O?

Answer :
Actual response time = 12+ (6*4) + (32*1024/8000) = 40.096
Where 12 ms = current response time
6 ms per I/O = latency
                   32*1024/8000 = data transfer time

Question 
It is required to connect one FOCE SAN and one FC SAN to a rack mounted servers having 10Gbe CNAs. Suggest a plan of connection with a diagram showing necessary components.

Answer :

Question 
Explain the action involved between the NDMP DMA control and NDMP Server during Recovery process in the given scenario.


Answer :

DMA creates a control connection to the secondary storage agent
 Connect using TCP port 10,000
 NDMP_CONNECT_OPEN  (to negotiate version)
 NDMP_CONNECT_CLIENT_AUTH (to authenticate DMA to Server)
DMA uses the tape library media changer to load the required tape
The SCSI service is invoked
 NDMP_SCSI_OPEN
 NDMP_SCSI_EXECUTE_CDB - to manipulate media changer
NDMP_SCSI_CLOSE
DMA prepares the tape service for a recovery operation
 The tape service is invoked
 NDMP_TAPE_OPEN
 NDMP_TAPE_READ - to validate volume label
 NDMP_TAPE_MTIO - to position tape to start of backup data
DMA prepares the mover for a recovery operation
 The mover is invoked
 NDMP_MOVER_SET_RECORD_SIZE
 NDMP_MOVER_SET_WINDOW
  DMA opens control connection to the primary storage agent
 Connect using TCP port 10,000
 NDMP_CONNECT_OPEN - to negotiate protocol version
 NDMP_CONNECT_CLIENT_AUTH - to authenticate DMA to Server
  DMA queries secondary storage agent for capabilities
 NDMP_CONFIG_GET_CONNECTION_TYPE
  DMA queries primary storage agent for capabilities
 NDMP_CONFIG_GET_BUTYPE_INFO
 NDMP_CONFIG_GET_CONNECTION_TYPE
  DMA obtains the data server’s data connection address information
 The Data service is invoked
 NDMP_DATA_LISTEN
  DMA creates a data connection connection between NDMP servers
 NDMP_MOVER_CONNECT
  DMA creates a data connection connection between NDMP servers
 The mover connects to the specified IP address & TCP port
  DMA instructs the data server to initiate the recovery operation
 NDMP_DATA_START_RECOVER
  DMA recovery request is processed
 Data service determines the offset & length of the DMA specified recovery data
 Data server requests the specified data stream be transferred
 NDMP_NOTIFY_DATA_READ
  DMA instructs the mover to transfer the specified recovery stream
 NDMP_MOVER_READ
the mover interacts with the tape service to access the recovery stream
  DMA instructs the mover to transfer the specified recovery stream
 The mover begins sending recovery stream over data connection
  NDMP Data & Tape services send periodic log messages to DMA
 NDMP_LOG_MESSAGE
  NDMP Tape service sends notification when DMA intervention is required
example: end of mover window or tape medium encountered
 NDMP_NOTIFY_MOVER_PAUSED
  DMA initiates tape swap possibly utilizing media changer support
 NDMP_TAPE_MTIO - to rewind/unload tape
 NDMP_SCSI_EXECUTE_CDB - to manipulate media changer
 NDMP_TAPE_MTIO - to position new tape
 NDMP_TAPE_READ - to validate new tape header
DMA prepares the mover to continue the recovery operation
 NDMP_MOVER_SET_WINDOW
 NDMP_MOVER_CONTINUE
Data server detects end of recovery operation