Krishna Logo
qa training in canada now
Divied
Call: Anusha @ 1 (877) 864-8462

 

Latest News
Home Navigation Divied
INTERVIEW Navigation Divied UNIX INTERVIEW QUESTIONS
Showing 131 - 140 of 324 Previous | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | Next
UNIX INTERVIEW QUESTIONS
 
131Construct Pipes To Execute The Following Jobs?
Date Posted: 07/02/2012

Ans: Who | echo "total users `who|wc -l`"ls | grep -c "poem" | tee filename.txtcat file1 file2 >> filetoappendto.txt??Rm -rf dir1 | tee error log

 
 
132In What Way The Fault Handlers And The Interrupt Handlers Are Different?
Date Posted: 07/02/2012

Ans: Fault handlers are also an interrupt handler with an exception that the interrupt handlers cannot sleep. Fault handlers sleep in the context of the process that caused the memory fault. The fault refers to the running process and no arbitrary processes are put to sleep.

 
 
133Explain About Fork?
Date Posted: 07/02/2012

Ans: Splitting is done by a system call named fork. Proc_id = fork (); splits the program into two copies, both of which continue to run. The only difference between the two is the value returned by fork, the process-id. Two copies of the program are made by the fork. In the child, the value returned by fork is zero, so it calls execlp, which does the command line and then dies. In the parent, fork returns non-zero so it skips the execlp.

 
 
134What Happens When You Execute A Program?
Date Posted: 07/02/2012

Ans:  When you execute a program on your UNIX system, the system creates a special environment for that program. This environment contains everything needed for the system to run the program as if no other program were running on the system. Each process has process context, which is everything that is unique about the state of the program you are currently running. Every time you execute a program the UNIX system does a fork, which performs a series of operations to create a process context and then execute your program in that context. The steps include the following:
Allocate a slot in the process table, a list of currently running programs kept by UNIX.
Assign a unique process identifier (PID) to the process.
iCopy the context of the parent, the process that requested the spawning of the new process.
Return the new PID to the parent process. This enables the parent process to examine or control the process directly. After the fork is complete, UNIX runs your program.

 
 
135What Are The Special Arrangements To Make A Terminal I/p And O/p?
Date Posted: 07/02/2012

Ans: When it is started by the shell, a program inherits three open files, with file descriptor 0, 1 and 2 called the standard i/p, the standard o/p, and the standard error. If the program reads’0’ and writes descriptors 1 and 2, it can do I/O without opening files.

 
 
136What Is The Use Of ‘Grep Command’?
Date Posted: 07/02/2012

Ans: Grep is a pattern search command. It searches for the pattern, specified in the command line with appropriate option, in a file(s).
Syntax: grep
Example: grep 99mx mcafile

 
 
137What Are The Processes That Are Not Bothered By The Swapper? Give Reason?
Date Posted: 07/02/2012

Ans: Zombie process: They do not take any up physical memory.
Processes locked in memories that are updating the region of the process.
Kernel swaps only the sleeping processes rather than the ?ready-to-run? Processes, as they have the higher probability of being scheduled than the Sleeping processes.

 
 
138What Is A Region?
Date Posted: 07/02/2012

Ans: A Region is a continuous area of a process’s address space (such as text, data and stack). The kernel in a? Region Table? That is local to the process maintains region. Regions are sharable among the process.

 
 
139What Are Conditions For A Machine To Support Demand Paging?
Date Posted: 07/02/2012

Ans: Memory architecture must based on Pages. The machine must support the? Restartable? Instructions.

 
 
140Suppose That You Are Using A Terminal In Which The Screen Size Is Bigger Than The Normal 24 Lines. If You Want To Use P And Take Full Advantage Of Your Terminal Capabilities What Choices Are Open To You?
Date Posted: 07/02/2012

Ans: You have to specify the screen size each time you use P. $P-36.
Also you could put a shell file in your bin.
$cat/usr/you/bin/p
Exec/usr/bin/p-36$*
$
Another solution is to modify p to use an environment variable that defines the properties of your terminal.

 
Showing 131 - 140 of 324 Previous | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | Next
Shadow Bottom
 
 
© 2005 -