0% found this document useful (0 votes)
26 views

Unit 1 CHP 1

An operating system (OS) acts as an interface between the user and computer hardware. The document discusses the key components of a computer system including the hardware, OS, application programs, and users. It describes the functions of the OS such as process management, memory management, file management, and device management. The OS controls and coordinates the use of hardware, runs user programs, and makes the computer system convenient to use while ensuring efficient use of resources.

Uploaded by

Priya Nagwekar
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views

Unit 1 CHP 1

An operating system (OS) acts as an interface between the user and computer hardware. The document discusses the key components of a computer system including the hardware, OS, application programs, and users. It describes the functions of the OS such as process management, memory management, file management, and device management. The OS controls and coordinates the use of hardware, runs user programs, and makes the computer system convenient to use while ensuring efficient use of resources.

Uploaded by

Priya Nagwekar
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 44

BSC Semester 3 – Operating

Systems
Unit 1 - Chapter 1
What is Operating System
Computer System = Hardware + Software

Software = Application Software + System Software(OS)

An Operating System is a system Software that acts as an


intermediary/interface between a user of a computer and the computer
hardware.
What is Operating System
• A program that acts as an intermediary
between a user of a computer and the
computer hardware
• Operating system goals:
• Execute user programs and make solving
user problems easier
• Make the computer system convenient to
use
• Use the computer hardware in an
efficient manner
Structure of Operating System
• Computer system can be divided into four components:
• Hardware – provides basic computing resources
• CPU, memory, I/O devices
• Operating system
• Controls and coordinates use of hardware among
various applications and users
• Application programs – define the ways in which the
system resources are used to solve the computing
problems of the users
• Word processors, software compilers, web
browsers, database systems, video games
• Users
• People, machines, other computers
Components of Computer System
Operating System mode

• The User Mode is concerned with the actual interface between the
user and the system.
• It controls things like running applications and accessing files.
• The Kernel Mode is concerned with everything running in the
background.
• It controls things like accessing system resources, controlling
hardware functions and processing program instructions.
• System calls are used to change mode from User to Kernel.
What Operating System can do
• Depends on the point of view
• Users want convenience, ease of use and good
performance
• Don’t care about resource utilization
• But shared computer such as mainframe or
minicomputer must keep all users happy
• Users of dedicate systems such as workstations have
dedicated resources but frequently use shared
resources from servers
• Handheld computers are resource poor, optimized for
usability and battery life
• Some computers have little or no user interface, such
as embedded computers in devices and automobiles
Computer System Organization
• Computer-system operation
• One or more CPUs, device controllers connect through common
bus providing access to shared memory
• Concurrent execution of CPUs and devices competing for memory
cycles
Computer system Operation

• I/O devices and the CPU can execute concurrently

• Each device controller is in charge of a particular device type

• Each device controller has a local buffer

• CPU moves data from/to main memory to/from local buffers

• I/O is from the device to local buffer of controller

• Device controller informs CPU that it has finished its

operation by causing an interrupt


I/O Structure
• I/O devices and the CPU can execute concurrently
• Each device controller is in charge of a particular
device type
• Each device controller has a local buffer
• CPU moves data from/to main memory to/from
local buffers
• I/O is from the device to local buffer of controller
• Device controller informs CPU that it has finished
its operation by causing an interrupt
Storage Structure
• Main memory – only large storage media that the CPU can access
directly
• Random access
• Typically volatile
• Secondary storage – extension of main memory that provides large
nonvolatile storage capacity
• Hard disks – rigid metal or glass platters covered with magnetic
recording material
• Disk surface is logically divided into tracks, which are subdivided
into sectors
• The disk controller determines the logical interaction between the
device and the computer
• Solid-state disks – faster than hard disks, nonvolatile
• Various technologies
• Becoming more popular
Storage Hierarchy
• Storage systems organized in hierarchy
• Speed
• Cost
• Volatility
• Caching – copying information into faster storage system;
main memory can be viewed as a cache for secondary
storage
• Device Driver for each device controller to manage I/O
• Provides uniform interface between controller and
kernel
Storage Hierarchy
Caching
• Important principle, performed at many levels in a
computer (in hardware, operating system,
software)
• Information in use copied from slower to faster
storage temporarily
• Faster storage (cache) checked first to determine if
information is there
• If it is, information used directly from the cache
(fast)
• If not, data copied to cache and used there
• Cache smaller than storage being cached
• Cache management important design problem
• Cache size and replacement policy
How Computer Work
In summary-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
Features of Operating System 19

 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
Functions of Operating System 20
Functions of Operating System 21

• Process Management
• A process is a program in execution.
• A process needs certain resources, including CPU time, memory, files, and I/O devices to
accomplish its task.
• Simultaneous execution leads to multiple processes. Hence creation, execution and
termination of a process are the most basic functionality of an OS
• If processes are dependent, than they may try to share same resources. thus task of process
synchronization comes to the picture.
• If processes are independent, than a due care needs to be taken to avoid their overlapping in
memory area.
• Based on priority, it is important to allow more important processes to execute first than
others.
Functions of Operating System 22

