User-mode Linux at IMADA
In the following we describe how to install and use User-mode Linux (UML) for DM14 at IMADA. If you have any problems, have a look at the FAQ.
All the files mentioned below, can also be found here.
How to install User-mode Linux at IMADA
Login at any IMADA machine and write
cd /home/DM14/<login>
where <login> is your IMADA/MIP login.
Next, get the source code for Linux and all the other necessary files for DM14
by writing
tar xvjf ../dm14/linux-2.6.10.tar.bz2
Enter the directory containing the kernel source files:
cd linux-2.6.10
To make this a working copy of UML, you also need to have a configuration
file (.config), a root file system (root_fs), and
some extra files (ummake and run_linux).
cp ../../dm14/{.config,root_fs.bz2} ../../dm14/bin/* .
bunzip2 root_fs.bz2
You are now ready to start using UML.
How to compile User-mode Linux
Usually you will compile UML using the following command:
make ARCH=um linux
Have a look at man make, if you want to know what
make does. ARCH=um ensures that the kernel you are
building is a UML kernel.
You can also compile UML using this command instead:
./ummake linux
ummake is a small script which makes the compilation run
faster. Apart from this, ummake is basically the same as
make ARCH=um. Have a look at the file itself to see, what it
actually does.
How to run User-mode Linux
Due to problems with NFS, the root file system for UML needs to be kept at
/tmp and not in /home/DM14/<login>/... To make
life easier for you, you can use the following small script to run UML. This
script copies your root file system from the current directory to
/tmp and then runs UML.
./run_linux
When running UML, you can login using the user name root with
no password. All files from /home/DM14/ are also available in the
directory /home/DM14/ inside UML. To stop the UML system you can
run the command halt.

Frequently asked questions (FAQ)
- When I try to run UML, I get the following error. Why?
-
This is most likely because you are trying to run two UML processes at the same time. Kill all running UML processes with the command
<snip> Failed to lock '/tmp/root_fs_<login>', err = 11 Initializing stdio console driver VFS: Cannot open root device "98:0" or unknown-block(98,0) Please append a correct "root=" boot option Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(98,0) </snip>
killall -9 linux. Next, try to run UML again using./run_linux. If this does not work, you can also try to delete your root file system in /tmp by usingrm /tmp/root_fs_<login>. - Changes I make inside UML in the root file systems, sometimes seems to be lost when I run UML the next time?
- The root file system is only saved in the temporary directory
/tmp. Occasionally, the contents of this directory is deleted, and a fresh copy of the root file system is copied byrun_linuxto/tmp. If you want to preserve the changes you have made, you need to copy the changed root file system from/tmpto your own directory, i.e.,cp /tmp/root_fs_<login> /home/DM14/<login>/linux-2.6.10/root_fs. - How can I avoid UML running xterms? I want to run UML at IMADA using Putty from my Windows machine without X at home.
- To do this both
/etc/inittabin the root file system and the configuration of UML needs to be changed slightly. The easiest way to do this is to use the modified files that already have been made available:cd /home/DM14/<login>/linux-2.6.10 rm root_fs /tmp/root_fs bunzip2 < ../../dm14/root_fs_noxterm.bz2 > root_fs cp ../../dm14/.config_noxterm .config ./ummake clean