You are on page 1of 3
Kafrelshelkh University Date: 21/04/2024 Faculty of Engineering ‘ Time Allowed: 60 mi in / Department of Electrical Engineering Full Mark: 30 Ma Year: Third Kenton Midterm Exam Subject: Operating System 3 pages cet Answer All the following Questions: Question One [10 Marks] A. Briefly explain the role of a Process Control Block (PCB) in process management. B. Explain monolithic and microkerel operating systems. C. Explain various inter-process communication (IPC) mechanisms used in operating systems (¢.g., message passing, shared memory). D. list and briefly describe any 3 of the typical services provided by an OS. E. A process can have one of the three states: RUNNING and READY. Please answer the following questions. a. (1pt) What is the state of the process that is currently being executed by CPU? b. (Ipt) A currently running process has used up its time quantum. Then, the CPU scheduler schedules the next process from the queue of processes that are waiting to be executed. ‘Scanned with CamScanner jestion Two [15 Marks] ‘A. Choose The correct answer. 1. A program in execution is called a: (a) Thread (b) Process (c) File (d) Device 2. The process of selecting a process for CPU execution is called: (@) Context Switching (b) Process Creation (©) Process Termination _(d) CPU Scheduling 3. A device driver call is a kind of system call in the operating system a) True b) False 4, Assume process PO and P1 are the process before and after a context switch, and PCBO and PCBI are respectively their process control block. Which of the following time units are included inside the dispatch latency? a) PO executing b) Plexecuting c) saving state into PCBO and restore state from PCB1 d) none of the above 5. It works by increasing the priority of a process as time passes and will eventually be the highest priority request {after it has waited long enough) a) Aging —_b) Starvation —_c) convoy affect 6. The system should be convenient to use, easy to learn and use, safe and fast. a) User goals b) System goals 7. In preemptive scheduling a) the process cannot be interrupted in the middle of the execution b) the CPU is allocated to the process till it terminates c) there is no flexibility 4) the critical processes are allowed to access CPU as. they arrive 8. Which of the following instruction should be privileged? a) set value to timer _b) switch from user to kernel mode _c) Read the clock 9. Which item below is not an operating-system service that is helpful to the user? a) User interface. b) Error Detection. c) Program. Execution. d) Application Development. ©) designer goals 10.When executable file loaded into memory and then become active entity: (a) Context Switching (b) Process (c) Program (d) CPU Scheduling 11, Security of system from outsiders requires user authentication, extends to defending external 1/0 devices from invalid access attempts a) Security b) Protection ©) None of above 12. The is the operating system core component that is always running on the computer. a) Kernel b) System Programs ©) Boot loader d) CPU 13. If process terminates, all its children must be terminated as well a) Cascading termination b) Abort termination _c) cooperated process 14, Reason to support process cooperation a) Time Sharing) Modularity ©)none of above d) aandb 15. The sending process sends the message and resume operations immediately a) Blocking(synchronous) send. b) Non-blocking(asynchronous)send, C) Non-blocking(synchronous)send 4d) None of above ‘Scanned with CamSeanner Question Three [5 Mark] A. Consider the following three processes that arrive in a system at the specified times, along with the duration of their CPU bursts. Process P1 arrives at time t=0, and has a CPU burst of 10-time units. P2 arrives at t=2, and has a CPU burst of 2 units. P3 arrives at t=3, and has a CPU burst of 3 units. Assume that the processes execute only once for the duration of their CPU burst and terminate immediately. Calculate the time of completion of the three processes under each of the following scheduling policies. For each policy, you must state the completion time of all three processes, P1, P2, and P3. Assume there are no other processes in the scheduler’s queue. For the preemptive Policies, assume that a running process can be immediately preempted as soon as the new process arrives (if the policy should decide to preempt). (a) First Come First Serve (FCFS) (b) Round robin (preemptive) with a time slice of 5 units per process (RRS) ‘Scanned with CamSeanner

You might also like