Skip to main content

Some Basic Questions and answers on Operating System Concepts





1.       What are the three main purposes of an operating system?
  • To provide an environment for a computer user to execute programs on computer hardware in a convenient and efficient manner.
  • To allocate the separate resources of the computer as needed to solve the problem given. The allocation process should be as fair and efficient as possible.
  • As a control program it serves two major functions:
(1)   supervision of the execution of user programs to prevent errors and improper use of the computer,
and
(2)   Management of the operation and control of I/O devices.

2.      Keeping in mind the various definitions of operating system, consider whether the operating system should include applications such as web browsers and mail programs. Argue both that it should and that it should not, and support your answers.
Point:
Applications such as web browsers and email tools are performing an increasingly important role in modern desktop computer systems. To fulfill this role, they should be incorporated as part of the operating system. By doing so, they can provide better performance and better integration with the rest of the system. In addition, these important applications can have the same look-and-feel as the operating system software.

Counter point:
The fundamental role of the operating system is to manage system resources such as the CPU, memory, I/O devices, etc. In addition, its role is to run software applications such as web browsers and email applications. By incorporating such applications into the operating system, we burden the operating system with additional functionality. Such a burden may result in the operating system performing a less-than satisfactory job at managing system resources. In addition, we increase the size of the operating system thereby increasing the likelihood of system crashes and security violations.

3.       What are the five major activities of an operating system with regard to process management?
a.       The creation and deletion of both user and system processes
b.      The suspension and resumption of processes
c.       The provision of mechanisms for process synchronization
d.      The provision of mechanisms for process communication
e.       The provision of mechanisms for dead lock handling


4.       What are the three major activities of an operating system with regard to memory management?
a.       Keep track of which parts of memory are currently being used and by whom.
b.      Decide which processes are to be loaded into memory when memory space becomes available.
c.       Allocate and de-allocate memory space as needed.

5.       What are the three major activities of an operating system with regard to secondary-storage management?
a.       Free-space management.
b.      Storage allocation.
c.       Disk scheduling

6.       List five services provided by an operating system, and explain how each creates convenience for users. In which cases would it be impossible for user-level programs to provide these services? Explain your answer.
a.       Program execution: The operating system loads the contents (or sections) of a file into memory and begins its execution. A user level program could not be trusted to properly allocate CPU time.
b.      I/O operations: Disks, tapes, serial lines, and other devices must be communicated with at a very low level. The user need only specify the device and the operation to perform on it, while the system converts that request into device-or controller-specific commands. User-level programs cannot be trusted to access only devices they should have access to and to access them only when they are otherwise unused.
c.       File-system manipulation: There are many details in file creation, deletion, allocation, and naming that users should not have to perform. Blocks of disk space are used by files and must be tracked. Deleting a file requires removing the name file information and freeing the allocated blocks. Protections must also be checked to assure proper file access. User programs could neither ensure adherence to protection methods nor be trusted to allocate only free blocks and de-allocate blocks on file deletion.
d.      Communications: Message passing between systems requires messages to be turned into packets of information, sent to the network controller, transmitted across a communications medium, and reassembled by the destination system. Packet ordering and data correction must take place. Again, user programs might not coordinate access to the network device, or they might receive packets destined for other processes.
e.       Error detection: Error detection occurs at both the hardware and software levels. At the hardware level, all data transfers must be inspected to ensure that data have not been corrupted in transit. All data on media must be checked to be sure they have not changed since they were written to the media. At the software level, media must be checked for data consistency; for instance, whether the number of allocated and unallocated blocks of storage match the total number on the device. There, errors are frequently process independent (for instance, the corruption of data on a disk), so there must be a global program (the operating system) that handles all types of errors. Also, by having errors processed by the operating system, processes need not contain code to catch and correct all the errors possible on a system
7.       What is the main advantage of the microkernel approach to system design? How do user programs and system services interact in a microkernel architecture? What are the disadvantages of using the microkernel approach?
Benefits typically include the following
(a)    adding a new service does not require modifying the kernel
(b)   it is more secure as more operations are done in user mode than in kernel mode
(c)    a simpler kernel design and functionality typically results in a more reliable operating system. 
User programs and system services interact in a microkernel architecture by using inter-process communication mechanisms such as messaging. These messages are conveyed by the operating system.

The primary disadvantage of the microkernel architecture are the overheads associated with inter-process communication and the frequent use of the operating system’s messaging functions in order to enable the user process and the system service to interact with each other.

Comments

Popular posts from this blog

Image Processing

Okay, Now let's start doing Image Processing exercises on MATLAB. Before diving in let's start knowing what are the terms "Histograms", "Cumulative Histograms" and "Histogram Equalization" of an image. Let's see what are those, Histogram An image histogram is a type of histogram that acts as a graphical representation of the tonal distribution in a digital image. It plots the number of pixels for each tonal value. By looking at the histogram for a specific image a viewer will be able to judge the entire tonal distribution at a glance. Cumulative Histogram A cumulative histogram is a mapping that counts the cumulative number of observations in all of the bins up to the specified bin. That is, the cumulative histogram M i of a histogram m j is defined as:  Histogram Equalization Histogram equalization is a method in image processing of contrast adjustment using the image's histogram. for more definitions visit wik...