kategori sistem operasi

Post on 18-Nov-2014

176 Views

Category:

Documents

3 Downloads

Preview:

Click to see full reader

TRANSCRIPT

eie282 os 1

EIE 282: Information Technology

Operating Systems

eie282 os 2

Lecture Outline

1. Basics of Operating Systems (OS).

2. OS Examples: Microsoft Windows, Unix, Linux.

3. OS for Process Management:

a) Multi-Tasking,

b) Multi-Processing.

4. OS for Memory Management:

a) Virtual memory management,

b) Virtual address management.

5. OS for Management of Networking & Device Drivers

6. OS for Security: internal and external.

eie282 os 3

Operating SystemAn operating system (OS) is a computer program that manages the

hardware and software resources of a computer

At the foundation of all system software, the OS performs these basic tasks:

prioritizing system requests

controlling and allocating memory, managing files

controlling input and output devices, providing a graphical user interface

for higher-level functions

facilitating networking

providing security

4

Operating System Categories

• Four categories:– Real-Time (RTOS)

• Real-time operating systems don’t require the intervention of any users at all.

– Single-User, Single-Task• Single-user, single-task operating systems are

proprietary systems developed specifically for the devices they manage.

– Single-User, Multitask– Multiuser

5

Real-Time Operating Systems

• Systems with a specific purpose and a certain result

• Uses include:– Industrial machines– Robotic equipment– Automobiles– Video game consoles– Home appliances

6

Single-User Operating Systems

Single-task systems• Perform one task at a time• PDAs:

– Pocket PC– Palm OS– Windows Mobile

• MS-DOS

Multitask systems• Perform simultaneous tasks• Windows• MAC OS• Linux

7

Multiuser Operating Systems

• Known as network operating systems• Allow access to the computer system by

more than one user• Manage user requests• Systems include:

– UNIX– Novell Netware– Windows Server 2003

eie282 os 8

Features of an OS

• Co-ordinates programs to work

with various devices and other

programs.

• Allocates resources to different

users.

• Provides user-interface.

• Organizes files on memory-disks.

• Provides security control.

eie282 os 9

• When the computer is first powered up, nothing is in the RAM.

• The CPU starts to read the BIOS-instructions stored in the ROM.

• The CPU then:

– Initializes all I/O devices: hard disk, video, mouse, keyboard, CD-ROM, etc

– Loads the bootstrap-loader of the operating system to RAM.

– Starts to execute the bootstrap-loader in RAM

• The bootstrap-loader further loads the other part of the operating system to the RAM

Starting the Computer: Loading the OS

10

Starting the Computer

The Boot Process

• Step 1: The basic input/output system (BIOS) is activated

• Step 2: A Power-on self-test (POST) checks attached hardware

• Step 3: The operating system loads into memory

• Step 4: Configuration and customization settings are checked

1

2

3

4

11

Desktop Operating Systems

• Operating system combined with the processor is known as a platform– Microsoft Windows / Intel– Apple Macintosh / Motorola

• Desktop operating systems include:– Microsoft Windows– MAC OS– UNIX– Linux

eie282 os 12

OS for Personal Computers

For IBM-PC compatible computers –

Microsoft Windows, Unix variants, and Linux variants

For Apple Macintosh computers –

Mac OS X (a Unix variant), Linux, BSD

eie282 os 13

Microsoft Windows OS The Microsoft Windows family of operating systems originated as a

graphical layer on top of the older MS-DOS environment for the IBM-PC.

In 2004, Windows held a near-monopoly of around 90% of the worldwide

desktop market share.

Windows is also used on low-end and mid-range servers, supporting

applications such as web-servers and database-servers

Recent Windows OS: Windows XP, Windows Vista (formerly Longhorn,

new functionalities, particularly in security, network administration, and digital

rights management. )

14

MAC OS• First operating system with point-and-click technology

(Graphical User Interface)• Excellent in:

– Graphics display– Processing capabilities– System reliability– Document recovery

• Fewer software applications

MAC OS X

15

UNIX

• Multiuser, multitask operating system

• Used primarily with mainframes

16

Linux

• Open-source operating system

• Based on UNIX

• Stable system

• Free

• May be downloaded through the Internet

17

What the Operating System Does

• Provides user interface

• Manages the CPU• Manages memory• Manages hardware• Coordinates

application software with the CPU

18

The User Interface

• Enables you to interact with the computer

• Types of interfaces:– Command-driven

interface (CLI: command line interface)

– Menu-driven interface

– Graphical user interface

Command-driven

Menu-driven

Graphical

• The OS arranges for the execution of all its activities in a systematic way.

• The OS assigns a slice of its time to each activity requiring the CPU’s attention. The OS then switches between processes thousands of times a second so it appears that everything is happening seamlessly.

19

Processor Management

20

Process 4th

Process 3rd

Process 2nd

Process 1st

Processor Management

• Controls the timing of events the processor works on– Interrupts: tell the OS it is in need of attention.– Interrupt handler: a special numerical code

