Question: Multi-Part question. Please respond with C code (or C++ just specify) a- Write a UNIX program that creates a child process b- Open a file,
Multi-Part question. Please respond with C code (or C++ just specify)
a- Write a UNIX program that creates a child process
b- Open a file,
Use fprintf() to write 1, 2, 3, 100 to the file, with each number occupying one line; (Take Screenshot)
Close the file.
c- In a Linux terminal, please run command ps ef. You will see a list of processes in the system.
1. Pick up the bash process (the Shell process) which you are its owner (suppose the process is PROC), obtain its PID (Process ID).
2. go to /proc, then go to the corresponding directory for this process PROC, answer the following question:
What are the cmdline, environ, io, and sched of the process PROC?
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
