1/197
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
User Mode
a mode that provides an interface between an application and the OS, and only has access to hardware resources through the code running in kernel mode.
Top Down View
provide abstractions to application programs
Bottom Up View
Manage pieces of a complex system, orderly and controlled allocation of these resources
Resource Management Goals
Keep track if which programs are using which resources, mediate conflicting, requests from different programs and users
Time sharing
allocation of CPU to a program for short period, reallocate CPU to other program for short period
Space sharing
store parts of several programs in memory
Different generations of operating systems
First Generation (1945-55) vacuum tubes
Second Generation (1955-65) transistors and batch systems
Third Generation (1965-1980) ICS and Mulitprogramming
Fourth generation (1980-present) personal computer
Fifth Generation (1990-present) mobile computers
Programming in First Generation
Done by wiring up electrical circuits by connecting thousands of cables to plugholes to control machines basic functions, vacuum tubes used as switches (turned on or off in a circuit)
Batch System
a type of system developed for the earliest computers that used punched cards or tape for input, which were entered in a "batch"
Spooling
Simultaneous Peripheral Operation On-Line, reads jobs from cards onto disk when brought in.
Transistors
invented by Bell Laboratories in 1947, these tiny pieces of technology, which receive and amplify radio signals, make portable radios possible
MULTICS
Multiplexed Information and Computing Service
Minicomputers
type of computer that is designed to serve multiple users and process significant amounts of data; larger than a microcomputer, but smaller than a mainframe
UNIX
An operating system originally conceived in 1969 by Ken Thompson and Dennis Ritchie of AT&T's Bell Labs. In 1974, the UNIX code was rewritten in the standard programming language C. Today there are various commercial versions of UNIX.
Linux
an open-source version of the UNIX operating system
Processors
1. Fetches instructions from memory
2. Decodes the instruction
3. Executes instruction
Cycles until program finishes
Registers
Fast accessing storage inside the CPU
- no delay accessing any data
- least amount of space
Special Registers
-Program Counter (Address of next instruction)
-Stack Pointer (Address of top of stack)
- PSW (Program Status Word) various control bits
Multithreaded Chips
More transistors
-greater parallelism
-more cache
-deeper pipelines
-switch between threads in nanoseconds
Multicore Chips
-Each core has its own independent cpu
- allows for true parallelism
Memory Hierarchy
Cache Memory
a type of high-speed memory that a processor can access more rapidly than main memory
- main memory is divided into cache lines
L1 Cache
-inside CPU
-typically 16KB
L2 Cache
- inside CPU
-holds several megabytes
-takes one of two clock cycles to fetch
L3
- outside CPU on mother board
- feeds L2
- faster than main memory
Caching System Issues
- When to put a new item into the cache.
- Which cache lines to put the new item in.
- Which item to remove from the cache when a slot is needed
- Where to put a new evicted item in the larger memory
Main Memory
stores data and information and is usually volatile; data written and read in same amount of time regardless of location
ROM
Read Only Memory- Permanent instructions that cannot be changed.
- non-volatile
- contains bootstrap loader to start PC
- fast, inexpensive
EEPROM
Electronically Erasable Programmable Read Only Memory
- can be erased and rewritten per bytes
- non-volatile
Flash Memory
a type of EEPROM
- can be erased and rewritten in larger chunks
CMOS
complementary metal-oxide semiconductor
- volatile
-holds current time and date
Disks
a memory device consisting of a flat disk covered with a magnetic coating on which information is stored
- 1000 times slower than RAM
- Metal platters rotate at 7200 RPM
- Mechanical arm pivots over platters
- reading and writing
Solid State Disks
- Stores data in flash memory
- Less capacity than hard drives
Virtual Memory
- Possible to run programs larger than physical memory of computer
- Brings in the idea of caching
- Carried out by Memory Management Unit (part of CPU)
Controller
chip or set of chips that physically controls the device
- accepts command from operating system
-offers interface to operating system.
Device Driver
software gives commands and accepts responses, and interacts with controller.
3 Ways Driver is loaded
- Relink kernel with new driver, reboot
- Make entry into OS file telling OS to find driver and load when booted
- OS Loads driver, no reboot needed
Steps in I/O
- User make call for I/O
- Driver takes over
- Polls device to see when completed
- When completed driver deals with data
- Operating system returns control to user
- BUSY WAITING
Interrupts
device signals when complete
Buses
Communication system that transfers data between components inside a computer.
PCIe
- dedicated point to point connection
- serial bus architecture
DMI
Bus that connects hub of legacy devices to CPU
fast enough for:
-hard drive
- USB
- Ethernet
- legacy devices
Plug and Play
technology that allows a hardware component to be attached to a computer so that it is automatically configured by the operating system, without user intervention
BIOS (Basic Input/Output System)
-contains low level I/O software
-detects how much ram is installed
-detects I/O devices installed and operating
-new devices are configured
-determines boot device (usually hard disc)
-operating system read in and started
-devices drivers loaded into kernel
Mainframe Operating Systems
Room size computers
offers 3 kinds of server
-batch system-process without user interrupt
-transaction process - handles large numbers
-time sharing - allows multiple remote users
--specialized operating system used to run Mainframe
Server Operating Systems
serve multiple users at once
allowing sharing or resources
-FreeBSD
-LINUX
-Database
Kernel Mode
- operating system can execute every instruction
- operating system can use every hardware feature
Operating System
system software that acts as a "go-between", allowing computer hardware and other software to communicate with each other, provides programmers with set of abstractions
Multiplexing
sharing resources by time or space
Multiprocessor Operating Systems
Multiple CPUs in one system
-Parallel computers
-multi-computers
-multiprocessors
Personal Computer Operating System
provide good support to one user
Embedded Operating Systems
A specialized OS that runs in various electronic devices
Very small, normally fits on a single chip
All software installed in ROM
Examples: GPS devices, ATMs, sensors, microwave ovens, etc.
Sensor-Node Operating Systems
-Networks of tiny computers
-Run on batteries - short lived
-Connect to base via radio transmission
Real-Time Operating Systems
requiring minimal user interaction, guaranteeing certain response times for particular computing tasks
Hard Real-time
task must be serviced by its deadline
Soft Real TIme
Missing a dealine is acceptable
Process
A program in execution
Address space
a memory location from 0 to some max, a set of addresses that a process can use to address memory
Process as container
reads and writes from to address space
Process Table
to keep track of all the processes, the scheduler maintains a block of information in main memory
Child Process
A process that was started by another process (parent process).
Pros of Address Space
-Multiple programs in memory at the same time
-Needs protection from other programs
Files
data stored in a container
Root Directory
the top of the file management structure
File Mounting
Allows user to specify path names to external storage medium
Special Files
makes i/o devices look like regular files so regular system calls can be used to read/write to them
Pipe
Pseudofile that connects two processes
process table
During multiplexing running process are suspended, it must be in the same state when restarted and must be saved
Child Process
a process created by another process
Address Space
multiple programs in memory at same time, done in hardware
virtual memory
Space on a hard disk or other storage device that simulates random access memory.
files
data stored in a container, grouped by directories, system calls exist to read and remove files
file mounting
allows user to specify path names to external storage medium
Metric Unit nano (n):
10^-9
Metric unit- Milli
10^-3
Metric Unit Micro
10^-6
Metric Unit Kilo
10^3
Metric Unit Mega
10^6
Metric Unit Giga
10^9
Metric Unit Tera
10^12
process creation 4 principal events
1. system initialization2. execution of a process creation system call by a running process3. a user request to create a new process4. initiation of a batch job
operating systems 2 main functions
providing abstractions to user programs and managing the computer's programs
system calls
is like making a special kind of procedure call, only system calls enter the kernel and procedure calls do not
Linux "ls" command
list files and directories
linux "cd" command
change directory
linux "cp file1 file2"
copy file1 and call it file2
linux "mv file1 file2" command
move or rename file1 to file2
linux "touch <name>" command
create an empty file
linux "rm file"
remove a file
linux "cat file"
display a file
linux "less file"
display a file a page at a time
linux "file <filename>"
find out what type of file it is = text, zip, jpg, etc.
linux "mkdir" command
make a directory
linux "rmdir" command
remove a directory
linux "sudo su-" command
switches over to the root account
linux "history" command
show all commands typed into terminal. saves up to 1000 commands in most linux versions
multiprogramming
CPU switches from process to process -> sequential processes; illusion of parallelism
running
using the CPU at that instant
ready
runnable; temporarily stopped to let another process run
blocked
unable to run until some external event happens