that prioritizes the requests– Interrupt table: in RAM– Stack

REQUEST

Operating

System

21

Memory Management

• The operating system allocates space in RAM for instructions and data

RAM

Operating

System

22

Virtual Memory

• Instructions and data are stored on the hard drive when RAM is full– Swap file– Paging – Thrashing

Operating

System

FULL

eie282 os 23

Memory Management

Parkinson's Law: "Data expands to fill the space available for storage"

Memory Properties:

• has finite size and finite speed.

• is arranged hierarchically, from the fastest registers to the slowest disk storage.

Virtual Memory Management:

The OS’ memory manager coordinates the finite memories by tracking

o which memory is available,

o which memory is to be allocated or de-allocated to which process,

o how to swap between the main memory and the secondary memories.

Can greatly increase the amount of memory available for each process.

If the running processes require more RAM than available, there will be a speed-penalty in swapping RAM to disk-memory.

eie282 os 24

Memory Management

Virtual addresses management

• If multiple processes are simultaneously in the primary memory, they must be

prevented from interfering with each other's memory.

• This is achieved by having separate address-spaces.

• Each process sees the whole virtual address-space as uniquely assigned to it.

• The operating system maintains tables to match virtual addresses to physical

addresses. This process is called “paging”.

• The OS tracks all memory used by each process, so that when a process

terminates, that process’ memory will be made available to other processes.

eie282 os 25

Networking Most OS use the TCP/IP networking protocols.

A computer can appear on another computer’s network to share resources, such as files, printers, and scanners.

Device Drivers A computer & its OS do not know how to control every device.

A device driver is an interface software to allow specific OS or software applications to communicate transparently with specific hardware devices – to provide commands to the device,

to receive data from the device,

to translate these OS’ function-calls into device-specific function-calls.

provides the requisite interrupt-handling for any asynchronous time-dependent hardware interfacing needs.

is generally hardware-specific and OS-specific.

26

Hardware Management

• Device drivers:– Programs that enable the

operating system to communicate with peripheral devices

– Provided by the manufacturer of the device

• Plug and Play:– Hardware and software

standard– Facilitates the installation

of new hardware

27

Software Application Coordination

• Application programming interfaces (APIs):– Blocks of code contained in the operating

system– Coordinates the operating system with

software applications• Similar toolbars and menus

– Microsoft Direct X

28

File Management

• The operating system provides an organizational structure to the computer’s contents

• Hierarchical structure of directories:– Drives

• FoldersSubfolders

» Files

29

File path

• File path– Location of the file

C: Tech in Action\TIA Pics\\My Documents\ dotmatrix.gif

Drive Primary folder

Secondary folders

Filename

30

Working with Files

• File management actions:– Open– Copy– Move– Rename– Delete

• Recycle binSaving files

31

Utility Programs

• Small application programs that perform special functions:– Manage system resources– Create pleasant environment– Improve efficiency

eie282 os 32

Security 1. The OS provides access to a number of resources, directly or indirectly. E.g., files on a

local disk, privileged system calls, personal information about users, and the services offered by the programs running on the system.

2. The OS can distinguish between authorized requesters of these resources allowed access, from unauthorized (forbidden) requesters.

3. OS has requester identity, such as a user name.

Requesters may be divided into two categories:

1. Internal security: an already running program. Sometimes, a program (once it is running) has no limitations. More often, a program has an identity which it keeps and is used to check all of its requests for resources.

2. External security: a new request from outside the computer, e.g., a login at a connected console or some kind of network connection. To establish identity, there may be a process of authentication, e.g., username & password.

3. A high-security OS audits: tracking of requests for access to resources (such as, "who has been reading this file?").

eie282 os 33

Internal Security

protects the computer's resources from other programs concurrently running.

is especially relevant for multi-user systems, allowing each user to have

private files that other users cannot change or read.

is vital for auditing, as a program can potentially bypass the operating system.

For a less-privileged program:

Less-privileged programs are disallowed from certain hardware

instructions, they have to ask a privileged program (e.g., the OS) to do so.

The operating system can thus check the less-privileged program's

identity. The OS may then allow or refuse the request.

eie282 os 34

External Security

An OS offers various services to (i.e., hosts) other computers on a network, e.g.,

file sharing, print services, email, web sites, and file transfer protocols.

At the front line of the external security are hardware devices known as firewalls.

In OS, a software firewall is configured to allow or deny traffic to a service

running on top of the operating system.

Thus, while running insecure service (e.g., Telnet or FTP) , another service would

not be threatened by a security breach because the firewall would deny all

attempts from telnet or FTP to connect to the other service.

eie282 os 35

Lecture Summary

1. Basics of Operating Systems (OS).

2. OS Examples: Microsoft Windows, Unix, Linux.

3. OS for Process Management:

a) Multi-Tasking,

b) Multi-Processing.

4. OS for Memory Management:

a) Virtual memory management,

b) Virtual address management.

5. OS for Management of Networking & Device Drivers

6. OS for Security: internal and external.

eie282 os 36

top related