EECE-4029 Operating Systems Fall 2016
Linux OS

processes, mutex, semaphores, memory management, producer-consumer, files, deadlock, more..

Install Linux

    You can run linux from a USB stick on any computer and any problems you run into will not affect your computer's native OS; or, you can install linux on an old, disused computer; or you can repartition an existing Windows computer and install linux there.
Installation Options:
You can download and burn a live iso image of the operating system on a DVD or USB drive, boot the disk or USB drive, and install; or you can perform a network install; or you can download and copy a pre-built image including all needed software onto an 4 GB or greater flash drive. The live iso image may be obtained by visiting, choosing a "flavour" (probably 64bits) and downloading. Total size is close to 1GB so the resulting iso image will have to be burned on a flash drive or blank DVD disk. I have already burned 10 DVD disks and you may borrow one from me, if you wish.

At this point, using this install disk or USB drive, you can install Linux directly on a partition of the hard drive or SSD or in a virtual machine such as VirtualBox, or on a second USB flash drive. It is far less risky to install in a virtual machine or on a USB drive. However, performance is lacking in a VM. A USB drive is a happy compromise as performance is not bad and there is no risk as long as the install is done carefully. Instructions for each of these installations follows.

Install Linux on the hard drive or SSD:
Boot from the above mentioned install disk or USB drive. Note, you can choose to install side-by-side with Windows, assuming you are on a Windows computer, or you can blow Windows away and let Linux occupy the entire hard drive or SSD. You may wish to change the partition table and partition sizes so Linux can be installed. This will require getting gparted. Download gparted live, reboot from that disk, and resize the chosen partition to leave about 20GB or more free for linux. Please note that this is a potentially dangerous operation and should be done with great care. If you are the slightest bit squeamish, install Linux on a virtual machine like VirtualBox. If you went ahead and repartitioned, save the changes (hit "Apply"). Remove the gparted disk, insert the Linux OS install disk and reboot. Respond appropriately to the prompts. The only place that a problem might occur is in finding a place for linux on the hard drive. If all goes well the installer will take care of this automatically. But, you may have to reclaim space for the install to succeed. Be really careful, in that case, because this process can seriously overwrite data if you are not watching carefully. During the install process you will be asked for a user account name and password. Save this information. When the install is completed reboot (with the disk out of the drive). Use the username and password of the account you created to login. Open a terminal by clicking the upper left icon on the desktop (when it appears) and typing "terminal" into the search textfield that gets displayed.

If you got this far the OS is probably working so proceed to update the system. Become root in the terminal like this:

  prompt> sudo su
  password for user: <type-user-password-here>
where text in red is what you type and text in blue represents system prompts. Then update like this:
  prompt> apt-get update
  prompt> apt-get upgrade

Install Linux on a USB drive (16GB or greater):
Follow instructions for installing on a hard drive except insert the blank USB drive after booting and choose the USB drive as the install target when asked to choose a place to put the operating system.

Copy a ready-made Ubuntu image (for UEFI) to a USB stick: There is an image ubuntu-14.04.1-LTS.iso that includes all needed software. The user account name is student with password student. This is an Ubuntu stick so there is no root password - to become super user follow the procedure given above. The image's size is 4 GB and will probably take some time to download. Make sure there is enough space on your target drive to store this iso file. When done, insert a stick (must have at least 4 GB capacity) into a USB port. From a Windows or Mac box, use the standard tools for burning an image to a stick. From a Linux box determine the device the stick associates with using dmesg right after inserting it. The device is usually /dev/sdb but can be /dev/sdc or /dev/sdd etc. Assuming it is /dev/sdb, do this as root:

   prompt> dd if=ubuntu-14.04.1-LTS.iso of=/dev/sdb
Then update the system like this, as root:
   prompt> apt-get update
   prompt> apt-get upgrade
To enter the gnome gui, start the computer with the stick in, boot with the OS boot manager (usually F9 or F12 or Escape to get the menu), enter 'student' as user and 'student' as password.

Install Linux in Virtualbox: Get and install VirtualBox (free download for the later, and it seems to work well). From here on it is best to watch this youtube video.
important: choose more than one virtual CPU or else your results will be wrong in some labs!!!
important: after installation, update and upgrade as above.

Install Linux over the internet
See the official documentation.
important: after installation, update and upgrade as above.

Run Linux:
The bootloader is called grub2. Upon boot a menu appears. A kernel to boot may be selected from this menu. After selection, hit return. A default selection is booted if no user response is detected in 10 seconds.