when a process is created using fork(). what is shared
between parent process and child process.
1.Heap 2. stack 3. shared memory segments 4. I/O handles




Answers were Sorted based on User's Feedback



when a process is created using fork(). what is shared between parent process and child process. ..

Answer / sushil kumar

(3)shared memory segments
reason:-When a fork() system call is issued, a copy of all
the pages corresponding to the parent process is created,
loaded into a separate memory location by the OS for the
child process.

Is This Answer Correct ?    41 Yes 5 No

when a process is created using fork(). what is shared between parent process and child process. ..

Answer / pradeep

this is correct but partially. there is something called COW(copy on write). stack is not copied until one of them(parent or child) tries to write into it. if the child immediately calls exec then there is not need to copy the stack at all. As practically in most of the cases child process does an exec call, this unnecessary copy of huge stack is avoided by delaying it till its written into.

Is This Answer Correct ?    11 Yes 3 No

Post New Answer




More Operating Systems General Concepts Interview Questions

What is the highest priority software interrupt?

1 Answers   HP,


What are the possible threads a thread can have?

1 Answers  


what is the difference b/w window 2000 server and window 2003 server ?

2 Answers   Unisys,


What is Semaphore?

3 Answers  


To ensure one program doesnt corrupt other program in a Multi program enviornment what you should do?

0 Answers  






What are turnaround time and response time?

6 Answers   IBM, TCS, WUB,


Explain Scheduling?

1 Answers   Infosys,


what is difference between xp & 2003?

0 Answers  


What are the different process states?

10 Answers  


What are the different tasks of Lexical analysis?

0 Answers  


Give a brief discussion on schedulers & Dispatchers with respect to process management.

2 Answers  


What is cache memory?

3 Answers  






Categories