1/351
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
Operating System (O/S)
- Programs that integrate hardware resources of computer
- Makes resources available to user efficiently
Efficiency in O/S is measured through...?
1. Functionality
2. Performance: Time and Utilization
3. Convenience and Cost
OS is a layer of _______ between ___ and _____
layer of abstraction between the hardware and software
OS Role
1. Resource Coordinator
2. Virtual machine
3. Reactive system
Operating Systems Ease the Pain
Performs interface task w/ hardware (file operations, memory paging) which the user does if OS didn't exist
The OS makes visible the _______ component of the system
virtual
The O/S does the ff. except...
A. Middleman between hardware and software
B. Resource divider
C. Reactive system
D. Being a real machine
D. Being a real machine
It's a virtual machine
Multiuser Capability
Multiple users can access resources at the same time
Interaction of Programs and Other Apps
OS allows program interaction with different applications
Why are Operating Systems Difficult to Create and Maintain?
1. Size
2. Lifetime
3. Complexity
4. Multitasking
5. General purpose
OS Difficult to Create and Maintain: Size
- Too big for one person
- Current systems have so many lines of code and involve 10-100 man years to build
OS Difficult to Create and Maintain: Lifetime
- OS remain longer than the makers
- Code is written and rewritten so original intent is forgotten
OS Difficult to Create and Maintain: Complexity
System do difficult things:
- deal w/ ugly I/O devices
- multiplexing / juggling act
- handle errors
OS Difficult to Create and Maintain: Multitasking
Do several tasks at once
Early 1950's, Mainframes Rule
- Early systems
- No O/S
- Programmer = operator
- Large machines run from a console
- Programs loaded via switches & card readers
What were the first real OS?
Simple batch systems
Batch Processing
- O/S was a program stored in one part of memory
- Loads a job from card reader into memory
- Transfers control from one job to the next
Problem in Batch Processing
- Setup time
- Operators hired, ran related jobs together (very labor intensive)
Offline Processing
- Tape contains code
- Tape is read but don't know what output tape says
- Only see output after tape is read
What does spool stand for?
Simultaneous Peripheral Operation On-Line
Spooling
- Jobs can be read ahead onto disk
- Read line by line
Multiprogrammed Systems
- Increased utilization
- Keeps several jobs in memory simultaneously
- Needs CPU scheduling
- Analogy: lawyer working on several cases
Multiprogrammed Systems Overlapping of jobs
I/O processing of a job overlaps w/ computation of another job
Timesharing System optimizes ____?
Reponse Time
All computers have same efficiency and throughput so processor memory is divided among computers
Timesharing System is based on ____?
Time-slicing
Dividing CPU time among multiple processes
Timesharing System
Allows multiple users to interact with a single processor
Desktop Systems
- First appeared in 1970
- Popularly known as personal computers (PCs)
- Advancement in hardware allowed downsizing from expensive mainframes
Multiprocessor Systems is also known as ___?
Parallel systems
Tightly-coupled systems
Multiprocessor Systems
Systems with multiple CPUs working together
Can be Asymmetric or Symmetric
Advantages of Multiprocessor Systems
1. Increased throughput (more CPUs = more work in less time)
2. Economy of scale (saves money, CPUs share peripherals)
3. Increased reliability (redundancy and fault tolerance)
Asymmetric Multiprocessing
each CPU has specific role (usually master-slave)
Symmetric Multiprocessing (SMP)
All CPUs do same thing
Multicore System
Instead of multiple processors in 1 set up, processors are divided into cores (each with own cache line) for tasks
Distributed (Loosely-Coupled) Systems
CPUs assigned specific roles in processing.
What does Distributed (Loosely-Coupled) Systems allow?
- Geographically-distributed computing resources
- Communications between parts of a job or diff. jobs
- Resource sharing
Client-Server Systems
Architecture where clients request services from servers
Peer-to-Peer Systems
Decentralized network where each node shares resources
What kind of architecture is Distributed (Loosely-Coupled) Systems?
Peer-to-peer systems
Clustered Systems
- Multiple CPUs linked and collab to perform tasks
- Shared storage (data) via LAN
Real Time Systems
Systems responding to physical events within fixed time
Applications for Real Time Systems
subway systems
flight-control
factories
power plants
Problems with Real Time Systems
Need to schedule activities to meet time constraints
Hard Real Time System
Critical deadlines for controlling devices
Soft Real Time System
Important deadlines, less critical than hard systems.
Handheld Systems
PDAs and cellphones
Problems with Handheld Systems
1. Limited main memory
2. Processor speed
3. Small display screens
General Structure of an O/S: 2 types of programs
1. Resident
2. Non-resident
Resident Programs
Programs which are critical to the operation of the system
Embedded in system
Allow PC to work
Non-Resident Programs
Programs loaded into memory as needed
Located in disks or bulky storage devices
Kernel
Computer program in core of computer OS
Complete control over everything in the system
Prevents and handles conflicts between processes
Examples of Kernel that are memory resident components
Command interface shell
eg. ver, dir, date, time: COMMAND.COM
I/O routines that control I/O devices
e.g. BIOS: IO.SYS
File Management System
e.g. MSDOS.SYS
Examples of Kernel that are non-resident components
FORMAT, FDISK
Stuff you plug to OS
Dual-Mode Operation
System operates in user and kernel modes
User Mode
System executes task for user
Kernel Mode
- System executes task for OS
- Executes privileged instructions
- Default at boot time
Privileged Instructions
Special instructions only executable in kernel mode
Bit changes depending on the mode
0 = go to kernel
1 = returns to user
If you request an O/S service, which is correct?
A. User to Kernel
B. Kernel to User
A. User to Kernel
8 OS Components
1. Process management
2. Main memory management
3. File management
4. I/O system management
5. Secondary storage management
6. Networking
7. Protection System
8. Command Interpreter System
Process management
- create
- delete
- suspend
- resume processes
- synchronize communications
- handle deadlocks
- possible support threads
Main Memory Management
Tracks memory use
Allocates / deallocates memory
Decide which processes to load when there’s available space
File Management
Tracks available space
Maintains file info and directory structure
Support file manipulation commands
I/O System Management
- Allows access to devices
- Use of device drivers for modularity
Secondary Storage Management
- Storage allocation
- Free space management
- Disk scheduling
Networking
- Transfer protocols
- Routing & connection strategies
Protection System
- Mechanism for controlling access to programs, processes, or users
- For multitasking and multiuser systems
Command Interpreter System
User interaction via command line, GUI, touch, voice, etc.
OS Architectures
1. Monolithic
2. Layered
3. Virtual Machine
4. Microkernel
Which O/S architecture is the easiest to implement?
Monolithic
Monolithic Architecture
- Virtually no structure
- Kernel = 1 big structure
- Procedures visible to each other
Layered Architecture
- Hard to implement bc functionalities are mutually dependent
- Inefficient bc many traversals
- Many checks to pass bc many layers to reach destination
Virtual Machine Architecture
- Many systems in 1 machine
- No resource management and responsiveness
Order of parts in
Virtual Machine Architecture
process -> kernels -> virtual machine -> hardware
- This allows things to run very fast
Microkernel Architecture
Takes as much functionality as possible from kernel
Allows modularity and portability across platforms
Efficient
Small monolithic kernel but user & system processes divided into user mode
Architecture of Systems Today
Monolithic w/ hybrid of microkernel
Non OS components controlled by user instead
When and where was the first version of Unix developed?
(1969)
Research Group in Bell Labs
Who developed the 1st version of UNIX?
Ken Thompson
What hardware was used to create UNIX?
PDP-7 (which was idle at that time)
Who joined Ken Thompson?
Dennis Ritchie (worked on MULTICS)
What hardware did Ritchie and Thompson use to create the 2nd version?
PDP-11/20
What did Ritchie and Thompson use for the 3rd version of UNIX?
C (developed in Bell Labs to support Unix) instead of assembly language
What enhancements were added to UNIX in version 4/5?
Multiprogramming
Run multiple programs at the same time
What hardware did Ritchie and Thompson use for the 4th/5th version of UNIX?
PDP-11/45 and PDP-11/70 (both support multiprogramming)
Version 6 Unix
(1976)
1st version distributed outside of Bell Labs
Version 7 Unix
(1978)
- Ancestor of most Unix systems
- Ported to VAX (appeared as 32V)
What hardware was used for version 7 of UNIX?
Developed for the PDP-11/70 and Interdata 8/32
Who produced the 3BSD Unix?
Bill Joy & Ozalp Babaoglu
Berkeley Software Distributions (BSD)
- 1st implementation of such functionality
- Allowed big programs to run in Unix
DARPA
Defense Advanced Researched Projects Agency
4BSD
Goal: Provide networking for DARPA Internet networking protocols (TCP/IP)
4.2BSD Release
- Communicate among diverse network facilities (LANs, WANs)
- New user interface = C shell
- New text editor = vi
4.2 BSD in 1984
60 connected networks
4.2 BSD in 1993
8,000 connected networks, 10 million users
What was the last Berkeley release?
1993
4.4 BSD
4.4BSD Release
- x.25 networking
- new file system organization
- enhanced security
- improved kernel structure
Unix Standardization Projects
Efforts by IEEE, ISO, and ANSI for Unix environments.
Unix Design Principles focus
Time-sharing system
Allows multiple processes
Simple
Kernel provides some functionality
Source code provided
Unix Design Principles later use
Networking, graphics, real-time operation
Needed a lot of code (double size of system)
System remained Unix
Unix Shell
Command interpreter
Executes user-written and system programs
Surrounds kernel
Users can write own shell
Popular command line shells
Bourne shell (Steve Bourne)
C shell (Bill Joy, BSD systems)
Korn shell (Dave Korn, C & Bourne combo)