Introduction To OS by ANANDHAN.K
Introduction To OS by ANANDHAN.K
Unit-1
OPERATING SYSTEMS
OVERVIEW
The Modern Computer System
Program is in plugboard!!!
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
IBM 650
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Early Batch System (2)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Early Batch System (3)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Uniprogrammed Batch System
User
Program
Fence register
Operating
System/RM
time
I/O-bound job
CPU
time
I/O-2
CPU-2
I/O-1
CPU-1
OS
time
Doing I/O
Has CPU
Waiting for CPU or event (3 channels)
Processes
Figure 1-7.
(a) Before mounting, the files on drive 0 are not accessible.
(b) After mounting, they are part of the file hierarchy.
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
File Systems (3)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
System Calls (1)
Process Management
Figure 1-9. The MINIX system calls. sig is signal number, act and
oldact are procedures, how says what to do, old allows old
signal mask to be remembered.
System Calls (3)
File Management
Figure 1-9. The MINIX system calls. fd is a file descriptor; mode determines
access mode; nbytes is a byte count; buf holds status info.
System Calls (4)
Time Management
Figure 1-9. The MINIX system calls. tp and timep are pointers to
time variable; file is filename.
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
The fork Call in the Shell
Figure 1-12. The structure used to return information for the stat
and fstat system calls. In the actual code, symbolic names
are used for some of the types.
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
I/O Redirection
In the shell:
$ cat - < file.txt | grep foo | sort > silly.txt
cat with the '-' option reads from stdin, and by default it writes to
stdout. Both grep and sort read from stdin and write to stdout
(cin and cout in C++)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
System Calls for File Management (2)
NB: need two file descriptors – read (0) and write (1)
link(“/usr/jim/memo”,”/usr/ast/note”);
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
System Calls for Directory Management (2)
mount(“/dev/cdrom0”,”/mnt”,0);
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Layered Systems (1)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Layered Systems (2)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Virtual Machines
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Client-Server Model (1)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Client-Server Model (2)
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Client-Server Model (3)
wait
Server for
request
reply reply
reque
st
reque
st
wait
for
Client wait reply
time
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8
Summary
Tanenbaum & Woodhull, Operating Systems: Design and Implementation, (c) 2006 Prentice-Hall, Inc. All rights reserved. 0-13-142938-8