Operating System

·        Operating System
-        Operating system is a system software which acts as Interface between users and computer hardware.
*       Goals of an operating system
-        Two primary goals of an operating system:-
                 i.          Operating System provides user friendly environment to interact with the external users.
                ii.          Operating System makes the resources available of the computer system. So, that one can execute any task in an efficient manner.      

Note :- Operating System is also known as resource allocator, it means it manages all resources of the computer system.

 *      Different functions of Operating System
  a.     Memory Management
  b.     Process Management
  c.      Device Management
  d.     File management
  e.      Command Interpretation
  f.       Security

1)     Memory Management
-        Memory Management is one of an important function of an operating system, which is responsible to manage primary memory / main memory / internal memory and secondary memory.
-        Memory management keep tracks of primary memory. It keeps track of primary memory i.e. what part of it are in use by whom, what part are not in use.
-        Operating System decides which process will get memory and for how much time.
-        It is also responsible for allocation and deallocation of the memory.
-        Operating System is also reliable and acts as a controller.

2)     Process Management
-        A program which is an execution is known as process. It is a passive entity.
-        Process Management is responsible for handling different activities related to any process, such as process allocation to the CPU.
-        Process Management implements scheduling Algorithm to execute different processes available for execution.
-        Process Management is also responsible to keep all information related to any process with the help of Process Control Block (PCB) for uniform execution of any process.

3)     Device Management
 ·       Device management is one of the important function of an operating system and it is responsible to perform the following activities.
-        Device Management keeps tracks of all devices.
-        Device Management decides which process gets the device when and for how much time.
-        Device Management  is also responsible for allocation and deallocation of the devices. It means operating system decides when to use any dice and when it should be free.
-        When any resource (devices) is being used then in that case operating system gives a proper message to the external user’s, as well as handles any exception.

4)     File Management
-        A file system is normally organized into directories for easy navigation and usage.
-        File Management keeps track of information, location, uses, status etc.
-        File Management decides which file would get the resource.
-        File Management is also responsible for allocation and deallocation of the files to the resources.
-        File Management is also responsible for adding or giving permission to the files so that hiding can be implemented.
-        File Management also implements for the type of the file and the specific resource it should get.

5)     Command Interpretation
-        Command Interpretation is one of the important function of the operating system through which it provides the environment to interact with he Users.
-        Users can interact with the operating system through the following:-
·        Character User Interface (CUI) :- Users interacts through writing commands. Such as copy con, date, md, cd, etc. It means at a time only one task is performed.
·        Graphical User Interface (GUI) :- Users can easily navigate through icons available on the desktop. It is more user friendly.

6)     Security
-        Security is one of the crucial function of an operating system through which we provides protection and security to different files and resources of the computer system.
-        Security feature is maintained with the help of Authentication and Authorization process. Associated with different activities of an operating system.

·        Serial Processing
-        Before Batch operating system computer’s used serial processing for their internal work. It means only one job was handled at a given time sequentially, i.e. FCFS - First Come First Serve.

*    Types of Operating System are
a.     Batch Operating System
b.     Multiprogramming Operating System
c.      Time Sharing Operating System
d.     Real Time Operating system
e.      Hard Real Time Operating System
f.       Soft Real Time Operating System
g.     Network Operating System
h.     Distributed Operating System
i.       Embedded Operating System

a)      Batch Operating System
-        To over come the problems of serial processing batch operating system was introduced.
-        The use of the batch operating system do not interact with the computer.
-        Each users give information of the job to the computer operator (users) with the help of Punch Cards, Magnetic Tape, Magnetic Relay, etc. for execution of the job.
-        It is the responsibility of batch operating system to create batches of the jobs which follows similar properties.
-        Different batches which are made by the batch operating system are executed sequentially.
            Problems with Batch Operating Systems are :-
·        Lack of interaction between the users and job.
·        Not proper utilization of the CPU (processor) due to some input/output operation.
·        One can’t add priority to add any process.

b)     Multiprogramming
-        Multiprogramming is a concept through which one can store two or more processes on the primary memory at a given time. Which was no possible with the single user’s, single tasking operating system.

