CS 170 Operating Systems Fall 2015 4 units

  • Slides: 16
Download presentation
CS 170: Operating Systems Fall 2015, 4 units http: //www. cs. ucsb. edu/~cs 170

CS 170: Operating Systems Fall 2015, 4 units http: //www. cs. ucsb. edu/~cs 170

Course Information n n Instructor: Tao Yang n www. cs. ucsb. edu/~tyang n Office

Course Information n n Instructor: Tao Yang n www. cs. ucsb. edu/~tyang n Office hours: TR 1: 45 -2: 45 (or stop by). TA: Daniel Kudrow (dkudrow@cs), Varun Kulkarni Somashekhar (varun@umail). Grading: Roman Kazarin (rkazarin@umail) Text Book: n n Operating Systems: Principles and Practice (Second Edition). by Thomas Anderson and Michael Dahlin. Recursive Books Ltd. 2014 Recommended: Operating System Concepts Essential. Or Operating System Concepts by the same authors 10/3/2020 2

OS Market Shares on All Devices Worldwide Device Shipments by Operating System Year Android

OS Market Shares on All Devices Worldwide Device Shipments by Operating System Year Android i. OS/OS X Windows Others 2014 48. 61% 11. 04% 14. 0% 26. 34% 2013 38. 51% 10. 12% 13. 98% 37. 41% 2012 22. 8% 9. 6% 15. 62% 51. 98% http: //en. wikipedia. org/wiki/Usage_share_of_o perating_systems

OS Market Shares on Desktops and Servers Desktops Windows 7 Windows XP Windows 8.

OS Market Shares on Desktops and Servers Desktops Windows 7 Windows XP Windows 8. 1 Windows 8 Mac OS X 10. 10 Windows Vista Mac OS X (other) Mac OS X 10. 9 Linux Windows 55. 99% 19. 15% 10. 49% Web server OS Market shares. 3. 55% Unixbased 64. 2% 67. 8% 3. 55% Windows 35. 9% 32. 2% 2. 11% Feb 2011 March 2015 1. 7% 1. 65% 1. 53% W 3 Techs. com http: //en. wikipedia. org/wiki/Usage_share_of_operating_systems

OS History: How Linux, Andriod, i. OS, and Windows are related?

OS History: How Linux, Andriod, i. OS, and Windows are related?

OS History: How Linux, Andriod, i. OS, and Windows are related? n n n

OS History: How Linux, Andriod, i. OS, and Windows are related? n n n Because of the cost of developing an OS from scratch, most modern OSes have a long lineage: Multics AT&T Unix BSD Unix Ultrix, Sun. OS, Net. BSD, … Mach (micro-kernel) + BSD Next. Step XNU Apple OSX, iphone i. OS Linux Android OS CP/M QDOS MS-DOS Windows 3. 1 NT 95 98 2000 XP Vista 7 8 phone … Linux Red. Hat, Ubuntu, Fedora, Debian, Suse, … J. Kubiatowicz CS 162 UCB

Course Info n n Design and implementation of operating systems. Class projects n Linux/Unix

Course Info n n Design and implementation of operating systems. Class projects n Linux/Unix system calls on process and Pthreads n Extend an operating system on a virtual machine. n Focus: process/thread management, code loading/execution, multiprogramming, virtual memory, and file systems/disk storage. Need to have a CSIL account Prerequisite: n n Algorithms/data structure, computer architectures C/C++ programming. Experience with Linux. 10/3/2020 7

Why this course? n Myself n n CS faculty since 1993. Ask Jeeves/Ask. com.

Why this course? n Myself n n CS faculty since 1993. Ask Jeeves/Ask. com. Research in parallel distributed systems and information retrieval. Built large-scale web search at Ask. com Why do I teach this course? n n Exciting System/OS experience is critical for many applications Share my academic/industry experience Help everybody to learn 10/3/2020 8

What will you learn? n n Operating system concepts How to program an operating

What will you learn? n n Operating system concepts How to program an operating system n n n Program execution & multiprogramming Process/thread management Memory management File system implementation (disk). Impact on your job or advanced studies n n Interpret performance behavior and optimize software that uses CPU/memory/disk Adapt technology evolution: n New OS, new devices/platform 10/3/2020 9

Internet Services: An OS Perspective DNS Servers DNS request Datacenter Reply page Load balancer

Internet Services: An OS Perspective DNS Servers DNS request Datacenter Reply page Load balancer Service engine Data store Ad Server n Complex interaction of multiple components in multiple administrative domains n Systems, services, protocols, …

Challenges/OS Issues in Internet Systems n n n Data intensive n Hundreds of terabytes/petabytes

Challenges/OS Issues in Internet Systems n n n Data intensive n Hundreds of terabytes/petabytes of data partitioned and replicated in many machines. n Management of memory, disk storage, CPU High performance and availability n Response time < 1 sec. n High throughput (thousands of requests per second) n Fault tolerant Infrastructure Cost: n Huge computer clusters/data center+networking expense. n OS resource/efficiency optimization. 10/3/2020 11

Topics/Schedule n n Weeks 1 and 2 lectures: n Introduction to OS and Process/Thread

Topics/Schedule n n Weeks 1 and 2 lectures: n Introduction to OS and Process/Thread Management. Nachos/Pthreads Action: n Join Piazza class discussion group (linked from ~cs 170 homepage) n Review Project 0 and form a 2 -3 person group n ~250 lines of C code n Due on April 10 10/3/2020 12

Projects Project 0: Shell Linux processes & system calls Project 1: Pthread Synchronization. Nachos

Projects Project 0: Shell Linux processes & system calls Project 1: Pthread Synchronization. Nachos Threads Project 2: Nachos Processes& System Calls Project 3 A: Nachos virtual memory 10/3/2020 Nachos 9 K lines Optional Project 3 B: Nachos file systems 13

Rest of fall quarter n Process/thread management and synchronization. System calls. n n Address

Rest of fall quarter n Process/thread management and synchronization. System calls. n n Address translation and memory management. n n Project 2 (Read 2 K lines. Write ~500 lines) Virtual memory and file system implementation n n Project 1 (Read 1 K lines. Write ~300 lines) Project 3 A and 3 B (Read 2 K lines. Write ~500 lines)) Process Scheduling. Deadlock. 10/3/2020 14

Discussion Sections n n n n Apr 6: Review Linux system calls. Project 0

Discussion Sections n n n n Apr 6: Review Linux system calls. Project 0 sample code/Makefile n April 10 (Proj 0 deadline) Apr 13: Review Pthreads and synchronization. Project 1 sample code. Apr 20 Project 1. MIPS Assembly. n April 23 (Proj 1 deadline) Apr 27: Project 2. n May 6 (Proj 2 deadline). May 4. Exercise review for Exam 1 n May 7 or 12 (Exam 1) May 11: Project 3 A. Memory management May 18: Project 3 B. File systems. n May 20 (Proj 3 A). June 1 (Proj 3 B). June 1. Exercise review for final exam 15

170 Class Workload: Heavy n Projects (45%) n 4 projects with extensive C++/C programming

170 Class Workload: Heavy n Projects (45%) n 4 projects with extensive C++/C programming n n 2 -3 persons/group. Exam 1+Exam 2 (45%). n n Project 3 B is optional, and will improve your exam 1 score. You can boost Exam 1 with Project 3 B or with Exam 2 Exercises and participation (10%) Not curved (tentatively): n n n A level [90 -100] A (>92. 5%) B level [80 -89. 9] B (>82. 5%) B+(>87) C level [70 -79. 9] C(>72. 5%) C+(>77) 16