Concepts of Operating system, Exam questions for Operating Systems. Alagappa University
Sulochana_Ravisankar
Sulochana_Ravisankar

Concepts of Operating system, Exam questions for Operating Systems. Alagappa University

DOC (123 KB)
4 pages
2Number of visits
Description
This consists of important questions in Operating system
20 points
Download points needed to download
this document
Download the document
Preview3 pages / 4
This is only a preview
3 shown on 4 pages
Download the document
This is only a preview
3 shown on 4 pages
Download the document
This is only a preview
3 shown on 4 pages
Download the document
This is only a preview
3 shown on 4 pages
Download the document

Madurai Sivakasi Nadars Pioneer Meenakshi Women’s College,Poovanthi Department Of Computer Science

Class:III B.Sc(Computer Science) Subject Name:Operating System. Subject Code:4BCE5C1

1. What is an operating system? An operating system acts as an intermediary between the user of a computer and the computer hardware. The purpose of an operating system is to provide an environment in which a user can execute programs in a convenient and efficient manner. An operating system is software that manages the computer hardware. The hardware must provide appropriate mechanisms to ensure the correct operation of the computer system and to prevent user programs from interfering with the proper operation of the system.

2. Define Bootstrap program. For a computer to start running:—for instance, when it is powered up -or rebooted —it needs to have an initial program to run. This initial program, or bootstrap program, tends to be simple. It initializes all aspects of the system, from CPU registers to device controllers to memory contents. The bootstrap program must know how to load the operating system and to start executing that system.

3. Define DMA. Direct memory access (DMA) is used for high-speed I/O devices. After setting up buffers, pointers, and counters for the I/O device, the device controller transfers an entire block of data directly to or -from its own buffer storage to memory, with no intervention by the CPU. Only one interrupt is generated per block, rather than the one interrupt per byte (or word) generated for low-speed devices.

4. Give the details about hardware protection. Many programming errors are detected by the hardware. These errors are normally handled by the operating system. If a user program fails in some way— such as makes an attempt either to execute an illegal instruction, or to access memory that is not in the user's address space—then the hardware will trap to the operating system

5. Define system call. System calls provide the interface between a process and the operating system. These calls are generally available as assembly-language instructions, and are usually listed in the manuals used by assembly-language programmers. Some systems may allow system calls to be made directly from a higherlevel language program, in which case the calls normally resemble predefined function or subroutine calls.

6. Define process. A process can be thought of as a program in execution. A process will need certain resources — such as CPU time, memory, files, and I/O devices — to accomplish its task

7. Draw the diagram of process state.

8. What is PCB? Each process is represented in the operating system by a process control block. Also called a task control block

9. Define device queue. When a process is allocated the CPU, it executes for awhile and eventually quits, is interrupted, or waits for the occurrence of a particular event, such as the completion of an I/O request. In the case of an I/O request, such a request may be to a dedicated tape drive, or to a shared device, such as a disk. Since there are many processes in the system,the disk may be busy with the I/O request of some other process.the process therefore may have to wait for the disk. The list of processes waiting for a particular I/O device is called a device queue.

10. Define scheduler. A process migrates between the various scheduling queues throughout its lifetime. The .operating system must select, for scheduling purposes, processes from these queues in some fashion. The selection process is carried out by the appropriate scheduler.

11. Define context switch. Switching the CPU to another process requires saving the state of the old process and loading the saved state for the new process. This task is known as a context switch. Context-switch times are highly dependent on hardware support. For

instance, some processors (such as the DECSYSTEM-20) provide multiple sets of registers., A context switch simply includes changing the pointer to the current register set.

12. What is the purpose of CPU scheduler? Whenever the CPU becomes idle, the operating system must select one of the processes in the ready queue to be executed. The selection process is carried out by the short-term scheduler (or CPU scheduler). The scheduler selects from among the processes in memory that are ready to execute, and allocates the CPU to one of them

13. What are the functions of dispatcher? Another component involved in the CPU scheduling function is the dispatcher. The dispatcher is the module that gives control of the CPU to the process selected by the short-term scheduler. This function involves: ® Switching context o Switching to user mode « Jumping to the proper location in the user program to restart that program

14. Define throughput and turnaround time. Throughput:If the CPU is busy executing processes, then work is being done. One measure of work is the number of processes that are completed per time unit, called throughput Turnaround time:The interval from the time of submission of a process to the time of completion is. the turnaround time. Turnaround time is the sum of the periods spent waiting to get into memory, waiting in the ready queue, executing on the CPU, and doing I/O.

15. Define aging. A solution to the problem of indefinite blockage of low-priority processes is aging. Aging is a technique of gradually increasing the priority of processes that wait in the system for a long time. For example, if priorities range from 127 (low) to 0 (high), we could decrement the priority of a waiting process by 1 every 15 minutes

16. What is the purpose of multiple processor scheduling? If several identical processors are available, then load sharing can occur. It would be possible to provide a separate queue for each processor. In this case, however, one processor could be idle, with an empty queue, while another processor was very busy. To prevent this situation, we use a common ready queue. All processes go into one queue and are scheduled onto any available processor.

17. What is the purpose of Spooling? Spooling is also used for processing data at remote sites. The CPU sends the data via communications paths to a remote printer (or accepts an entire input job from a remote card reader). The remote processing is done at its own speed, with no CPU intervention. The CPU just needs to be notified when the processing is completed, so that it can spool the next batch of data. Spooling overlaps the I/O of

one job with the computation of other jobs. Even in a simple system, the spooler may be reading the input of one job while printing the output of a different job.

18. Define Time sharing system. Time sharing, or multitasking, is a logical extension of multiprogramming. Multiple jobs are executed by the CPU switching between them, but the switches occur so frequently that the users may interact with each program while it is running. An interactive, or hands-on, computer system provides on-line communication between the user and the system.

19. What is the difference between real time scheduling and thread scheduling? A real-time scheduling System is composed of the scheduler, clock and the processing hardware elements. In a real-time system, a process or task has schedulability; tasks are accepted by a real-time system and completed as specified by the task deadline depending on the characteristic of the scheduling algorithm.

Thread Scheduling:

A thread is a path of execution within a process. Also, a process can contain multiple threads.Thread is also known as lightweight process. The idea is achieve parallelism by dividing a process into multiple threads. For example, in a browser, multiple tabs can be different threads. MS word uses multiple threads, one thread to format the text, other thread to process inputs etc.

20. Define caching? Caching is an important principle of computer systems. Information is normally kept in some storage system (such as main memory). As it is used, it is copied into a faster storage system—the cache—on a temporary basis. When we need a particular piece of information, we first check whether it is in the cache. If it is, we use the information directly from the cache; if it is not, we use the information from the main storage system, putting a copy in the cache under the assumption that there is a high probability that it will be needed again.

no comments were posted
This is only a preview
3 shown on 4 pages
Download the document