• Memory Management
• Memory is a large array of words or bytes, each with its own address.
• It is a repository of quickly accessible data shared by the CPU and I/O devices.
• Main memory is a volatile storage device. When the computer made turn off
everything stored in RAM will be erased automatically.
• In addition to the physical RAM installed in your computer, most modern operating
systems allow your computer to use a virtual memory system. Virtual memory allows
your computer to use part of a permanent storage device (such as a hard disk) as
extra memory.
• The operating system is responsible for the following activities in connections with
memory management:
Keep track of which parts of memory are currently being used and by whom.
Decide which processes to load when memory space becomes available.
Allocate and de-allocate memory space as needed.
Functions of Operating System 23
• File Management
• A file is a collection of related information defined by its creator.
• File systems provide the conventions for the encoding, storage and management of data on a storage
device such as a hard disk.
 FAT12 (floppy disks)
 FAT16 (DOS and older versions of Windows)
 FAT32 (older versions of Windows)
 NTFS (newer versions of Windows)
 EXT3 (Unix/Linux)
 HFS+ (Max OS X)
• The operating system is responsible for the following activities in connections with file management:
✦ File creation and deletion.
✦ Directory creation and deletion.
✦ Support of primitives for manipulating files and directories.
✦ Mapping files onto secondary storage.
✦ File backup on stable (nonvolatile) storage media.
Functions of Operating System 24

• Device Management
• Device controllers are components on the motherboard (or on expansion cards) that act as an interface
between the CPU and the actual device.
• Device drivers, which are the operating system software components that interact with the devices
controllers.
• A special device (inside CPU) called the Interrupt Controller handles the task of receiving interrupt
requests and prioritizes them to be forwarded to the processor.
• Deadlocks can occur when two (or more) processes have control of different I/O resources that are
needed by the other processes, and they are unwilling to give up control of the device.
• It performs the following activities for device management.
 Keeps tracks of all devices connected to system.
 Designates a program responsible for every device known as Input/output controller.
 Decides which process gets access to a certain device and for how long.
 Allocates devices in an effective and efficient way.
 Deallocates devices when they are no longer required. 
Functions of Operating System 25
• Security and Protection
• The operating system uses password protection to protect user data and similar
other techniques.
• It also prevents unauthorized access to programs and user data by assigning
access right permission to files and directories.
• The owners of information stored in a multiuser or networked computer system
may want to control use of that information, concurrent processes should not
interfere with each other.
Functions of Operating System 26

• A user interface (UI) controls how you enter data and instructions and how
information is displayed on the screen
• There are two types of user interfaces
• Command Line Interface
• Graphical user Interface
Functions of Operating System 27

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.
Command interpretation:- This module is interpreting commands given by and acting system
resources to process that commands.
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.
Job accounting:- Keeping track of time & resource used by various job and users.
Communication management:- Coordination and assignment of compilers, interpreters, and
another software resource of the various users of the computer systems.
Resource Abstraction
 What is Resource?
 The OS treats any entity as a resource if it satisfies following
characteristics:
 A process must request that entity from the OS.
 A process must suspend its operation until the entity is allocated
to it.
 Anything like CPU cycle, Main memory, printer…..
 Similar resources can be abstracted to a common abstract resource
interface (i.e. system software may abstract floppy disks, hard-disks
and CD-ROMs into a single abstract disk interface).
 Abstraction generalizes the hardware behaviour but restricts the
flexibility.
 With abstraction, certain operations become easier to perform, other
may become impossible (such as specific hardware control).
 Different hardware components that a program may use are referred
to as resources.
 Any particular resource, such as a HDD has a generic interface that
defines how the programmer can make the resource perform a desired
operation.
 An abstraction can be made to be much simpler than the actual
resource interface.
Resource Abstraction

 Resource abstraction is the process of "hiding the


details of how the hardware operates, thereby
making computer hardware relatively easy for an
application programmer to use".
 One way in which the operating system might
implement resource abstraction is to provide a single
abstract disk interface which will be the same for
both the hard disk and floppy disk.
 Such an abstraction saves the programmer from
needing to learn the details of both hardware
interfaces.
 Instead, the programmer only needs to learn the
disk abstraction provided by the operating system.
Types of Operating System 30

1. Batch Operating System


2. Multiprogramming Operating System
3. Time-Sharing OS
4. Multiprocessing OS
5. Distributed OS
6. Network OS
7. Real Time OS
8. Embedded OS
Types of Operating System 31
1. 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.
Types of Operating System 32

Advantages of Batch Operating System: 


 Processors of the batch systems know how long the job would be when it is in
queue
 Multiple users can share the batch systems
 The idle time for the batch system is very less
 It is easy to manage large work repeatedly in batch systems
