Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I need help with the following OPerating system homework questions? 1) What proc

ID: 3890769 • Letter: I

Question

I need help with the following OPerating system homework questions?

1) What processes are waiting for an I/O device? How does the OS keep track of them? When the event happens that several processes have been waiting for, what happens to those processes?

2) Compare the UNIX fork() and Windows CreateProcess() functions.

3) Do ordinary pipes in UNIX only occur between parent and child processes, or can they occur between unrelated processes?

4) What combinations of send() and receive() are possible between two communicating processes, and what is the name of each of these combinations?

5) In what order does the OS run the parent and child process after a fork()?

Explanation / Answer

Please find the solution below :

2) Fork is for linux/unix systems where as CreateProcess is for Windows systems.

Both Fork and CreateProcess results in creating a new process but fork system call creates a new process and continues execution in both the parent and the child from the point where the fork function was called whereas CreateProcess creates a new process and load a program from disk.

3) Ordinary pipes in UNIX are used between parent and child process as the output of parent process is fed as input to child process.
Named pipes are used to connect two unrelated process on the same system.

5) there is no order in which parent and child process are executed after fork. If there is a dependency between parent and child process the parent has to wait for the child process to complete.
Other than this the process execution depends the OS as to which process is assigned CPU

Please leave a comment so that i can post answers to question 1 and 4 also.