c)      Time Sharing Operating System 
-        Time Sharing Operating System is an important operating system where response time to any process is minimize.
-        In Time Sharing Operating System a fixed time is shared among the processes. So, that each process would get the CPU interaction for its execution.
Note :- The fixed time allocated by an operating system is known as Time Slice or Quantum.     
-        Time Sharing Operating System is used to over come the problems faced in batch operating system, Where the processes having least burst time (process time) have to wait for a long time for processing.
-        The main ideas of time sharing system was to maintain the efficiency of the system as well as the interaction with all the processes waiting in the job que.

d)     Real Time Operating System
-        Real Time Operating System plays an important role which means the information should be updated without any delay for uniform execution.
-        In railway reservation, flight control, weather forecasting, etc. real time operating system is implemented.
-        Real Time System are generally implemented with a dedicated link used in embedded system.
·        Hard Real Time Operating System
-        In Hard Real Time Operating System the information or any process is executed as soon as it arrives at the processor without any delay.
-        Railway reservation and flight control is the best implementation of hard real time system.
·        Soft Real Time Operating System
-        In soft Real Time System the process which is to be executed has higher priority in comparison to the other processed which are having normal priority.
-        Unlike hard real time system the processing may be delayed in soft real time system but the importance of the process must be maintained.
-        Using mobile phones, cameras, depositing money in the bank are the implementation of soft real time system.

e)     Network Operating System
-        Network Operating System allows multiple computer to connect in a network for sharing of information as well as other resources.
-        Network Operating system also allow to use computer in a Client server environment.
-        One can easily share information and resources across geographic location for exchange of data information.
-        Window Anti and Novell Netware is network operating system generally used in offices, banks, research centers etc. to minimize the cost of the resources as well as clustering of the data in an efficient manner.

f)       Distributed Operating System
-        It is the superset of network operating system it means it is an enhanced version of network operating system which can be run in a distributed way.
-        Distributed Operating System allow users to setup different client server environment at multiple locations and be connected with a dedicated link.
-        The main advantage  of distributed operating system is to load balancing as well as clustering of information so that reports can be easily maintained and dependency of the different location is minimized.
-        The distributed operating system allows resources sharing in which an application can resources located in any computer system.
-        It also increases the computational speed by executing the parts of computation n different computer system.

The main difference between Network Operating System and Distributed Operating System

Provision of local services to the remote client.

Management of hardware resources.

2 – tier client / server architecture.

N – tier client / server architecture.

Handled at each node.

Global control and distributed management.

Operating System can be different on all nodes.

Operating System can be same o all nodes.

g)      Embedded Operating System
-        An Embedded Operating System is a specialized operating system designed to perform a specific task for a device that is not a computer.
-        An Embedded Operating ‘s main job is to run the code that allows the device to do its jobs.
-        Examples :- Mobile Phones, Washing Machines, ATM’s, Camera’s, etc.

Multiprogramming  Vs  Multiprocessing Vs Multitasking Vs Multithreading 

*       Multiprogramming 
-        The Concurrent residency of more than one program in the main memory is referred as multiprogramming.
-        Since multiple processes reside in the main memory, as soon as the currently executing process finishes is execution the next process is placed from the main memory to the processor.
-        The main objective of multiprogramming is Maximum CPU utilization & Efficient management of the main memory.




*       Multiprocessing
-        When one system is connected to move than one processor which collectively work for the competition of the task, it is called as multiprocessing system.

-       
Multiprocessing System can be divided into two types Symmetric Multiprocessing and Asymmetric Multiprocessing.

Symmetric Multiprocessing  :- The Os here resides on any available processor and the other processors run user’s program.
Asymmetric Multiprocessing :- The Os runs on any available processor or all the processor simultaneously run the user program.

*       Multithreading
·        Thread : It is a sub weight light process.
-        Multithreading is generally used to achieve of multitasking where multiple treads  works for the individuals process.

-        Multithreading is used to minimize the dependency of the process or any other resources.