Sei sulla pagina 1di 4

Agenda Schedule

•Last time (This morning) Sun Tues Thurs Fri


 I/O
systems + Mass storage structure File systems Mass storage
PA#5 due protection,
 PA#4 back PA#6 out 7 protection, security 9 security 10
•This time (Thurs night / Friday afternoon) No class – marty No class – marty
PA#6 due
at conference at conference
 Mass storage structure 16 (noon)
14
 Security introduction No class – No class –
•Next time (Tuesday Nov 28) Thanksgiving 21 Thanksgiving 23
protection, security protection,security
 Moresecurity/protection PA#7 out
28 30
 PA#7 out (look for it early)
Wrap-up
•Remember, no class next week PA#7 due 5
•Remember, PA#6 due NEXT Friday at noon! DO it soon!!! Final exam
0900-noon 14

CS414: Operating Systems CS414: Operating Systems

Before we start: PA#6 (Main) Optimizing Disk Accesses


•Datafile replaced today at noon or so! •In timesharing systems, disk driver may have many
different requests pending
•Approach: minimize disk seek time
•Some strategies are implemented in the disk driver, while
others are implemented directly in the disk controller
•We'll look at
 FCFS, SSTF, SCAN, C-SCAN, LOOK, and C-LOOK
•Example: range of request: 0-199; Head pointer currently
at 53
 The request sequence: 98, 183, 37, 122, 14, 124, 65, 67

CS414: Operating Systems CS414: Operating Systems

Disk Scheduling: FCFS Disk Scheduling: SSTF

•Potential problem with SSTF?

CS414: Operating Systems CS414: Operating Systems

1
Disk Scheduling: SCAN
(Elevator Algorithm)
Disk Scheduling: C-SCAN

CS414: Operating Systems CS414: Operating Systems

Disk Scheduling: LOOK Disk Scheduling: C-LOOK

CS414: Operating Systems CS414: Operating Systems

Selecting a Disk-Scheduling Algorithm DEMO


• SSTF is common and has a natural appeal •http://www.sysinternals.com/utilities/diskmon.html
• SCAN and C-SCAN
 perform better for systems that place a heavy load on the disk.
• Performance depends on the number and types of
requests.
• Requests for disk service can be influenced by the file-
allocation method.
• Either SSTF or LOOK is a reasonable choice for the
default algorithm.

CS414: Operating Systems CS414: Operating Systems

2
RAID RAID (cont.)
• Level 0 (“striping”)
 Good: large requests
 Bad: small requests; MTTF (no redundancy)
• Level 1 (“mirroring”)
 Good: fault tolerance
 Bad: Double the cost of storage
• Level 2
 Bad: must be rotationally synchronized; hamming code
• Level 3
 Good: fastest for large-file transfer
 Bad: what happens if parity disk fails?
• Level 4
• Level 5
 Good: Higher I/O rate for writing data; no dedicated parity disk
 Bad: Not as fast as RAID 3

• Most popular are 0,1,3,5

CS414: Operating Systems CS414: Operating Systems

Disk Management Swap-Space Management


• Low-level formatting, or physical formatting — Dividing a • Swap-space — Virtual memory uses disk space as an
disk into sectors that the disk controller can read and extension of main memory.
write. • Swap-space can be carved out of the normal file
• To use a disk to hold files, the operating system still system,or, more commonly, it can be in a separate disk
needs to record its own data structures on the disk. partition.
 Partition the disk into one or more groups of cylinders. • Swap-space management
 Logical formatting or “making a file system”.  4.3BSD allocates swap space when process starts; holds text
• Boot block initializes system. segment (the program) and data segment.
 The bootstrap is stored in ROM.  Kernel uses swap maps to track swap-space use.

 Bootstrap loader program.  Solaris 2 allocates swap space only when a page is forced out of
physical memory, not when the virtual memory page is first
• Methods such as sector sparing used to handle bad created.
blocks.

CS414: Operating Systems CS414: Operating Systems

Power Management Power Consumption in Laptops


•ENIAC
 18000 vacuum tubes; 140,000 watts
•Typical desktop PC
 200 watt power supply (loses 15% to heat)
 100 million PCs  20,000 Megawatts (= 20 nuclear power plants)
•Two general approaches for reducing power consumption
 OS turns off components not in use
 App program uses less energy (at degraded user experience)M

CS414: Operating Systems CS414: Operating Systems

3
Reducing Power Consumption Crypto 101: Basic terminology
•Display • Authentication: Assurance of identity of person or
 Dimming originator of data
•Hard Disk  Password, biometrics, challenge/response (e.g., certificates)
 Spinning down/up • Authorization: Rights to perform some action
 Increase disk cache in RAM?
• Integrity: Maintaining data consistency
 Have OS inform app (e.g., auto-save in emacs?)
 Checksums, MD5 (hash)
•CPU
 Voltage/frequency scaling • Confidentiality: Protection from disclosure to
 Intel “SpeedStep”: 750MHz  600MHz; 1.6V  1.35V (related: unauthorized persons
“Quickstart”)  Encryption: cleartext  ciphertext, ciphertext  cleartext
•Memory • Non-repudiation: Originator of communications can't
 Turn off cache (lines)?; writing main memory to disk? deny it later
•Wireless • Availability: Resources available for authorized parties

CS414: Operating Systems CS414: Operating Systems

More definitions
• Threat: external to entity under
consideration/protection
• Vulnerability: internal to entity under
consideration/protection

• Example: sender S wants to send a message to


receiver R; what can an “man-in-the-middle” do?
1. Capture message and keep it
2. Capture message, read it, and relay it on
3. Capture message, modify it and send it on
4. Capture message, keep it, send it on, and then send it on again
(replay) – e.g., financial transaction
Note: These are threats – whether or not the original message is
vulnerable to these threats is orthogonal!

CS414: Operating Systems

Potrebbero piacerti anche