Operating Systems Flashcards
Operating system
Core software that controls how the computer operates
Purpose of Operating System
- Control the hardware of the computer system. e.g. hard drive
- Manage software, in terms of loading (and unloading) into main memory.
- Provide security, such as user name and password control.
- Provide an user interface
Parts of an Operating System
The KERNEL
The DEVICE DRIVERS
The USER INTERFACE
The SYSTEM UTILITIES
The Kernel
- Loading / Unloading applications from memory
- Memory management
- File management
- Data security
Device drivers
Enables the operating system to control and communicate with the device.
User Interface
Allows a person to interact with the computer.
System Utilities
All the basic facilities that run in the background without user interaction
- File management services
- Anti-virus utility
- File compression utiity
Reason for memory management
Every computer has a limited amount of memory. Memory is a limited resource so it has to be managed.Task of memory manager.
Segmentation
- Memory is split up into segments
- Segments can vary in size
- Uses logical divisons
Paging
- Memory is split into equal size pages
- Pages are swapped between main and virtual memory
- Uses physical divisions
Disk thrashing.
As more pages are swapped, eventually more time is spent swapping pages than on processing the data. This is called disk thrashing.
Memory leaks
A well-written program will flush its data away once it no longer needs it and declares memory as free.
A badly-written program will not flush its data properly. The memory remains unavailable, locked up.
Scheduling
Task of allocating CPU processor time amongst all running programs.
Purpose of scheduling
- Processes as many tasks as possible in a given time
- Makes maximum use of CPU time
- It will try to minimise the delay between when the user requests something to be done and when that task is completed.
- Makes maximum use of resources
- Ensure that no task is left uncompleted for too long
Round Robin
- Eeach process is give time slice
- If completed next process is loaded
- If not repeats until is completed
First come first served
- Process in the order they enter the queue
Shortest job first
- The queue is ordered by the amount of processor time needed
- Shortes Jobs are completed first
Shortest Time Remaining
- The queue is based on the timeleft to completion
- Jobs with the least time needed are completed first