OPERATING SYSTEMS ICOMS W4118, Dept of Computer Science, Columbia University
Home | Announcements | Lectures | Homeworks | Grades | Discussion | Resources | Facebook

"Try not to become a man of success but rather to become a man of value." -- Albert Einstein
OS RESOURCES
This page is designed to provide resources that will facilitate the programming assignments. There is information about C (the language in which most of the Linux kernel is written), a variety of links about Linux, information about the development environment and how to connect to it, and finally some tools for collaborating with your fellow group members.
LINUX RESOURCES
There are a huge number of Linux resources available on the web that come from a large community of people who have worked with the Linux kernel.
VMWARE RESOURCES
VMware is a virtual computer that emulates the hardware of a machine so that you can run an entirely different operating on top of one that is already running. This is ideal for operating system development because if something goes wrong with the system that is running on the virtual machine, the entire computer does not crash. A pair of VMware ESX servers is installed, and VM guests will be allocated on these servers.

To use VMware on the ESX servers, you first need an MRL account . If this is the first time you setup this account, or if you reset your password, you must then change your password in the MRL lab at least once.

Each student will have his/her own VM guest. To be allocated a VM, send a request by email to the w4118 mailing list. A VM will be instantiated or you from the course template. The VMs will have a user student for you to login. When your VM is ready for use you will get a confirmation email, together with your (personal) password for that user.

Note: the data stored within your VM is not backed up. Make sure you keep copies of your work elsewhere, e.g. on your home directory. VMware provides a useful feature that enables you to take snapshots of your VM and later use these snapshots. Thus you can take a snapshot before testing your modified kernel, to facilitate easy recovery should the VM crash its file system. We recommend that you make at least one snapshot (after you have downloaded the kernel sources, patched them, and compiled them).

By default, the VMs runs a special utility called VMware Tools, that provides useful functionality between the host and the guest VM. This utility depends on the specific kernel that runs in the VM. Therefore, when you install a new kernel for the first time (or when you make substantial changes to an existing kernel, such as changes to include files), it is necessary to adjust the VMware Tools accordingly. To do this, boot the new kernel, and then run vmware-config-tools.pl (hit Enter at all prompts).

  • Using VMware On Linux:
    • Connecting to the VM via Virtual Infrastructure Client:
      If you use a windows machine, you can download the VMware Virtual Infrastructure Client (VIC). The VIC provides a convenient interface to access and control your VM (see the VIC documentation).
    • Connecting to the VM via Virtual Infrastructure web interface:
      You can access and control your VM via VMware's web interface through here. If you are using Firefox on certain Linux systems, you may experience some difficulties using the console plugin. This can be fixed by copying the plugin files (viewer and remotemks from ~/.mozilla/plugins to /usr/lib/firefox/plugins (see this thread).
    • Connecting to the VM via ssh:
      Our VMware servers are set up to allow users to ssh into their virtual machine through a dedicate gateway machine (vm-gw01 and vm-gw02). The best way to find out the IP address of the VM is on your machine is to boot up the virtual machine (using X or VNC) and type 'ifconfig' to get the IP information. If the VMware tools are setup correctly in the VM (by default they are), then you can look up the IP in the "summary" tab via the control interface.
      Then you can use the IP address to ssh or ftp into the machine from the host machine. This is only a local IP address, so you cannot ssh directly into the VM from the outside world.
    • General VMware Documentation:

C PROGRAMMING RESOURCES
The Linux kernel is written almost entirely in C, so for those unfamiliar with C, here are some links that provide some explanations.
REMOTE ACCESS INFORMATION
The virtual machines on which you will need to do the kernel modifications required for the assignments are located in the CLIC Lab. VMware requires X to run, so if you cannot work in the Clic Lab, you will need to connect to the VM remotely using one of the following methods.
  • X Server
    If you are running a Unix-based operating system or have an X Server running on your local computer, you can use X to access your virtual machine. X-Win32 is available for running X on Windows PCs. This is probably the easiest way to use VMware, but you may run into firewall problems if you are off campus.
    To do this:
    • From a Unix-based computer, just run:
      $ ssh -X mymachine.clic.cs.columbia.edu
    • If you're running Windows, you can find instructions on how to forward remote X connections using different ssh programs here
    • Now you can run VMware, Emacs, or any other application that requires X with no problem.
  • VNC
    According to the VNC website: "VNC stands for Virtual Network Computing. It is, in essence, a remote display system which allows you to view a computing 'desktop' environment not only on the machine where it is running, but from anywhere on the Internet and from a wide variety of machine architectures."
    There is a free client available for VNC, so it is very easy to access. It is also extremely lightweight and can save your session on the server in between logins. However, it can be slower over the network.
  • SSH
    Once a virtual machine is up and running, you can ssh into it from the machine on which the VM is running. This requires that the VM be started either locally on the machine itself, or from a VNC or X session. Once this is done, the IP address can be used to connect to the VM after ssh-ing into the local machine. (See VMware Info for info on how this works)

COLLABORATION TOOLS
All major programming projects will be done in groups of three. To facilitate collaboration among group members (some of whom may not be on campus), there are some resources available to help out. CVS and RCS are popular methods of retaining source code integrity. Also, Instant Messaging allows for quick communication, whether it be a commercial product or using the 'talk' command on the cunix or cs machines.
  • Source Code Management
    • CVS us a version control system that enables you to log all changes made to a body of source code. It also makes patches and does lots of cool stuff to keep track of your source code: CVS Manual
    • RCS is another version control system, but a little more lightweight. It allows files to be stored in a directory without downloading them to another directory: RCS Mini-HowTo
  • Instant Messenging