Unit 2
Introduction to operating system
What is an Operating System?
An Operating system (OS) is a software which acts as an interface between the end user and computer hardware. Every computer must have at least one OS to run other programs. An application like Chrome, MS Word, Games, etc needs some environment in which it will run and perform its task. The OS helps you to communicate with the computer without knowing how to speak the computer's language. It is not possible for the user to use any computer or mobile device without having an operating system.
Introduction Operating System
History Of OS
- Operating systems were first developed in the late 1950s to manage tape storage
- The General Motors Research Lab implemented the first OS in the early 1950s for their IBM 701
- In the mid-1960s, operating systems started to use disks
- In the late 1960s, the first version of the Unix OS was developed
- The first OS built by Microsoft was DOS. It was built in 1981 by purchasing the 86-DOS software from a Seattle company
- The present-day popular OS Windows first came to existence in 1985 when a GUI was created and paired with MS-DOS.
Features of Operating System
Here is a list commonly found important features of an Operating System:
- Protected and supervisor mode
- Allows disk access and file systems Device drivers Networking Security
- Program Execution
- Memory management Virtual Memory Multitasking
- Handling I/O operations
- Manipulation of the file system
- Error Detection and handling
- Resource allocation
- Information and Resource Protection
What is a Kernel?
The kernel is the central component of a computer operating systems. The only job performed by the kernel is to the manage the communication between the software and the hardware. A Kernel is at the nucleus of a computer. It makes the communication between the hardware and software possible. While the Kernel is the innermost part of an operating system, a shell is the outermost one.
Features of Kennel
- Low-level scheduling of processes
- Inter-process communication
- Process synchronization
- Context switching
Types of Kernels
There are many types of kernels that exists, but among them, the two most popular kernels are:
1.Monolithic
A monolithic kernel is a single code or block of the program. It provides all the required services offered by the operating system. It is a simplistic design which creates a distinct communication layer between the hardware and software.
2. Microkernels
Microkernel manages all system resources. In this type of kernel, services are implemented in different address space. The user services are stored in user address space, and kernel services are stored under kernel address space. So, it helps to reduce the size of both the kernel and operating system.
Functions of an Operating System
Function of an Operating System
In an operating system software performs each of the function:
- Process management:- Process management helps OS to create and delete processes. It also provides mechanisms for synchronization and communication among processes.
2. Memory management:- Memory management module performs the task of allocation and de-allocation of memory space to programs in need of this resources.
3. File management:- It manages all the file-related activities such as organization storage, retrieval, naming, sharing, and protection of files.
4. Device Management: Device management keeps tracks of all devices. This module also responsible for this task is known as the I/O controller. It also performs the task of allocation and de-allocation of the devices.
5. I/O System Management: One of the main objects of any OS is to hide the peculiarities of that hardware devices from the user.
6. Secondary-Storage Management: Systems have several levels of storage which includes primary storage, secondary storage, and cache storage. Instructions and data must be stored in primary storage or cache so that a running program can reference it.
7. Security:- Security module protects the data and information of a computer system against malware threat and authorized access.
8. Command interpretation: This module is interpreting commands given by the and acting system resources to process that commands.
9. Networking: A distributed system is a group of processors which do not share memory, hardware devices, or a clock. The processors communicate with one another through the network.
10. Job accounting: Keeping track of time & resource used by various job and users.
11. Communication management: Coordination and assignment of compilers, interpreters, and another software resource of the various users of the computer systems.
Types of Operating system
- Batch Operating System
- Multitasking/Time Sharing OS
- Multiprocessing OS
- Real Time OS
- Distributed OS
- Network OS
- Mobile OS
Batch Operating System
Some computer processes are very lengthy and time-consuming. To speed the same process, a job with a similar type of needs are batched together and run as a group.
The user of a batch operating system never directly interacts with the computer. In this type of OS, every user prepares his or her job on an offline device like a punch card and submit it to the computer operator.
Multi-Tasking/Time-sharing Operating systems
Time-sharing operating system enables people located at a different terminal(shell) to use a single computer system at the same time. The processor time (CPU) which is shared among multiple users is termed as time sharing.
Real time OS
A real time operating system time interval to process and respond to inputs is very small. Examples: Military Software Systems, Space Software Systems.
Distributed Operating System
Distributed systems use many processors located in different machines to provide very fast computation to its users.
Network Operating System
Network Operating System runs on a server. It provides the capability to serve to manage data, user, groups, security, application, and other networking functions.
Mobile OS
Mobile operating systems are those OS which is especially that are designed to power smartphones, tablets, and wearables devices.
Some most famous mobile operating systems are Android and iOS, but others include BlackBerry, Web, and watch OS.
Difference between Firmware and Operating System
Firmware | Operating System |
Firmware is one kind of programming that is embedded on a chip in the device which controls that specific device. | OS provides functionality over and above that which is provided by the firmware. |
Firmware is programs that been encoded by the manufacture of the IC or something and cannot be changed. | OS is a program that can be installed by the user and can be changed. |
It is stored on non-volatile memory. | OS is stored on the hard drive. |
Difference between 32-Bit vs. 64 Bit Operating System
Parameters | 32. Bit | 64. Bit |
Architecture and Software | Allow 32 bit of data processing simultaneously | Allow 64 bit of data processing simultaneously |
Compatibility | 32-bit applications require 32-bit OS and CPUs. | 64-bit applications require a 64-bit OS and CPU. |
Systems Available | All versions of Windows 8, Windows 7, Windows Vista, and Windows XP, Linux, etc. | Windows XP Professional, Vista, 7, Mac OS X and Linux. |
Memory Limits | 32-bit systems are limited to 3.2 GB of RAM. | 64-bit systems allow a maximum 17 Billion GB of RAM. |
The advantage of using Operating System
- Allows you to hide details of hardware by creating an abstraction
- Easy to use with a GUI
- Offers an environment in which a user may execute programs/applications
- The operating system must make sure that the computer system convenient to use
- Operating System acts as an intermediary among applications and the hardware components
- It provides the computer system resources with easy to use format
- Acts as an intermediator between all hardware's and software's of the system
Disadvantages of using Operating System
- If any issue occurs in OS, you may lose all the contents which have been stored in your system
- Operating system's software is quite expensive for small size organization which adds burden on them. Example Windows
- It is never entirely secure as a threat can occur at any time
Summary
- An operating system is a software which acts as an interface between the end user and computer hardware
- Operating systems were first developed in the late 1950s to manage tape storage
- The kernel is the central component of a computer operating systems. The only job performed by the kernel is to the manage the communication between the software and the hardware
- Two most popular kernels are Monolithic and Micro Kernels
- Process, Device, File, I/O, Secondary-Storage, Memory management are various functions of an Operating System
- Batch, Multitasking/Time Sharing, Multiprocessing, Real Time, Distributed, Network, Mobile are various types of Operating Systems
Introduction
For those who grew up having an entire computer sitting at their finger tips waiting at their beck and call to carry out every command it is hard to imagine punching a program into punch cards, submitting it over a Dutch door and then waiting at least 24 hours to get a printout of the run. Or, even worse, driving 30 miles and waiting one week between program submission and receipt of the printout. But, to understand how today’s operating systems came to be what they are, we need to go back “to those days of yesteryear,” as the saying goes.
The chief function of an operating system, we said, is to manage the resources of a complex computer system. It has been said that necessity is the mother of invention. The development of operating systems to their present day form is a good illustration of that. At each stage in this development, bottlenecks were found which prevented using the computer resources to their fullest capacity. The need to eliminate those bottlenecks gave impetus to inventiveness leading to the next step in the history of operating systems.
Stages of Development
Prehistory
The earliest computers did not have software. Their functionality was hardwired. To reprogram the machine required rewiring. These machines, of course, did not have an operating system.
User SetUp and Breakdown
With the advent of the stored program machine the day of the von Neumann architecture machines began. But the early machines were costly behemoths, available only to clients with deep pockets.
When it was not uncommon to pay $1 million for a computer, those who used these machines for business or research were willing to go to great lengths just to get their “moment in the sun,” so to speak. Computers were scheduled around the clock and users had to come in at their scheduled time. In addition to loading their programs, the users had to load (and link, if necessary) any system software, such as compilers and device drivers, needed for their run. And additional work was required to make the machine available for the next user.
Operator Controlled Machines
Very soon it became clear that during the rather lengthy setup and breakdown time the very expensive computer was not doing useful work. This waste of resources had to be remedied. A computer operator was put in charge of the machine. Users submitted their programs on punch cards. The operator scheduled job execution, loaded the programs, collected the output and performed any required setup operations. By running jobs with similar system requirements in the same time frame, the setup and breakdown process was streamlined. Jobs could also be arranged by priority, run time and other criteria.
Simple Batch Systems
To further reduce slack time, the amount of time during which the computer did no useful work, the scheduling and loading functions were turned over to a program called the monitor (called a resident monitor, if it stayed in memory at all times). Users submitted short instructions in a cryptic language called JCL (job control language) to aid the monitor in its task. Jobs were grouped together and run in batches. Often a separate computer was used to handle the I/O operations. Debugging for this and other early systems was accomplished by interpreting a core dump, a hexadecimal snapshot of the contents of memory and all registers at the time of program error. Hardware features such as memory protection, timers, privileged instructions and interrupts were added to machines during this stage of development.
Multiprogrammed Batch Systems
An I/O operation is orders of magnitude slower than instruction execution. For this reason the processor would sit idle a large proportion of the time, despite the efficiency improvements brought about by batch systems. Instead of doing useful work, the processor would wait for an I/O operation to complete. The observation was made that more than one job could be read into memory, allowing the processor to switch back and forth between jobs (or processes, as they came to be known). While one process was involved in I/O, another could be running - i.e., making use of the processor. The introduction of multiprogramming or multitasking laid the foundation for many features found in today’s operating systems.
Implementation of multitasking required a more sophisticated form of scheduling, as well as software to manage the placement of jobs into memory. Thus, schedulers and memory management modules were added to the software repertoire of an operating system.
Interactive Multiprogramming
{Time Sharing Systems}
As the price of machines came down and wages went up, the programmers’ and users’ time became an important commodity. The importance of good response time and short turnaround time were factored into the OS design process. The major step taken was the advent of time shared systems. Instead of just submitting jobs, the user was given interactive access to the machine via a command line interface. Since the processor speed was many orders of magnitude faster than the actions taken by the user, under ideal conditions the user could work as if she had sole access to the machine.
Single User Multiprogramming
The wedding of the personal computer to multiprogramming resulted in extremely useful computer systems. The could the user run several processes at one time, doing useful work with one program while waiting for another program to complete its task. In addition, he could perform operations which require two programs to run simultaneously, e.g., copy text from a web page and paste it into a word processing document.
To clear up confusion:
Since the terms task and process are often used interchangeably, it may seem that multitasking and multiprocessing would be also. This is not the case. From page 64 of Stalling, we see that multiprogramming and multitasking are synonymous. But on page 198 we read these definitions:
Multiprogramming: The management of multiple processes within a uniprocessor system.
Multiprocessing: The management of multiple processes within a multiprocessor.
We see, then, that the term multiprocessing comes from multiprocessor, whereas the term multitasking comes from task. Since a process (or task) is a program in execution, we can see that the concept “the management of multiple processes” is not far from “the management of multiple programs.” It is unfortunate that the development of OS terminology created this source of confusion.
There are Many Operating Systems those have be Developed for Performing the Operations those are requested by the user. There are Many Operating Systems which have the Capability to Perform the Requests those are received from the System. The operating system can perform a Single Operation and also Multiple Operations at a Time. So there are many types of Operating systems those are organized by using their Working Techniques.
1) Serial Processing: The Serial Processing Operating Systems are those which Performs all the instructions into a Sequence Manner or the Instructions those are given by the user will be executed by using the FIFO Manner means First in First Out. All the Instructions those are Entered First in the System will be Executed First and the Instructions those are Entered Later Will be Executed Later. For Running the Instructions the Program Counter is used which is used for Executing all the Instructions.
In this the Program Counter will determines which instruction is going to Execute and the which instruction will be Execute after this. Mainly the Punch Cards are used for this. In this all the Jobs are firstly Prepared and Stored on the Card and after that card will be entered in the System and after that all the Instructions will be executed one by One. But the Main Problem is that a user doesn’t interact with the System while he is working on the System, means the user can’t be able to enter the data for Execution.
2) Batch Processing: The Batch Processing is same as the Serial Processing Technique. But in the Batch Processing Similar Types of jobs are Firstly Prepared and they are Stored on the Card. And that card will be Submit to the System for the Processing. The System then Perform all the Operations on the Instructions one by one. And a user can’t be Able to specify any input. And operating system wills increments his Program Counter for Executing the Next Instruction.
The Main Problem is that the Jobs those are prepared for Execution must be the Same Type and if a job requires for any type of Input then this will not be Possible for the user. And Many Time will be wasted for Preparing the Batch. The Batch Contains the Jobs and all those jobs will be executed without the user Intervention. And Operating System will use the LOAD and RUN Operation. This will first LOAD the Job from the Card and after that he will execute the instructions. By using the RUN Command.
The Speed of the Processing the Job will be Depend on the Jobs and the Results those are produced by the System in difference of Time which is used for giving or submit the Job and the Time which is used for Displaying the Results on the Screen.
3) Multi-Programming: As we know that in the Batch Processing System there are multiple jobs Execute by the System. The System first prepare a batch and after that he will Execute all the jobs those are Stored into the Batch. But the Main Problem is that if a process or job requires an Input and Output Operation, then it is not possible and second there will be the wastage of the Time when we are preparing the batch and the CPU will remain idle at that Time.
But With the help of Multi programming we can Execute Multiple Programs on the System at a Time and in the Multi-programming the CPU will never get idle, because with the help of Multi-Programming we can Execute Many Programs on the System and When we are Working with the Program then we can also Submit the Second or Another Program for Running and the CPU will then Execute the Second Program after the completion of the First Program. And in this we can also specify our Input means a user can also interact with the System.
The Multi-programming Operating Systems never use any cards because the Process is entered on the Spot by the user. But the Operating System also uses the Process of Allocation and De-allocation of the memory Means he will provide the memory Space to all the Running and all the Waiting Processes. There must be the Proper Management of all the Running Jobs.
4) Real Time System: There is also an Operating System which is known as Real Time Processing System. In this Response Time is already fixed. Means time to Display the Results after Possessing has fixed by the Processor or CPU. Real Time System is used at those Places in which we Requires higher and Timely Response. These Types of Systems are used in Reservation. So when we specify the Request, the CPU will perform at that Time. There are two Types of Real Time System.
1) Hard Real Time System: In the Hard Real Time System, Time is fixed and we can’t Change any Moments of the Time of Processing. Means CPU will Process the data as we Enters the Data.
2) Soft Real Time System: In the Soft Real Time System, some Moments can be Change. Means after giving the Command to the CPU, CPU Performs the Operation after a Microsecond.
5) Distributed Operating System. – Distributed Means Data is Stored and Processed on Multiple Locations. When a Data is stored on to the Multiple Computers, those are placed in Different Locations. Distributed means In the Network, Network Collections of Computers are connected with Each other.
Then if we want to Take Some Data From other computer, Then we uses the Distributed Processing System. And we can also Insert and Remove the Data from out Location to another Location. In this Data is shared between many users. And we can also Access all the Input and Output Devices are also accessed by Multiple Users.
6) Multiprocessing: Generally a computer has a Single Processor means a Computer have a just one CPU for Processing the instructions. But if we are Running multiple jobs, then this will decrease the Speed of CPU. For Increasing the Speed of Processing then we uses the Multiprocessing, in the Multi Processing there are two or More CPU in a Single Operating System if one CPU will fail, then other CPU is used for providing backup to the first CPU. With the help of Multi-processing, we can Execute Many Jobs at a Time. All the Operations are divided into the Number of CPU’s. If first CPU Completed his Work before the Second CPU, then the Work of Second CPU will be divided into the First and Second.
7) Parallel operating systems are used to interface multiple networked computers to complete tasks in parallel. The architecture of the software is often a UNIX-based platform, which allows it to coordinate distributed loads between multiple computers in a network. Parallel operating systems are able to use software to manage all of the different resources of the computers running in parallel, such as memory, caches, storage space, and processing power. Parallel operating systems also allow a user to directly interface with all of the computers in the network.
A parallel operating system works by dividing sets of calculations into smaller parts and distributing them between the machines on a network. To facilitate communication between the processor cores and memory arrays, routing software has to either share its memory by assigning the same address space to all of the networked computers, or distribute its memory by assigning a different address space to each processing core.
Sharing memory allows the operating system to run very quickly, but it is usually not as powerful. When using distributed shared memory, processors have access to both their own local memory and the memory of other processors; this distribution may slow the operating system, but it is often more flexible and efficient.
An operating system is a powerful, and usually large, program that controls and manages the hardware and other software on a computer.
All computers and computer-like devices require operating systems, including your laptop, tablet, desktop, smartphone, smartwatch, and router.
Not sure what operating system you're running? Use the Lifewire System Info Tool below to find out!
System Info Tool
Tap or click "Check Now" and we'll automatically determine your IP address, ISP, browser, operating system, and other basic information about your device.
None of your information is sent to Lifewire's servers and no one but you can see the results.
Examples of Operating Systems
Laptops, tablets, and desktop computers all run operating systems that you've probably heard of. Some examples include versions of Microsoft Windows (like Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP), Apple's macOS (formerly OS X), Chrome OS, BlackBerry Tablet OS, and flavors of Linux, an open-source operating system.
Your smartphone runs a mobile operating system, probably either Apple's iOS or Google's Android. Both are household names but you may not have realized that they are the operating systems running on those devices.
Servers, like those that host the websites you visit or serve the videos you watch, typically run specialized operating systems, designed and optimized to run the special software required to make them do what they do. Some examples include Windows Server, Linux, and FreeBSD.
Software & Operating Systems
Most software applications are designed to work with just one company's operating system, like just Windows (Microsoft) or just macOS (Apple).
A piece of software will clearly say which operating systems it supports and will get very specific if necessary. For example, a video production software program might say it supports Windows 10, Windows 8, and Windows 7, but does not support older versions of Windows like Windows Vista and XP.
Software developers also often release additional versions of their software that work with other operating systems. Coming back to the video production program example, that company might also release another version of the program with exactly the same features but that only works with macOS.
It's also important to know whether your operating system is 32-bit or 64-bit. It's a common question you're asked when downloading software. Special types of software called virtual machines can actually mimic "real" computers and run different operating systems from within them.
Operating System Errors
There are a number of ways that an operating system itself can become corrupted or damaged but these issues are relatively rare.
In Windows, the most severe is the Operating System Not Found error message and implies that one can't even be found!
Operating System Updates
All modern operating systems have a built-in mechanism to keep the software updated. In Windows, this is done through Windows Update. Other operating systems work similarly, like when you update the Android OS or install iOS updates.
Keeping an operating system up to date with the newest features is important so that you're getting the most out of what you paid for. Getting security fixes is another crucial reason to make sure your OS is always updated; this can help prevent hackers from getting into your device.
There are four types of operating systems −
- Real-time operating system
- Single-User/Single-Tasking operating system
- Single-User/Multitasking operating system
- Multi-User/Multitasking operating system
Real-time operating system
Real-time operating system is designed to run real-time applications. It can be both single- and multi-tasking. Examples include Abbasi, AMX RTOS, etc.
Advantages
- It works very fast.
- It is time saving, as it need not be loaded from memory.
- Since it is very small, it occupies less space in memory.
Single-User/Single-Tasking OS
An operating system that allows a single user to perform only one task at a time is called a Single-User Single-Tasking Operating System. Functions like printing a document, downloading images, etc., can be performed only one at a time. Examples include MS-DOS, Palm OS, etc.
Advantages
- This operating system occupies less space in memory.
Disadvantages
- It can perform only a single task at a time.
Single-User/Multitasking OS
An operating system that allows a single user to perform more than one task at a time is called Single-User Multitasking Operating System. Examples include Microsoft Windows and Macintosh OS.
Advantages
- It is time saving as it performs multiple tasks at a time yielding high productivity.
Disadvantages
- This operating system is highly complex and occupies more space.
Multiuser/Multitasking OS
It is an operating system that permits several users to utilize the programs that are concurrently running on a single network server. The single network server is termed as "Terminal server". "Terminal client" is a software that supports user sessions. Examples include UNIX, MVS, etc.
Advantages
- It is highly productive as it performs multiple tasks at a time.
- It is time saving as we don’t have to make changes in many desktops, instead can make changes only to the server.
Disadvantages
- If the connection to the server is broken, user cannot perform any task on the client as it is connected to that server.