Monday, November 12, 2007

Chapter 1-Introduction

What is an Operating System?

Mainframe Systems
Desktop Systems
Multiprocessor Systems
Distributed Systems

System View of Operating System
Resource allocator: decide how to allocate resources to specific programs and users efficiently and fairly
Control program: mange the execution of user programs to prevent errors and improper use of the computer

What Makes Up an OS?
Common definition: the one program running at all times (usually called kernel).
System programs are sometimes considered part of OS
Provide a convenient environment for program development and execution
E.g., text editors, compilers, assemblers, linkers, debuggers

System Goals
Convenience for the user (PCs)
Efficient operation of the computer system (large multiuser systems)
maximize resource utilization
fair use of resources


Mainframe Systems
Simple batch systems
Multiprogrammed batch systems
Time-sharing systems

Simple Batch Systems
User prepare a job and submit it to a computer operator
User get output some time later
No interaction between the user and the computer system
Operator batches together jobs with similar needs to speedup processing
Task of OS: automatically transfers control from one job to another.
OS always resident in memory

Disadvantages of one job at a time:
CPU idle during I/O
I/O devices idle when CPU busy

Multiprogrammed Batch Systems
Keep more than one job in memory simultaneously
When a job performs I/O, OS switches to another job
Increase CPU utilization
All jobs enter the system kept in the job pool on a disk, scheduler brings jobs from pool into memory

Time-Sharing Systems
Like multiprogrammed batch, except CPU switches between jobs occur so frequently that the users can interact with a running program
User give instructions to the OS or a program, and wait for immediate results
Require low response time
Allow many users to share the computer simultaneously, users have the impression that they have their own machine
CPU is multiplexed among several jobs that are kept in memory and on disk

Desktop Systems
Personal computers – computer system dedicated to a single user.
CPU utilization not a prime concern, want maximize user convenience and responsiveness.
Can adopt technologies developed for mainframe operating systems: virtual memory, file systems, multiprogramming
File protection needed due to interconnections of computers
Operating systems for PCs: Windows, Mac OS, Linux

Multiprocessor Systems
Also known as parallel systems or tightly coupled systems
More than one processor in close communication, sharing computer bus, clock, memory, and usually peripheral devices
Communication usually takes place through the shared memory.

Advantages
Increased throughput: speed-up ratio with N processors <>
Economy of scale: cheaper than multiple single-processor systems
Increased reliability: graceful degradation, fault tolerant

Multiprocessor Systems
1. Symmetric multiprocessing (SMP)
Each processor runs an identical copy of the operating system
All processors are peers: any processor can work on any task
OS can distribute load evenly over the processors.
Most modern operating systems support SMP

2. Asymmetric multiprocessing
Master-slave relationship: a master processor controls the system, assigns works to other processors
Each processor is assigned a specific task
Don't have the flexibility to assign processes to the leastloaded CPU
More common in extremely large systems

Distributed Systems
Loosely coupled system – each processor has its own local memory and clock; processors communicate with one another through a network.
Need protocol to communicate: TCP/IP is the most common and best supported protocol

Three types of networks (based on distances between nodes)
1. Local area network (LAN): exists within a room/floor/building/campus
2. Wide area network (WAN): span a country or continent
3. Metropolitan area network (MAN): span a city

Transmission media: copper wires, optical fiber, radio

Types of Distributed Systems
1. Client-server systems
Client sends requests to server
Server sends reply to client

Two types of servers
2. File servers:
allow clients to create, read, update, and delete files
Compute servers: execute actions requests by clients and send back results to clients
Peer-to-peer systems: all machines are equals, serve both as clients and servers
File-sharing networks: Gnutella, eDonkey 2000

No comments: