• No results found

lecture 5 chapter 1

N/A
N/A
Protected

Academic year: 2020

Share "lecture 5 chapter 1"

Copied!
22
0
0

Loading.... (view fulltext now)

Full text

(1)

Lecture 5

(2)

Computer System & Operating System

Overview

(3)

1. Introduction to Operating Systems

2. Functions Performed by an OS

3. Types of OS

Mainframe OS

Server OS

Multiprocessor OS

PC OS

Real Time OS

Embedded OS

Networking OS

4. Batch Processing System

5. Multiprogramming

Operating System Concepts

(4)

7. Spooling

8. Instruction-Fetch-Execute Cycle

9. Structure of Disk Drive

10. Busses

11. Processes

12. Deadlocks

13. Memory Management

14. I/O

15. Files

(5)

Memory Management

Characteristics of Main Memory

1. It is a temporary storage device used to hold data temporary.

2. Main memory holds the programs and instructions which are

currently being executed by the CPU.

3. It is the fast access storage device.

4. It is read and write memory.

5. It is a volatile memory.

(6)

1. In a simple OS, only one program at a time is in the

memory. To run a second program, the first one has to be

removed and the second program placed in the memory.

2. Sophisticated OS allow multiple programs to be in the main

memory at the same time.

3. To keep them interfering with one another, some kind of

protection mechanism is needed.

4. Important memory related issue is managing the address

space of the processes.

(7)

OS managed the

address space

(contains data, registers

including program counter, stack pointer and all other

info. need to run the program) of the process.

Maximum amount of address space a process has is less

than the main memory, a process can fill up its address

space and there will be enough room in main memory to

hold it all.

(8)

What if a process has more address space

than the computer has main memory and the

process wants to use it all?

(9)

Technique called virtual memory exists, in which the

OS keeps part of the address space in the memory

and part on the disk and shuttles pieces back and

forth between them as needed.

(10)

Operating System Concepts-I/O

1. Operating system has I/O system for managing its I/

O devices.

2. Some of I/O software are device independent, i.e.

applies to many I/O devices equally well.

3. Device drivers are specific to particular I/O devices.

(11)

Operating System Concepts-Files

Directory way of grouping

files.

Example, file system for a

university department

What will be the path of file

CS101?

(12)

Operating System Concepts-Mounting File System

UNIX file system

– Allow to attach file system on a floppy disk to be attached to

the main tree (mounting) on the hard disk.

Before mounting

– files on floppy are inaccessible. The root file system is on the

hard disk and a second file system on the floppy disk.

After mounting floppy on b

– files on floppy are part of file hierarchy

(13)

Communication between processes in UNIX

A pipe, a sort of pseudo file that can be used to connect

two processes.

(14)

Operating System Concepts-System Call

1. System calls provide an interface between the process

and the operating system.

2. System calls allow user-level processes to request some

services from the operating system which process itself

is not allowed to do.

(15)

Examples

(16)

1. mkdir and rmdir

are used to create and remove

empty directories.

2. Link system call

is used to allow the same file to

appear under two or more names in different

directories.

(17)

System calls for Directory management

Link(“/usr/jim/memo”, “usr/ast/note”);

Fig.a

Two directories before linking

/usr/jim/memo

to ast's directory

Fig.b

The same directories after linking

Note: Every file in UNIX has

a unique number called

i-number which identifies the

file

(18)

The principle metric prefixes

(19)

TOPICS COVERED

Introduction (Page 1, 2 &3)

1.1 What is an operating system?

1.1.1 The operating system is an extended machine 1.1.2 The operating system as a Resource Manager 1.2 History of Operating system

1.2.1 The first generation (1945-55) vacuum tubes and plugboards 1.2.2 The second generation (1955-65) transistors and batch system 1.2.3 The third generation (1965-1980) IC’s and multiprogramming 1.2.4 The forth generation (1980-Present) personal computers 1.3 The operating system zoo

1.3.1 Mainframe operating system

1.3.2 Networking/Server operating system

1.3.3 Distributed/Multiprocessor operating system

(20)

1.4 Computer hardware review

1.4.1

Processors

1.4.2

Memory

1.4.4

Buses

1.5 Operating system concepts

1.5.1

Processes

1.5.2

Deadlocks

1.5.3

Memory management

1.5.4

I/O management

1.5.5

Files

1.6 System calls (page 44 - 48)

1.6.3

System calls for directory management

(21)

QUIZ-1

(22)

End of Chapter 1

References

Related documents

In our opinion, the consolidated financial statements and the Parent Company financial state- ments give a true and fair view of the Carlsberg Group’s and the Parent Company’s

Through the recursive analysis of the interviews and with the support of several functions of Nvivo 11 software (i.e. matrix coding, relational nodes and sets), the most

The self- assessments of people based on such factors as their ability and ability to create their own businesses, entrepreneurial intentions, fear of failure

One option for attracting additional capital to the renewable energy sector that Congress may consider is allowing renewable energy activities access to the master limited

stack code stack code stack code address space 1 shared memory stack code stack code CPU stack code address space n shared memory … process 1 process n 419 Oper at ing Syst ems ©

Study, medita- tion, work,

I Demand-paging : delay the allocation of a memory page and its mapping to the process’s virtual address space until the process accesses an address in the range associated with

◮ detaches the shared memory segment located at the address specified by shmaddr from the address space of the calling process.... The system