OS Notes

of 9
All materials on our website are shared by users. If you have any questions about copyright issues, please report us to resolve them. We are always happy to assist you.
Related Documents
  OPERATING SYSTEMS   This document contains some basic definitions in Operating Systems. Ihave referred “Operating System Concepts” by Galvin et al. Please read theboo once and have a glance at this. !ou ill have a good understanding only hen you read the boo once or t ice. I have covered Process management and#emory management only. I ould say this ould do for Campus placements. OS Components ã Process management ã #ain$memory management ã %ile #anagement ã I&O management ã Secondary storage management ã 'et oring ã Protection management ã Command$Interpreter system Shell The interface bet een the user and the operating system. System call The interface bet een the process and the operating system. Microkernel In this type of ernel( all the non$essential components are removed fromthe ernel and they are implemented as system and the user level programs.Thus resulting to a S#)**+, -+,'+*( that typically provides minimal processand memory management in addition to communication facility. Process ã It is a program in eecution. ã It is an instance of a program. ã It is an active entity( hile the program is a passive entity. /i.e.( activationof a program becomes a process0 ã It is a unit of or in a system. Process States  New   Ready RunningTerminated Waiting  Context Switch Saving the state of old process and loading the saved state of the ne process. Cooperatin! Process  ) process is co$operating if it can affect or be affected by the other processes eecuting in the system. Threa s It is a called a light eight process and is a basic unit of CP1 utili2ation. #i$$erences %etween Process an Threa s The basic difference is that every process has its o n process id( codesection( data section( stac and a register set and. 3hile a thread has its o nthread id( stac and a register set( but it shares the data and code section ith allthe others threads of the process it belongs to. Si!nal It is used in 1'I4 system to notify a process that a particular event hasoccurred. Metho s $or IPC &InterProcess Comm'nication( ã Pipes ã Socets ã Signals ã Shared buffer  ã %iles )ren e*+o's, con ition In message passing( it is the condition in hich both the sender and thereceiver are bloced until the message is delivered. -on!term Sche 'ler &.o% Sche 'ler( This loads the process into the memory for eecution. Shortterm Sche 'ler &CP/ Sche 'ler( This selects the process from the ready 5ueue and allocates CP1 to it. #e!ree o$ M'ltipro!rammin! It is the number of processes currently present in memory. Me i'mterm Sche 'ler   It does s apping of processes( to control the degree of multiprogrammingand to have a good process mi /the miture of CP1$bound and I&O$boundprocesses0 Nonpreempti+e Sche 'lin! 1nder this( once the CP1 has been allocated to a process( the processeeps the CP1 until it releases the CP1 either by terminating or by s itching tothe aiting state. Preempti+e Sche 'lin! 6ere( the process releases the CP1 under the compulsion of other processes. #ispatcher  The module that gives the control of CP1 to the process selected by theCP1 scheduler. #ispatch -atency The time taen for the dispatcher to stop one process and to start another running. T'rnaro'n Time The interval from the time of submission of a process to the time of completion is the turnaround time. 0aitin! Time It is the sum of the periods spent aiting in the ready 5ueue. CP/ Sche 'lin! Al!orithms ã 1irst Come 1irst Ser+e &1C1S( o This is 7ust a %I%O 5ueue. ã Shortest .o% 1irst &S.1( o This is also called “shortest net CP1 burst” scheduling. o It can be both preemptive and non$preemptive. o The other name for preemptive S8% is called “shortest$remainingtime first” scheduling. ã Priority Sche 'lin! o This can also be both preemptive and non$preemptive. o Preemptive priority scheduling suffers from the “starvation”problem. This problem can be avoided using “aging”. )ging is themethod used to increase the priority of a process. ã Ro'n Ro%in &RR( sche 'lin! o Generally( it is %C%S scheduling ith preemptive added to it. o  ) time 5uantum /time slice0 is defined and one by one the processin the ready 5ueue is allo ed to use the CP1 only for this time  5uantum. )fter a process has finished its time 5uantum( it ispreempted and the net process in the 5ueue is given the CP1. o The ready 5ueue used here is a circular 5ueue. ã M'ltile+el Sche 'lin! o This scheduling partitions the ready 5ueue into several separate5ueues. o The processes are assigned permanently to one 5ueue( generallybased on some property of the process( such process type /liebacground or foreground processes0( process memory si2e(process priority and etc. o +ach 5ueue has it o n scheduling algorithm. In addition( theremust be scheduling among the 5ueues( no as “fied$prioritypreemptive scheduling”. ã M'ltile+el 1ee %ack 2'e'e Sche 'lin! o The setup is same as that of the multilevel 5ueue scheduling. 9uthere( the processes are allo ed to move bet een 5ueues. /i.e.0 If aprocess uses too much of CP1 time( it ill be moved to a lo er priority 5ueue and if a process aits too long in a lo er priority5ueue( it may be moved to a higher priority 5ueue. o This scheduling is the most general scheme and is also the mostcomple. 0in ows Sche 'lin! Scheme 3indo s uses priority scheduling. It has some nearly : priorities for processes. The priorities are as follo s in the descending priority order( o ,+)*;TI#+;P,IO,IT!;C*)SS o 6IG6;P,IO,IT!;C*)SS o  )9O<+;'O,#)*;P,IO,IT!;C*)SS o 'O,#)*;P,IO,IT!;C*)SS o 9+*O3;'O,#)*;P,IO,IT!;C*)SS o I=*+;P,IO,IT!;C*)SS -in'x Sche 'lin! Scheme  /,efer the boo0*inu uses credit based algorithm. +very process has its o n priority anda >nice? value. It uses this t o to find the credit and thus the credit basedscheduling. *inu uses %C%S and ,, to support Soft$,eal time scheduling. Priority In+ersion The situation hen a high$priority process ould be aiting for a lo er$priority one to finish. Critical Section
We Need Your Support
Thank you for visiting our website and your interest in our free products and services. We are nonprofit website to share and download documents. To the running of this website, we need your help to support us.

Thanks to everyone for your continued support.

No, Thanks