Lecture 14

advertisement
CGS 3763 Operating Systems Concepts
Spring 2013
Dan C. Marinescu
Office: HEC 304
Office hours: M-Wd 11:30 - 12:30 AM
Lecture 14 – Friday, February 8, 2013

Last time:


Today:






Networking concepts
Solutions to HW1
Student questions for week 4
More network concepts
Client-server systems
Remote procedure call
Next time

Shared memory systems
 Pipes

Reading assignments

Chapters 3 and 4 of the textbook
 Chapters 3 and 4 textbook slides
Lecture 13
2
Solutions to HW1







1.2 What are the main differences between an OS for a
mainframe and one for a PC?
Mainframe: a. more sophisticated resource management
policies; b. additional functionality, e.g., it has to support
accounting; c. enhanced security.
1.3 What are the four steps involved in the execution of
an instruction on a stored-program computer?
Instruction fetch from the address pointed at by the PC
(Program Counter) into the IR (Instruction Register).
Instruction decode.
Instruction execution.
Write back the results
Lecture 13
3
Solutions to HW1
3 Several users share a system in multiprogramming
and time-sharing environments and this can result in
security problems: (a) List two such problems; (b) Can
we ensure the same level of security in a time-shared
system as in a dedicated machine. Explain your answer.
a. Security and privacy; unpredictable execution time.
b. Probably not, since any protection scheme devised
by humans can inevitably be broken by a human, and the
more complex the scheme, the more difficult it is to feel
confident of its correct implementation.

Lecture 13
4
Solutions to HW1

1.14 What resources must be managed carefully in the following
settings: (a) Mainframe of minicomputer systems; (b) Workstations
connected to servers; (c) Handheld computers.
 Mainframes: memory, CPU, primary and secondary storage, network.

Workstations: memory,CPU, network
 Handheld computers: power consumption, memory resources, display,
RF (Radio Frequency) subsystem for wireless communication.

1.15 Under what circumstances would a user be better off using a
time-sharing system rather than a PC or a single-user system?

(a) When the amount of computing resources (CPU cycles, primary and
secondary storage) is considerable.
 (b) When the problems requires a collaborative effort of several users.
Lecture 13
5
HW1 solutions

1.21 How are network computers different from traditional PCs?
Describe some usage scenarios in which it is advantageous to use
network computers.

A network computer has limited resources and relies on systems
accessible via the Internet for data storage and for computing; its price
is low. The OS of a network computer supports a small number of
functions. Chromebook is an example of a network computer see
 http://www.google.com/intl/en/chrome/devices/#foreveryone-promosamsung


Typical usage scenario: Web access, Email access.
Lecture 13
6
Student questions

Jan 30th Wednesday:






More on the fork() or exec() commands.
Better explanation of pipelining and what it is.
Where does the PCB come into play?
Explain further the concept of an interrupt. What is an interrupt vector?
What determines which process has more priority over another
process?
What is the purpose of the program counter? Why do we need to know
this?
Lecture 13
7
Student questions

Feb 1st Friday:






What is the main difference between independent and cooperating
within a system?
RISC/CISC Architecture: what exactly are these two architectures?
What is an example of CISC machine and where are they used? What
is the advantage or disadvantage of these versus the standard RISC?
Further explain branch execution.
Explain in greater detail of a process creation and what it is used for?
What is a Producer-Consumer Problem? What is a flag/condition code,
where does it come in place?
What are the major differences between layered and modular systems?
Lecture 13
8
Peer-to-peer communication
Host
Host
Application Layer
(Message)
Application Layer
(Message )
Network
Transport Layer
(Segment)
Network Layer
(Packet)
Data Link Layer
(Frame)
Physical
Layer
Transport Layer
(Segment)
Router
Router
Network Layer
Network Layer
Network Layer
(Packet)
Data Link
Layer
Data Link
Layer
Data Link Layer
(Frame)
Physical
Layer
Physical
Layer
Physical
Layer
Streams of bits encoded as electrical, optical, or electromagnetic signals
Lecture 13
9
Local and wide area networks
Wide Area Network
Router
Router
Network Layer
Network Layer
Data Link
Layer
Physical
Layer
Data Link
Layer
Physical
Layer
Host
Host
Application
Layer
Application
Layer
Transport
Layer
Transport
Layer
Network
Layer
Local Area Network
Bridge
Data Link
Layer
Hub
Physical
Layer
Physical
Layer
Data Link
Layer
Physical
Physical
Layer
Layer
Local Area Network
Bridge
Data Link
Layer
Physical
Layer
Lecture 13
Network
Layer
Hub
Data Link
Layer
Physical
Layer
Physical
Layer
10
Encapsulation/ de-capsulation
Application
Header
Transport
Header
Network
Header
Message
Segment
Packet
Data Link
Header
Frame
Encapsulation at the sender
Data Link
Header
Frame
Network
Header
Packet
Transport
Header
Segment
Application
Header
Message
Decapsulation at the receiver
Lecture 13
11
IPV4 and IPv6 datagrams
0
16
8
version
hlen
ToS
flags
fragment identifier
time to live
31
packet length (bytes)
upper layer prot
12-bit fragment offset
header checksum
32-bit source IP address
32-bit destination IP address
options (if any)
0
version
Payload
16
8
31
flow label
priority
payload length (bytes)
next header
hop limit
128-bit source IP address
128-bit destination IP address
Payload
Lecture 13
12
Multiplexing, de-multiplexing
P1
P2
P3
P1
P4
P2
P3
P4
Sending side
Receiving side
Lecture 13
13
Download