Chapter 1 Introduction
Chapter 1 Introduction
•Operating System Concepts – 9th Edit9on • Silberschatz, Galvin and Gagne ©2013
Contents
What Operating Systems Do
Computer-System Organization
Computer-System Architecture
Operating-System Structure
Operating-System Operations
Computing Environments
Open-Source Operating Systems
•Operating System Concepts – 9th Edition • 1.2 • Silberschatz, Galvin and Gagne ©2013
Objectives
systems
of operating systems
computing environments
To explore several open-source operating systems
•Operating System Concepts – 9th Edition • 1.3 • Silberschatz, Galvin and Gagne ©2013
What is an Operating System?
Operating system goals:
Execute user programs and make solving
manner
•Operating System Concepts – 9th Edition • 1.4 • Silberschatz, Galvin and Gagne ©2013
Computer System Structure
Computer system can be divided into four components:
Hardware – provides basic computing resources
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, compilers, web browsers,
database systems, video games
Users
People,
•Operating System Concepts – 9th Edition machines, other computers•
• 1.5 Silberschatz, Galvin and Gagne ©2013
Four Components of a Computer System
•Operating System Concepts – 9th Edition • 1.6 • Silberschatz, Galvin and Gagne ©2013
What Operating Systems Do
Depends on the point of view
Users want convenience, ease of use
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
•Operating System Concepts – 9th Edition • 1.7 • Silberschatz, Galvin and Gagne ©2013
Operating System Definition
OS is a resource allocator
Manages all resources
OS is a control program
Controls execution of programs to prevent errors
•Operating System Concepts – 9th Edition • 1.8 • Silberschatz, Galvin and Gagne ©2013
Operating System Definition (Cont.)
No universally accepted definition
•Operating System Concepts – 9th Edition • 1.9 • Silberschatz, Galvin and Gagne ©2013
Computer Startup
bootstrap program is loaded at power-up or reboot
Typically stored in ROM or EPROM, generally known as
firmware
Initializes all aspects of system
•Operating System Concepts – 9th Edition • 1.10 • Silberschatz, Galvin and Gagne ©2013
Computer System Organization
Computer-system operation
One or more CPUs, device controllers connect through
memory cycles
•Operating System Concepts – 9th Edition • 1.11 • Silberschatz, Galvin and Gagne ©2013
Computer-System Operation
I/O devices and the CPU can execute concurrently
device type
Each device controller has a local buffer
buffers
I/O is from the device to local buffer of controller
Interrupt architecture must save the address of the
interrupted instruction
An operating system is interrupt driven
•Operating System Concepts – 9th Edition • 1.13 • Silberschatz, Galvin and Gagne ©2013
Interrupt Handling
Determines which type of interrupt has occurred:
polling
•Operating System Concepts – 9th Edition • 1.14 • Silberschatz, Galvin and Gagne ©2013
Direct Memory Access Structure
Used for high-speed I/O devices able to transmit
information at close to memory speeds
Device controller transfers blocks of data from buffer
storage directly to main memory without CPU
intervention
Only one interrupt is generated per block, rather than
the one interrupt per byte
•Operating System Concepts – 9th Edition • 1.15 • Silberschatz, Galvin and Gagne ©2013
How a Modern Computer Works
•Operating System Concepts – 9th Edition • 1.16 • Silberschatz, Galvin and Gagne ©2013
Batch operating system
The users of batch operating system do not interact with the computer directly.
Each user prepares his job on an off-line device like punch cards and submits
it to the computer operator.
To speed up processing, jobs with similar needs are batched together and run
as a group. Thus, the programmers left their programs with the operator.
The operator then sorts programs into batches with similar requirements.
•Operating System Concepts – 9th Edition • 1.17 • Silberschatz, Galvin and Gagne ©2013
Operating System Structure
Multiprogramming needed for efficiency
Single user cannot keep CPU and I/O devices busy at all times
Multiprogramming organizes jobs (code and data) so CPU always has one to
execute
A subset of total jobs in system is kept in memory
One job selected and run via job scheduling
When it has to wait (for I/O for example), OS switches to another job
Timesharing (multitasking) is logical extension in which CPU switches jobs so
frequently that users can interact with each job while it is running, creating
interactive computing
Response time should be < 1 second
Processor's time which is shared among multiple users simultaneously is
termed as time-sharing.
Each user has at least one program executing in memory process
If several jobs ready to run at the same time CPU scheduling
If processes don’t fit in memory, swapping moves them in and out to run
Virtual memory allows execution of processes not completely in memory
•Operating System Concepts – 9th Edition • 1.18 • Silberschatz, Galvin and Gagne ©2013
Memory Layout for Multiprogrammed System
•Operating System Concepts – 9th Edition • 1.19 • Silberschatz, Galvin and Gagne ©2013
The main difference between Multiprogrammed Batch
Systems and Time-Sharing Systems is that in case of
multiprogrammed batch systems, objective is to maximize
processor use, whereas in Time-Sharing Systems objective is to
minimize response time.
•Operating System Concepts – 9th Edition • 1.20 • Silberschatz, Galvin and Gagne ©2013
Operating-System Operations
Interrupt driven by hardware
components
User mode and kernel mode
or kernel code
Some instructions designated as privileged, only executable in
kernel mode
System call changes mode to kernel, return from call resets it to
user
•Operating System Concepts – 9th Edition • 1.21 • Silberschatz, Galvin and Gagne ©2013
Transition from User to Kernel Mode
Timer to prevent infinite loop / process hogging resources
Set interrupt after specific period
•Operating System Concepts – 9th Edition • 1.22 • Silberschatz, Galvin and Gagne ©2013
Computing Environments – Cloud Computing
Delivers computing, storage, even apps as a service across a network
Logical extension of virtualization as based on virtualization
Amazon EC2 has thousands of servers, millions of VMs, PBs of
storage available across the Internet, pay based on usage
Many types
Public cloud – available via Internet to anyone willing to pay
Private cloud – run by a company for the company’s own use
Hybrid cloud – includes both public and private cloud components
Software as a Service (SaaS) – one or more applications available
via the Internet (i.e. word processor)
Platform as a Service (PaaS) – software stack ready for application
use via the Internet (i.e a database server)
Infrastructure as a Service (IaaS) – servers or storage available over
Internet (i.e. storage available for backup use)
•Operating System Concepts – 9th Edition • 1.23 • Silberschatz, Galvin and Gagne ©2013
Computing Environments – Cloud Computing
•Operating System Concepts – 9th Edition • 1.24 • Silberschatz, Galvin and Gagne ©2013
Computing Environments – Real-Time Embedded Systems
Use expanding
•Operating System Concepts – 9th Edition • 1.25 • Silberschatz, Galvin and Gagne ©2013
Computing Environments – Real-Time Embedded Systems
•Operating System Concepts – 9th Edition • 1.26 • Silberschatz, Galvin and Gagne ©2013
Distributed operating System
Distributed systems use multiple central processors
to serve multiple real time application and
multiple users. Data processing jobs are distributed
among the processors accordingly to which
one can perform each job most efficiently.
•Operating System Concepts – 9th Edition • 1.27 • Silberschatz, Galvin and Gagne ©2013
Distributed operating System
•Operating System Concepts – 9th Edition • 1.28 • Silberschatz, Galvin and Gagne ©2013
Network operating System
Network Operating System runs on a server and and provides server the capability to
manage data, users, groups, security, applications, and other networking functions.
The primary purpose of the network operating system is to allow shared file
and printer access among multiple
computers in a network, typically a local area network (LAN), a private network or to oth
networks. Examples of network operating systems are Microsoft Windows Server 2003,
Microsoft Windows Server 2008, UNIX, Linux, Mac OS X, Novell NetWare, and BSD.
•Operating System Concepts – 9th Edition • 1.29 • Silberschatz, Galvin and Gagne ©2013
Open-Source Operating Systems
binary closed-source
movement
•Operating System Concepts – 9th Edition • 1.30 • Silberschatz, Galvin and Gagne ©2013
End of Chapter 1
•Operating System Concepts – 9th Edit9on • Silberschatz, Galvin and Gagne ©2013