Disadvantages of Batch Operating System:  
 The computer operators should be well known with batch systems
 Batch systems are hard to debug
 It is sometimes costly
 The other jobs will have to wait for an unknown time if any job fails
Examples of Batch based Operating System:
IBM's MVS
Types of Operating System 33

2.Multiprogramming Operating System
• This type of OS is used to execute more than one jobs simultaneously by a single processor.
• It increases CPU utilization by organizing jobs so that the CPU always has one job to execute.
• Multiprogramming operating systems use the mechanism of job scheduling and CPU scheduling.
Types of Operating System 34

2.Multiprogramming System

 Multiprogramming is also the ability of an operating system to execute more


than one program on a single processor machine.
 More than one task/program/job/process can reside into the main memory at
one point of time.
 A computer running Excel and Firefox browser simultaneously is
an example of multiprogramming.
Types of Operating System 35

3. Multi-Tasking/Time-sharing Operating systems


• Each task is given some time to execute so that all the tasks work smoothly.
• These systems are also known as Multi-tasking Systems.
• The task can be from a single user or different users also.
• The time that each task gets to execute is called quantum.
• After this time interval is over OS switches over to the next task. 
Types of Operating System 36

3. 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.
 In other words, time sharing refers to the allocation
of computer resources in time slots to several
programs simultaneously.
 For example a mainframe computer that has many
users logged on to it. Each user uses the resources of
the mainframe -i.e. memory, CPU etc.
Types of Operating System 37

3. Multi-Tasking/Time-sharing Operating systems

Advantages of Time-Sharing OS:  


Each task gets an equal opportunity
Fewer chances of duplication of software
CPU idle time can be reduced
Disadvantages of Time-Sharing OS:  
Reliability problem
One must have to take care of the security and integrity of user programs and data
Data communication problem
Examples of Time-Sharing Oss
Multics, Unix, etc. 
Types of Operating System 38

4. Multiprocessor operating systems


• Multiprocessor operating systems are also known as parallel OS or tightly coupled OS.
• Such operating systems have more than one processor in close communication that sharing
the computer bus, the clock and sometimes memory and peripheral devices.
• It executes multiple jobs at the same time and makes the processing faster.
• It supports large physical address space and larger virtual address space.
• If one processor fails then other processor should retrieve the interrupted process state so
execution of process can continue.
• Inter-processes communication mechanism is provided and implemented in hardware.
Types of Operating System 39
5. Distributed Operating system
• Various autonomous interconnected computers communicate with each other using a
shared communication network.
• Independent systems possess their own memory unit and CPU.
• These are referred to as loosely coupled systems.
• Examples:- Locus, DYSEAC
Types of Operating System 40
6. Networked Operating system
• These systems run on a server and provide the capability to manage data, users,
groups, security, applications, and other networking functions.
• These types of operating systems allow shared access of files, printers, security,
applications, and other networking functions over a small private network.
• The “ other" computers arc called client computers, and each computer that
connects to a network server must be running client software designed to request a
specific service.
• Popularly known as tightly coupled systems. 
Types of Operating System 41
6. Networked Operating system
Advantages of Network Operating System:  
 Highly stable centralized servers
 Security concerns are handled through servers
 New technologies and hardware up-gradation are easily integrated into the system
 Server access is possible remotely from different locations and types of systems
Disadvantages of Network Operating System:  
 Servers are costly
 User has to depend on a central location for most operations
 Maintenance and updates are required regularly
Examples of Network Operating System are:
Microsoft Windows Server 2003/2008/2012, UNIX, Linux, Mac OS X, Novell NetWare,
and BSD, etc. 
Types of Operating System 42
7. Real time Operating system
• These types of OSs serve real-time
systems.
• The time interval required to process and
respond to inputs is very small.
• This time interval is called response time. 
• Real-time systems are used when there
are time requirements that are very strict
like
 missile systems,
 air traffic control systems,
 robots, etc. 
Types of Operating System 43
7. Embedded Operating system
• An embedded operating system is one that is built into the circuitry of an electronic
device.
• Embedded operating systems are now found in automobiles, bar-code scanners, cell
phones, medical equipment, and personal digital assistants.
• The most popular embedded operating systems for consumer products, such as
PDAs, include the following:
 Windows XP Embedded
 Windows CE .NET:- it supports wireless communications, multimedia and Web
browsing. It also allows for the use of smaller versions of Microsoft Word,
Excel, and Outlook.
 Palm OS:- It is the standard operating system for Palm-brand PDAs as well as
other proprietary handheld devices.
 Symbian:- OS found in “ smart” cell phones from Nokia and Sony Ericsson
THANK YOU!

Patkar Varde College,


Piramal Nagar, Goregaon West,
Mumbai, Maharashtra 400062.

+91 9920053700 [email protected] www.sdbi.in

You might also like