Getting Started
Log onto a computer science server making sure to change the port number.
Follow these instructions to get your files ready to start lab.
- Use
wget
to download the file at http://cs.longwood.edu/courses/cmsc442/f18/files/lab3.tgz
- Uncompress the lab3.tgz file by using
tar -xvzf lab3.tgz
The Problem
We have been discussing scheduling. You are to simulate an OS scheduling processes. Your simulation must do the following things:
- Handle processes
- name -- name of the process for id
- start time -- when the process should start to be scheduled
- duration -- how long it needs to run
- wait time -- needed for statistics
- stop time -- needed for statistics
- Handle statistics
- makespan -- the time all processes are done
- average waiting time
- throughput -- number of processes completing per unit of time
- sum of completion times
- utilization -- percentage of time units with the processor being used
- Command line arguments
- filename or number of random generated processes
- number of processors to schedule
- algorithm to use
- File format
- Each line is a process
- Format: name startTime duration
- Algorithms
- First Come First Serve
- Round Robin
- HRRN
- Shortest Job Remaining
- Shortest Job First
Handin
When you are done you need to hand in your lab. The easiest way is to type make handin
.
If you have changed file names or directory names you will need to change to the
directory which contains the directory you wish to hand in. We will use
the handin cmsc442 assignment directory
command.
In this case you will type: handin cmsc442 lab3 lab3
You lab is due at 11:59pm Nov. 26th 2018.