Chapter 1
Chapter 1
Objectives
1.2
What is an Operating System?
1.3
Operating Systems
1.4
Android
1.5
Computer System Structure
1.6
Four Components of a Computer System
1.7
Operating System Definition
OS is a resource allocator
Manages all resources
Decides between conflicting requests for efficient and fair
resource use.
OS control program
Controls the execution of programs to prevent errors and
improper use of the computer.
“The program running at all times on the computer” is the
kernel.
Everything else is either
a system program (ships with the operating system) , or
an application program.
1.8
Components of operating system
Kernel
Shell
Other program
Or
Process management, memory management, file
management, storage management, security
management components, etc.
1.9
Kernel
Kernel is the heart of an operating system.
It allocates the system resources and coordinate all the details
of the computer's internals.
It interacts with the hardware and perform most of the tasks
like;
memory management,
task scheduling,
file management,
input and output requests handling
access CPU and peripheral device like hard disk, DVD,
RAM, Printers, etc.
1.10
Shell
1.12
Functions of an OS
User Environment - OS layer transforms bare hardware machine into higher level
abstractions.
Execution environment –to run other programs.
process management, file manipulation, interrupt handling, I/O operations.
Error detection and handling- internal and external hardware errors and
various software errors.
Make the response that clears the error condition with least impact on the
user
Security- enforce security through abstraction.
Access Control: regulating user access to the total system, subsystem
and data. And process access to various resources and objects.
Information flow control: flow of data within the system.
Securing a system against internal and external attacks.
Communication : message sending and receiving.
Message passing
Shared memory
1.13
Functions of an OS
Resource Management
Time management
CPU and disk transfer scheduling
Space management
main and secondary storage allocation
Synchronization and deadlock handling
IR, PC, critical section
Accounting and status information
resource usage tracking
Collect usage statistics
Monitor performance
1.14
Computer Startup
1.15
Computer-System Architecture
Most systems use a single general-purpose processor.
Most systems have special-purpose processors as well
Multiprocessors systems are growing in use and importance.
Also known as parallel systems, tightly-coupled systems
Advantages include:
1. Increased throughput: more work with less time
2. Economy of scale: save money than single-core type
because it used shared resources.
3. Increased reliability – graceful degradation or fault tolerance
Two types:
1. Asymmetric Multiprocessing – each processor is assigned a
specific task.
a master processor controls the system, scheme defines a
master-slave relationship
2. Symmetric Multiprocessing – each processor performs all tasks.
processor runs an identical copy of the operating system and
communicate with one another
1.16 as needed.
What Operating Systems Do
1.17
Operating-System Operations
1.18
Operating-System Operations
Timer to prevent infinite loop / process hogging resources
Timer is set to interrupt the computer after some time period
Keep a counter that is decremented by the physical clock.
Operating system set the counter (privileged instruction)
When counter zero generate an interrupt
Set up before scheduling process to regain control or terminate program
that exceeds allotted time
1.19
Operating-System Operations (cont.)
1.20
Transition from User to Kernel Mode
1.21
Types of Operating System
1.22
Types of OS
Serial processing OS
Batch OS
Multi-programmed OS
Multi-tasking /Time sharing OS
Multiprocessors OS
Real time OS
Network OS
Distributed OS
1.23
1.24
1.25
1.26
1.27
1.28
1.29
1.30
1.31
Cont…
Real-Time Systems : is used when rigid time
1.34
1.35
1.36
Characteristic of Modern OS
1.37