The course is an introduction to the principles, design, and implementation of modern operating systems. Topics: functions of an OS; processes, threads, and CPU scheduling; deadlock management; management of main and virtual memory; file system interface and implementation; management of peripheral devices and secondary memory; UNIX/Linux environment: interactive use of the shell; system call; system programming and inter-process communication; Kernel programming.
Theory
Required Textbook:
Sistemi Operativi. A.Silberschatz & P.B.Galvin & G.Gagne, 10ed., Addison-Wesley.
Reference Textbooks:
- Sistemi Operativi. P.Ancillotti & M. Boari & A. Ciampolini & G. Lipari, 2ed., McGraw-Hill.
- I Moderni Sistemi Operativi. A.S. Tanenbaum & H. Bos, 4ed., Pearson.
Laboratory exercise activities
Reference Textbooks:
- The Linux Command Line, W. Shotts.
- C didattica e programmazione, A. Kelley, I. Pohl, Pearson, 2nd Edition.
- Understanding the Linux kernel, D. Bovet, M. Cesati, O’Reilly.
- J. Erickson, L’arte dell’Hacking, vol 1, 2008.
Learning Objectives
At the end of the course, the student should have acquired knowledge of the principles underlying modern operating systems and skills to understand and critically analyze the issues related to their design and implementation. Furthermore, he will have a clear understanding of the importance of the operating system in a generic computing system and of its functions, and of the techniques and methodologies, both software and hardware, necessary to perform these functions.
In particular, the student should:
[Knowledge and understanding] know and understand: the internal structure of operating systems; the functionalities of the operating system components; the interactions of these components with user programs and with the underlying hardware; the problems inherent in the design and implementation of the various operating system components.
[Applying knowledge and understanding] be able to: use the acquired knowledge for solving exercises; use operating systems and the tools they provide consciously and effectively.
[Making judgments] know how to critically evaluate and compare alternative methods and techniques (e.g. different realizations of the same component).
[Communication skills] be able to present concepts related to operating systems in a clear and competent way.
Class lectures: 48 hours.
Laboratory exercise activities: 36 hours.
Further information
The course takes place at the Centro Didattico Morgagni (Viale Morgagni 40-44, Florence), according to the scheduled lesson timetable (see https://kairos.unifi.it/agendaweb/). Attendance to theory lessons and laboratory exercise activities is not mandatory but is strongly recommended. The course website is available on the University platform (https://e-l.unifi.it/). Student reception Prof. Pugliese: usually on Thursdays from 14.00 to 16.00, make an appointment by e-mail (rosario.pugliese@unifi.it).
Type of Assessment
The exam consists of two tests, one concerning the theory part and one concerning the laboratory exercise activity. The evaluation of each test is expressed with a mark out of thirty, with possible honors. A test is considered successfully passed if the grade assigned is at least 18. The two tests can be taken in any order, as long as they are both in the same academic year, under penalty of cancellation of the only test successfully passed. Provided that both tests are successfully passed, the final grade will be determined by the weighted average of the marks, assigning a weight of 2/3 to the vote of the theory part and 1/3 to the vote of the laboratory exercise activity.
Each educational objective is assessed in at least one of the two tests that make up the exam.
The theory test consists of a written exam that covers all the topics of the program carried out in class. The test includes both theory questions and exercises to be solved through the practical application of theory. The grade is determined by the sum of the scores achieved in the individual questions/exercises; these scores, in turn, are assigned based on the complexity of the questions/exercises and the accuracy of the answers provided. At the request of the teacher or the student, if the latter has achieved a score equal to or greater than 16 in the written test, it is also possible to take an oral test. In this case, the grade of the theory test is determined by the arithmetic average of the marks obtained in the written and oral tests. The oral test consists of questions that can cover all the topics of the program carried out in class and its mark is determined on the basis of the accuracy of the answers provided to the questions posed by the teacher.
The theory test aims to assess the student's knowledge and understanding of the topics covered during classroom lectures, his ability to critically and in-depth address these topics, and his skills in using the knowledge acquired for the resolution of exercises. The test also aims to evaluate the clarity of the exposition, the appropriate use of the specialized vocabulary, and the ability to relate alternative methods and techniques to each other critically.
The test relating to the laboratory exercise activity consists of i) developing a software project, with a short report, in groups of maximum 3 students, and ii) an oral test that includes the discussion of the project and the verification of knowledge of the topics covered in the laboratory module. The grade of the laboratory test is determined by the average of the scores obtained in the evaluation of the software project and in the oral exam. The project is evaluated according to the criteria: i) quality of the relationship; ii) quality of the code; iii) quality of the file structure and organization; iv) quality of the compilation process; v) correct functional behavior of the project. The verification of the topics covered in the course through an oral exam, once it is established that the project and the related discussion are sufficient, is based on two sets of questions (GROUP A, consisting of 20 questions, and GROUP B, consisting of 80 questions), which will be made available on the course website. In particular, as a necessary condition for passing the oral exam, gaps in the answer to the questions of GROUP A are not allowed. Answering only the questions of GROUP A allows to obtain a score for the part of the laboratory module not exceeding 20.
Course program
Theory:
Operating systems main objectives and tasks. Resource management. Interrupt. Operating system services. User interfaces. System calls and APIs. Concurrent model and processes. States diagram. Process scheduling. Process operations. Processes and threads. Multithreading models. CPU management. Scheduling criteria and algorithms. Deadlock: characterization and management methods. Main memory management. Logical and physical address spaces. Swapping. Contiguous memory allocation. Segmentation. Paging. Page replacement algorithms. Secondary memory management. The file system: interface and implementation. Directories and files. File access and allocation methods. Free space management. Management of an I/O device: polling, interrupt, DMA. Disk structure and management. Scheduling of disk requests. Laboratory exercise activities:
Shell commands in UNIX/Linux. The C programming language UNIX/Linux system calls. System programming and inter-process communication in UNIX/Linux. Basic concepts of system administration UNIX/Linux. Basics of kernel programming.