Operating system is one of most popular word in 21st century. Basically operating system provides basic functionality to users to maintain a computer. It provides functions to other application software for access memory, I/O resources, Files etc. Computer hardware and software contain several layers.
Linux, Ubuntu, Widows 8, Mac OS are several from famous OS's.
Mainly OS has 3 objectives.
- Convenience: Provide facility to use computer easy.
- Efficiency: Use computer resource efficiency.
- Ability to evolve: OS should be able to introduce new functionality without affecting to other services.
Here is the several services provide by OS.
- Program development: This utility provides tools for create and debug programs.
- Program execution: Instruction load into main memory, Initialize I/O devices, provide basic functions and control system resource.
- Access to I/O devices: OS encapsulate I/O resource and provide interface for exchange data with I/O devices. Application software can only request for use I/O resource from OS. OS determine which operation should do.
- Control access to files: OS provide interface to access files in storage device. OS can provide protection to the file using this interface when multiple users use same storage device.
- System access: This access functions provide protection to resources and date in shared or public systems.
- Error detection and response: there many errors can occur while computer is working. Sometimes these little errors are reason for stuck whole computer(eg:- dead lock). Therefore OS should have ability to find errors and then fixed the error or end the program.
- Accounting: OS should provide ability to work with multiple users at single computer by providing different account for each user.
Earliest computers only contain display light, switches, printers. Program instructions enter to the system by using punch cards.
Early computers have several problems.
- Scheduling: User can use computers only for multiple of time blocks. When user complete the task before time block, it waste remaining time.
- Setup time: Users have to spend lots of time to setup program to run.
- Expensive: Used expensive materials and equipment.
Monitor is a piece of software to use batch-process. User submit job on card or tape sequentially. Monitor load this program and execute. Then it automatically load next program and continue process. It means processor time alternate between executions.
Monitor first read next job and then pass the control to that job. After complete that job, monitor gets control and continue this cycle again and again until end the all jobs. Job control language (JCL) uses to provide instructions to the monitor.
Computer hardware should provide below facility to functionality of Monitor.
- Memory protection: when program executing, memory area which contain monitor may be change by other program. Therefore processor hardware should detect this error and print the error and pass control to next program.
- Timer: timer start at the beginning of the job. When timer expires, program stops and return to monitor.
- Privileged instructions: program occur error if program use I/O devices directly. If user program need to perform I/O operation, then user program should request from Monitor perform that operation.
Interrupt: relinquishing control to and regaining control