Week
Starting |
|
1/25 |
Introduction to the course
Start Chapter 1 - Chapter 1 Notes
Look at the Practice Exercises |
2/1 |
Chapter 1 & 2
Continue with Chapter 1
Look at some Questions
Chapter 2 Notes
Dowloand and instal Virtual Box and the VirtualBox Appliance OSC10e.ova. This will give us a linux machine to play with. For now and rest of the semester. This can be found at:
https://codex.cs.yale.edu/avi/os-book/OS10/index.html The books web site.
Look at Introduction to Linux Kernal Modules near end of Chapter 2
Parts I & II
- Look at the directory structure of included programs, go to chapter 2
- Compile simple.c
- Add it to the kernel modules running on the operating system
- Look to see that it ran
- Remove it from the set of modules running on the operating system
- Install an editor, I used JOE
- Modify it to print out the GOLDEN_RATIO_PRIME when it gets loaded
- Modify it to print the Greatest Common Factor of 3300 and 24 when it is removed from the set of kernel modules.
|
2/8 |
Chapter 2 & 3
Chapter 2 Notes
- Continue with in-class programming OS module examples
- Print out jiffies and Hz
- Print out jiffies
- Discuss some of the Practice Exercises in class
|
2/15 |
Chapter 3
Chapter 3 Notes
Do some fork() programming to see exactly what the OS is doing when it forks.
|
2/22 |
Review & Test
Review for Exam
Chapters 1 thru 3
|
3/1 |
Chapter 3 Coding
Try something different, lets work on problems 3.21 & 3.22 in class
- Starter File for 3.21 - Also refer to figure 3.9
- Starter Files for 3.22 - Figures 3.17 & 3.18
- man page for shm_open
- I know the book says so , but you don't need to fork() here, the idea is to practice interprocess communication.
|
3/8 |
Chapter 4
Chapter 4 Notes
Code for figure 4.9
- compile with gcc -pthread
- to run: ./a.out 5 should give you "sum = 15"
Zoom Recording of March 8th (working on chapter 3 stuff)
Zoom Recording of March 17th (Finish the pthread example & talk about Signals)
|
3/15 |
Chapter 5
Chapter 5 Notes
Solution to 4.22 for use in 5.39 -> compile with gcc -lpthread parallel.c -lm
|
3/22 |
Chapter 5 & Review
Finish Chapter 5
Review
- Chapter 4 Practice Exercises
- Chapter 4 Homework Exercises
- Chapter 5 Practice Exercises
- 3 requirements for critical-section problem
- pseudo code for a monitor -> 5.32
- busy-waiting
- tools for process synchronization - spinlock, semaphore, monitors, mutex locks, reader-writer, condition variables
- 5.21
- Read, really read the chapter while being able to Google.
|
3/29 |
Exam 2 & Chapter 6
Exam 2
Chapter 6 Notes |
4/5 |
Chapter 7
|
4/12 |
Chapter 8 & 9
Chapter 8 Notes
Chapter 9 Notes
|
4/19 |
Chapter 10
Chapter 10 Notes |
4/26 |
Chapter 11
Chapter 11 Notes
Review |
|
Final Exam is Wednesday May 4th at 12:30 - 2:30 pm |
Subject to change |
Assignments |
How to submit: |
To turn in the assignments, one option is to use FileZilla:
- Make sure portforwarding is turned on in your VirualBox
- Select Settings on the Virtual Box Manager window
- Select Network in the menu on the left
- Open the advanced drop down in the Adapter 1 tab on the right
- Click the Port Forwarding button
- It should have a rule for ssh
- Open up Filezlla
- Use:
- Host: sftp://127.0.0.1
- Username: osc
- Password: osc
- Port:2222
- Then connect
- Select the directorys you want to copy from and copy to.
- Drag and drop files over, or double click
- Put your .c file in the proper assignment folder in D2L
You could also use the command line in windows and use SFTP
- Open a CMD window
- run the sftp command: sftp -P 2222 osc@127.0.0.1
- enter password: osc
- drill over to the file you want to download
- run get, for example sftp>get simple.c
- this will put it in the directory you were sitting in when you started, probably your Users directory.

|
Due Date |
Description |
HW-1 Due 2/5 |
Chapter 1 - 1.12, 1.14, 1.16, 1.17, 1.19, 1.20, 1.24, 1.25 |
HW-2 Due 2/15 |
Chapter 2 - Finish the last part of Introduction to Linux Kernal Modules where you get the timer rate. (for extra credit must be done by Thursday)
IV. Assignment in the Programming Projects section at the end of Chapter 2.
From the book:
This assignment will involve designing two kernel modules:
1. Design a kernel module that creates a /proc file named /proc/jiffies that reports the current value of jiffies when the /proc/jiffies file is read, such as with the command
cat /proc/jiffies
Be sure to remove /proc/jiffies when the module is removed.
2. Design a kernel module that creates a proc file named /proc/seconds that reports the number of elapsed seconds since the kernel module was loaded. This will involve using the value of jiffies as well as the HZ rate. When a user enters the command
cat /proc/seconds
your kernel module will report the number of seconds that have elapsed since the kernel module was first loaded. Be sure to remove /proc/seconds when the module is removed. |
HW-3 Due 2/25 |
Chapter 3
Project 3 - Linux Kernel Module for Listing Tasks
This seems to be straight forward compared to the others and we discussed most of what you need already. |
HW-4 |
Chapters 4 & 5
Homework Quiz in D2L |
HW-5 |
Chapter 6, 7, 8
Homework Quiz in D2L |
HW-6 |
Chapter 9, 10, 11
Homework Quiz in D2L |
Bonus |
Programming Problem 11.27
Program it in C, C++, or JavaScript
If JavaScript you'll just send me the URL
If C or C++ I have a drop box for it.
|
|