OS Questions and Answers Set 1

Operating System (OS)

Questions 1 to 10

1.
Which of the following statement about operating systems is correct?
I.     Operating system is not the interface between user and computer.
II.     The batch systems used in the second generation of operating systems allow several user jobs to be in the primary memory of a computer system at any given time.
III.    An interactive operate system provides on-line communication between the user and the system.
IV.   In a real-time operating system response time is not a key issue.
(a)  Only (I) above                                   (b)  (I), (III) and (IV) above                       
(c)  Both (II) and (III) above                       (d)  Both (I) and (III) above                       
(e)  (I), (II), and (IV) above.
2.
Which of the following statement(s) about operating system is/are correct?
I.     It manages the computer’s resources.
II.     Some operating systems distinguish between upper case and lower case letters in naming files.
III.    MS-Office is an operating system.
IV.   The operating system can be viewed as a virtual machine, which runs on top of the computer hardware.
(a)  Only (I) above                                   (b)  Only (II) above    (c)  Only (III) above
(d)  Only (IV) above                                 (e)  (I), (II) and (IV) above.
3.
In the Unix file system:
(a)   Directories and ordinary files are arranged in a hierarchical tree structure
(b)   Files can be accessed only by using its absolute path name
(c)   A file cannot have many extensions
(d)   A directory entry cannot contain a pointer to the file’s inode
(e)   ./usr/passwd and /usr/passwd represent two different files.
4.
Suppose we have a logical address space of 64 pages of 1024 words each, mapped onto a physical memory of 256 frames.  How many bits are there in the logical address? 
(a)  15                     (b)  16                     (c)  17                     (d)  18                     (e)  19.
5.
Which of the following is not a necessary condition for deadlock to occur?
(a)  Mutual exclusion                                                             (b)  Hold and wait                         (c)  Wait and signal
(d)  Circular wait                                     (e)  Hold.
6.
Suppose a system has six equivalent tape drives.  Three concurrent  processes P1,
P2 and P3 require three, two and four of these tape drives, respectively, to complete their execution.  At a given instance two, one and one of these tape drives are allocated to these processes P1, P2 and P3 respectively.  Which of the following allocations will bring the system to an unsafe state?
(a)   Allocating one tape drive to process P1
(b)   Allocating one tape drive to process P2
(c)   Allocating one tape drive to process P3
(d)   allocating two tape drives to process P3
(e)   Allocating one tape drive to P1 and another one to P3.
7.
A system suffering from an excessive number of page faults is said to be
(a)  Crashing            (b)  Hashing             (c)  Trashing            (d)  Thrashing           (e)  Bashing.
8.
A process P consists of five pages P1, P2, P3, P4, and P5, but the operating system allows it only THREE page-frames.  During its lifetime the process references its pages in the order P1, P2, P3, P2, P1, P4, P1, P5.  If the memory management policy is LFU (Least Frequently Used, with FIFO used to decide ties), which page will be replaced to make room for P5?
(a)  P1                     (b)  P2                     (c)  P3                     (d)  P4                     (e)  P5.
9.
The critical section problem can be solved in numerous ways. What statement is not true?
(a)   A test-and-set-lock (TSL) approach is known as a 'busy-wait' solution
(b)   A 'busy-wait' solution is good for short duration critical sections
(c)   When a binary semaphore is used and when SLEEP() is called the calling process goes into 'ready-to -run' mode
(d)   Monitors are more secure than less problematic than semaphores
(e)   All tools used to implement CS solutions must have atomic operations.
10.
A light weight process (LWP) is supported by a single kernel space thread, and it in turn supports several user space threads, belonging to a single user task.  Which statement is true?
(I)    The user task is made to be multithreaded in order to make it more efficient.
(II)    Only kernel space threads can utilize multiple CPU’s power.
(III)   If a user space thread blocks due to an I/O operation, the whole user task blocks.
(IV)  Kernel space threads have higher context switching overhead than user space threads.
(a)  (I), (II) and (IV) are only true               (b)  (I), (II) and (III) are only true               
(c)  None is true                                     (d)  All are true        
(e)  (I) and (IV) are only true.

Answers


1.
Answer : (c)
Reason:  Remaining all are contradictory statements.
2.
Answer : (e)
Reason:  MS-Office is a package.
3.
Answer : (a)
Reason:  A file can have many extensions; A directory can contain a pointer to the files inode Files can not be accessed only by using its absolute path name.
4.
Answer : (b)
Reason:  Remaining all are contradictory.
5.
Answer : (c)
Reason:  Wait and signal is not a necessary condition for deadlock to occur.
6.
Answer : (d)
Reason:  Allocating two tape drives to process P3 will Put the system in safe remaining drive the system to be unsafe.
7.
Answer : (d)
Reason:  Remaining all are not related to page faults in Operating system.
8.
Answer : (d)
Reason:  D is the right choice for the above situation.
9.
Answer : (c)
Reason:  By remaining all statements we can solve critical section problem.
10.
Answer : (a)
Reason:  iii is a contradictory statement.





1 comment :

  1. Did you know that that you can make cash by locking special pages of your blog or website?
    Simply join AdWorkMedia and add their content locking widget.

    ReplyDelete