CS 570: Advanced Operating Systems Instructor’s Name: Umar Saif Year: 2010-11 Office No. & Email: 421, [email protected] Quarter: Fall Office Hours: TR 2-3 PM Category: MS TA for the Course: TBA Course Code (Units) CS 570: Advanced Operating Systems (3 Units) Course Description This course is a graduate level course on operating systems. The goal of the course is to enable students to understand the concepts and architectural principles of operating systems, as well as to appreciate the tradeoffs of different design choices in real-world, complex systems. Unlike traditional operating systems courses that follow a textbook approach to teach individual concepts in isolation, this course will aim to convey the bigger picture of engineering an operating system and will draw from a wealth of state-of-the-art research material on OS design. Concepts like concurrency, naming, communication, synchronization, memory management, faulttolerance, authentication and I/O will be taught with reference to complexity, reliability, availability, performance and security concerns in engineering operating systems. Core/Elective Core for Computer Science Majors and Elective for Computer Engineering Majors Pre-requisites Data Structures, Working knowledge of the Java Programming Language Goals • • • • TextBooks, Course Materials, aetc. Gain a basic understanding of operating systems concepts See the bigger picture of engineering issues in operating system design and implementation View system engineering as a set of design tradeoffs rather than theories cast in stone Design a simple “realistic” operating system Textbook:  Abraham Silberschatz, Greg Gagne, and Peter Galvin. Operating System Concepts, Seventh Edition. John Wiley and Sons, 2005. ISBN 0-471-69466-5.  Principles of Computer System Design, MIT 6.033 Class Notes, Draft Release 3 by Jerome H. Saltzer and M. Frans Kaashoek, Department of EECS, MIT  Selected Research Papers CS 570: Advanced Operating Systems Year: 2010-11 Quarter: Fall Lectures, Tutorials & Attendance Policy Grading Additional Details Assignments There will be 26 lecture sessions. Tutorials will be arranged if and when needed. There are no points for attendance, though 5% grade is reserved for class participation. NACHOS Operating system will be used to used for lab assignments, in which students will build a working operating system as part of 4 main assignments. 25% 15% 25% 35% Assignments and labs Quizzes Midterm Exam Final Exam (Comprehensive) The course website will be the primary source for announcements and reading materials including lecture slides, handouts, and web links. http://suraj.lums.edu.pk/~cs570f09 * Phase #1: Threads Week 4-5 * Phase #2: Multiprogramming Week 6-7 * Phase #3: Virtual Memory Week 8-9 * Phase #4: Networks and Distributed Systems Week 10-12 Lecture Schedule CS 570: Advanced Operating Systems Year: 2010-11 Quarter: Fall Lecture 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 Topics Introduction, processes, multiprogramming. EIT, scheduler, CPU scheduling system model, CPU scheduling, goals. CPU scheduling, metrics, constraints, open vs. closed systems, user characteristics, job characteristics, FIFO, round robin, little's formula, CPU Scheduling: SJF, SPT, SRPT, FB, MLFB, Exponential queue, CPU scheduling: fair share scheduler, countermeasures. Discrete event simulation. Cooperating processes, atomic operations, critical sections, too much milk problem. Synchronization with semaphores. Synchronization: producers and consumers, readers and writers, dining philosophers. Threads. Synchronization with Condition Variables. Unix implementation. Monitors. Semaphore implementation, disabling interrupts. Deadlock, deadlock prevention. deadlock avoidance, banker's algorithm, recovery, rollback. Unix file locking. Linkers and loaders. Dynamic storage allocation: stacks, heaps, fragmention, (external/internal)first fit, best fit, next fit, bit map, reference counts, garbage collection, buddy system. Memory management ‐ flat memory, relocation (static, dynamic), base and bounds, swapping. Multiple variable length segments, address translation, processes vs. threads, managing segments, paging (intro) Paging: translation, PTBR, pros/cons, page tables, page table implementation, wired down pages, paging and segmentation combined, sharing, paging vs. segmentation. Paging: copy on write, address space communication, I/O in paging system, sharing, 370 implementation, VAX implementation, TLB, principle of locality, translator. Demand paging, principle of locality, page faults. paging fetch algorithms, page replacement algorithms (RAND, FIFO, LRU, MIN/OPT), real vs. virtual time. Evaluation of paging algorithms, stack algorithms. implementing LRU, clock algorithm, local vs. global replacement. Thrashing, working sets. page fault frequency, page size, I/O and paging, trace driven simulation, modify‐ ing code to minimize paging, algorithm comparison. I/O device characteristics and device management. I/O device characteristics and device management. File and I/O systems ‐ disk management, file alloca‐ tion, contiguous 19 20 21 22 23 24 25 26 27 allocation, linked files, multilevel indexed file, simple indexed file, dynamic optimized allocation (Demos), free block list. I/O optimization: block size, disk arm sked (fcfs, sstf, scan, cscan), rotational scheduling, skip sector allocation, track offset for head switching, file placement, disk caching, prefetching, data replication, ALIS, RAID. File descriptor, tree structured directories, links, symbolic links, root, tree structured directories, working directory, operations on files, file backup and recovery. Networks and communications protocols, examples, hardware, topologies, performance parameters, protocols, ISO, wide area nets, broadcast nets, ethernet. Networks: ring networks, circuit switching, packet switching, names vs. routes, communication problems, datagrams, TCP/IP, NFS. Protection and security: problems, levels of info protection, design principles, authentication, authorization determination, access lists, capabilities, Multics protection, access enforcement, common problems. Protection: examples of penetration, countermeasures, inference controls, confinement problem, viruses. Encryption: substitution, transposition, codes, cryptanalysis, key distribution, DES, public key encryption, safe mail, digital signatures, Clipper Chip. Virtual Machines, VMM, emulators, implementation, memory mapping, I/O, VM performance. Real Time Systems ‐ deadlines. Performance evaluation: measurement, hardware monitoring, software monitoring, multics, GTF, workload characterization, analytic modeling, queueing networks,simulation, back‐of‐the‐envelope calculations. Hints for OS designers. Current research in Operating Systems.