Thursday, November 20, 2008

Operating Systems (MC251): April 2007

Section A : Basic Concepts (30 Marks)
1. Which one of the following operating systems was written for minicomputers?
(a) MS-DOS 1.0 (b) OS/360 (c) UNIX version 7 (d) Windows NT (e) LINUX.
2. Which technique was introduced because a single job could not keep both the CPU and the I/O devices busy?
(a) Time-sharing (b) Spooling (c) Preemptive scheduling (d) Multiprogramming (e) Monoprogramming.
3. Which kind of scheduling involves activation and suspension of processes?
(a) Short-term (b) Middle-term (c) Long-term (d) Prioritised (e) Non-prioritized.
4. One needs a good practical example of a “producer-consumer” type problem. From among the following which is/are true of such a good practical example?
I. A multithreaded audio server, where a thread writes digitized sound into a circular buffer and another thread reads it over to a web page.
II. A printer spooler where files are spooled on to the printer queue, to be taken and printed by the printer driver.
III. A shared data base updated by simultaneous queries.
(a) Only (II) above
(b) Both (I) and (III) above
(c) Both (I) and (II) above
(d) Only (I) above
(e) All (I), (II) and (III) above.
5. The wait time for a process is the amount of time
(a) A process needs, to be in the running state before it is completed
(b) The process spends waiting in the ready state
(c) The process waits for all resources to be allocated to it
(d) The process spends in the blocked state
(e) The process needs for context switching.
6. Which of the following is correct with respect to all UNIX system calls?
(a) time(), chdir(), createdir(), execve()
(b) chmod(), main(), waitpid(), exit()
(c) open(), fork(), delete(), read()
(d) lseek(), stat(), link(), kill()
(e) Read(), write(), parent(), exe().
7. What is meant by ‘thrashing’ with regard to memory management?
(a) Frequent movement of pages to and from main memory to the hard disk, due to page faults
(b) Reduction of disk space in the swap partition area
(c) Illegal attempt by a process to address a forbidden memory location
(d) Is another name for a page fault
(e) Is another name for a segmentation fault.
8. The amount of time that a job waits in a ready queue for getting selected by CPU is called as
(a) Turn around time (b) Waiting time (c) Completion time (d) Submission time (e) Throughput.
9. What do you call the process of storing and restoring from PCB?
(a) Loading (b) Relocation (c) Dispatcher (d) Process (e) Context switch.
10. Which of the following memory management scheme loads all pages of a program from disk into main memory?
(a) Paging (b) Demand paging (c) Segmentation (d) Segmentation with paging (e) Demand Segmentation.
11. Which of the following page replacement algorithm uses the technique of replace that page which is not used in the near future?
(a) LRU (b) LFU (c) ORA (d) FIFO (e) MFU.
12. The set of pages that a process is currently using is called
(a) Program (b) Page Group (c) Working Group (d) Working Set (e) Software.
13. The register that contains the starting address of a program in the main memory is
(a) Address register (b) Base register (c) GPR (d) Index register (e) Limit register.
14. What is the process of converting logical address into physical address?
(a) Conversion (b) Displacement (c) Relocation (d) Transfer (e) Segmentation.
15. How does the logical memory is divided in segmentation process?
(a) Pages (b) Frames (c) Blocks (d) Cells (e) Segments.
16. Where do the O.S programs reside in main memory?
(a) User Memory area (b) Monitor Memory area (c) Heap area (d) Stack area (e) Data area.
17. In Unix, which of the following system call returns the meta data about a file?
(a) Fstat (b) Mstat (c) MetaCall (d) Sigabort (e) Fork.
18. Information in the file is processed in order, one recode after another. What is the mode of access for the above given statement?
(a) Relative (b) Sequential (c) Direct (d) Index (e) Indexed-sequential.
19. Which technique is used to recover the process from starvation situation?
(a) Paging (b) Aging (c) Compaction (d) Starvation (e) Reduction.
20. Before we store data into a disk it must be divided into sectors from where the disk controller can read and write. What do you call this process as?
(a) Low-level formatting (b) Fragmenting (c) High-level formatting (d) Cleaning (e) Portioning a disk.
21. The disk controller can be told to replace each bad sector logically with one of the spare sectors in the disk. What do you call this scheme as?
(a) Sector sparing (b) Sector slipping (c) Forwarding (d) Back word replacing (e) Sector replace.
22. Controlling the access of programs, processes or users to the resources defined by the system. What is this process called as?
(a) Prevention (b) Security (c) Protection (d) Access stop (e) Access right.
23. Which of the following symbol is used to represent the process vertex in a RAG?
(a) (b) (c) (d) (e)
24. Which of the following mechanism is used to achieve concurrency control?
(a) Clusters (b) Triggers (c) Control access (d) Cursors (e) Locks.
25. Every process before starting execution should know what resources are allocated to it. This is known as
(a) Know-to-need (b) Need-to-Know (c) Know about what (d) Need-to-use
(e) Know-to-use.
26. The ability to execute an operation on an object is known as
(a) Access Right (b) Access Control (c) Domain Knowledge (d) Control Right
(e) Protection.
27. Which among the following is the time required to move the disk head to the desired track?
(a) Access Time (b) Track Time (c) Latency Time (d) Seek Time
(e) Block Time.
28. Which among the following is not shared in distributed system?
(a) CPU (b) Memory (c) I/O devices (d) Network (e) File.
29. What do you call the name of the file that does not reveal any hint of the file’s physical storage location?
(a) Location independence (b) Protection (c) Location transparency (d) File migration
(e) Inter-machine interface.
30. 1024 words occupy how many bits?
(a) 9 (b) 10 (c) 11 (d) 12 (e) 13.
Section B : Problems (50 Marks) 1. Discuss about the following O.S structures and also discuss the advantages and disadvantages of each.
a. Layered Structure.
b. Client-server Model. (5 + 5 = 10 marks)
2.
a. Write the differences between a program and a process.
b. Draw the process state diagram for a multi programmed operating system. Explain about various transitions among the states. (4 + 6 = 10 marks)
3.
a. What is thrashing? Explain different mechanisms to handle thrashing situation.
b. Consider a logical address space of 8 pages and 1024 words mapped into physical memory of 32 frames.
i. How many bits are there in logical address?
ii. How many bits are there in physical address? (6 + 4 = 10 marks)
4. Define paging? Discuss in detail how paging scheme can be implemented? Discuss advantages and disadvantages of paging scheme. (10 marks)
5. Explain different file allocation schemes and discuss merits and demerits of each scheme.
(10 marks)
Section C : Applied Theory (20 Marks)
6. Suppose that a disk has 200 tracks, numbered from 0 to 199. The drive is currently serving a request a track 50. The queue of pending requests in FIFO order is
93 38 14 124 78 130 12 140
Starting from the current head disk position, what is the total distance that the disk arm moves to satisfy all the pending requests for each of the following disk scheduling algorithms.
a) FCFS b) SSTF c) SCAN d) CSCAN e) LOOK f) CLOOK. (12 marks)
7. What is a page fault? Consider the following page reference string.
1, 2, 3, 4, 2, 1, 5, 6, 2, 1, 2, 3, 7, 6, 3, 2, 1, 2, 3, 6
How many page faults would occur for the following page replacement algorithms? Assume there are four frames in the memory.
i. ORA
ii. LRU
iii. FIFO. (8 marks)
1.
Answer : (c)
Reason: UNIX version 7 was written for minicomputers.
2.
Answer : (a)
Reason: Time sharingtechnique was introduced because a single job could not keep both the CPU and the I/O devices busy
3.
Answer : (a)
Reason: Short-term. Kind of scheduling involves activation and suspension of processes.
4.
Answer : (b)
Reason: A multithreaded audio server, where a thread writes digitized sound into a circular buffer and another thread reads it over to a web page and a shared data base updated by simultaneous queries are the suitable examples for “producer-consumer”
5.
Answer : (a)
Reason: Wait time for a process is the amount of time a process needs, to be in the running state before it is completed
6.
Answer : (a)
Reason: The given are the unix system calls time(), chdir(), createdir(), execve()
7.
Answer : (b)
Reason: Reduction of disk space in the swap partition area.
8.
Answer : (b)
Reason: The amount of time that a job waits in a ready queue for getting selected by CPU waiting time
9.
Answer : (e)
Reason: The process of storing and restoring from PCB is called context swithching
10.
Answer : (a)
Reason: Paging memory management scheme loads all pages of a program from disk into main memory.
11.
Answer : (c)
Reason: ORA page replacement algorithm use the technique of replace that page which is not used in the near future.
12.
Answer : (d)
Reason: The set of pages that a process is currently using is called- Working set
13.
Answer : (b)
Reason: The register that contains starting address of the program in the main memory is called Base register
14.
Answer : (c)
Reason: The process of converting logical address into physical address is called Relocation.
15.
Answer : (e)
Reason: In a segmentation scheme the logical memory will be divided into Segments.
16.
Answer : (b)
Reason: The place where O.S programs stored in the main memory is called Monitor Memory area.
17.
Answer : (a)
Reason: In Unix which of the following system call returns the meta data about a file. Fstat
18.
Answer : (b)
Reason: Information in the file is processed in order, one recode after another. This mode of access is called Sequential.
19.
Answer : (b)
Reason: Aging technique is used to recover the process from starvation situation
20.
Answer : (c)
Reason: Before we store data into a disk it must be divided into sectors and from where the disk controller can read and write. This is known a s highlevel formatting
21.
Answer : (a)
Reason: The disk controller can be told to replace each bad sector logically with one of the spare sectors in the disk. This scheme is known as Sector sparing
22.
Answer : (c)
Reason: Controlling the access of programs, processes or users to the resources defined by the system is known as Protection
23.
Answer : (b)
Reason: Circle is used to represent a process in RAG
24.
Answer : (e)
Reason: Locks mechanism is used to achieve concurrency control
25.
Answer : (b)
Reason: Every process before starting execution should know what resources are allocated to it. This is known as Need-to-Know.
26.
Answer : (a)
Reason: The ability to execute an operation on an object is known as Access Right
27.
Answer : (d)
Reason: The time required to move the disk head to the desired track is known as Seek Time
28.
Answer : (b)
Reason: A distributed system is a collection of processors that do not share- Memory.
29.
Answer : (c)
Reason: The name of the file does not reveal any hint of the file’s physical storage location is called Location transparency
30.
Answer : (b)
Reason: 1024=210 words. So 10 bits is the right choice.


2 comments:

Anonymous said...

how are you?

Can I link to this post please?

Anonymous said...

top [url=http://www.001casino.com/]casino online[/url] brake the latest [url=http://www.casinolasvegass.com/]online casinos[/url] unshackled no set aside perk at the best [url=http://www.baywatchcasino.com/]online casinos
[/url].