Practical Exercises To be completed due by 2/7/2008
Boot the system from the CD and follow the installer
instructions. When prompted for the installation type, choose
In this exercise, you don't care about installing various software since the
system is going to be reinstalled again in the next exercise. To save time, install only the base system, skip software installation and APT configuration.
After reboot, you should be able to login into the new system as root.
Generate a list of installed packages on your desktop and store it
in a file:
cd /etc
dpkg -l > old_system.txt
cd /etc
tar -zcvf old_system.tgz hosts hostname resolv.conf X11
mke2fs /dev/fd0
mkdir /floppy
mount /dev/fd0 /floppy
cp /etc/old_system.tgz /floppy
cp /etc/old_system.txt /floppy
umount /floppy
Use a Debian Etch 4.0 network install CD located by your desktop.
http
Edit countries list by hand
Enter information manually
for host type in:
192.168.5.55; for directory: /
It is obvious to choose the nearest Debian mirror. In our case, it is a server in the Unisys lab. If you are at home and
want to install Debian on your computer there, choose one of the official
Debian mirrors.
For partitioning, you can choose the following layout, or stay close to it:
IDE1 master (hda)
#1 primary 256 MB ext3 /
#2 primary 512 MB swap swap
#5 logical 512 MB ext3 /var
#6 logical 3.0 GB ext3 /usr
#7 logical 1.0 GB ext3 /tmp
#8 logical leftover ext3 /home
Download the preseed.cfg configuration file from http://linuxcourse.rutgers.edu/lessons/lesson2/preseed.cfg:
wget http://linuxcourse.rutgers.edu/lessons/lesson2/preseed.cfg
mount /dev/fd0 /floppy
cp preseed.cfg /floppy
umount /floppy
linux preseed/file=/floppy/preseed.cfg debconf/priority=critical
As you may have noticed, the newly installed system is not configured, for example, you can not get the original desktop after you run startx; the host name is the default, debian.
Mount the floppy with the two files created in the first exercise and
copy the one with the configuration archive into /etc and the other
into /root:
mkdir /floppy
mount /dev/fd0 /floppy
cp /floppy/old_system.tgz /etc
cp /floppy/old_system.txt /root
cd /etc
tar -zxvf old_system.tgz
Configure APT:
Open file /etc/apt/sources.list with an editor and leave there only the following two lines:
deb http://192.168.5.55/ etch main contrib non-free
deb http://security.debian.org/debian-security etch/updates main contrib non-free
apt-get update
Copy file /root/old_system.txt into your current working directory.
Generate a list of installed packages on your new system and store it
in a file:
dpkg -l > new_system.txt
Comparing files new_system.txt and old_system.txt, you can see what packages have not been installed on
the new system.
To compare the content of the two files, download a script,
make_update_list.sh.
You can use either the browser or command wget
to fetch the file:
wget http://linuxcourse.rutgers.edu/lessons/lesson2/make_update_list.sh
chmod u+x make_update_list.sh
./make_update_list.sh old_system.txt new_system.txt
wc -l diff.txt
By using APT, install g++:
apt-get install g++
By using APT, install xfce4:
apt-get install xfce4
Again, check the number of the absent packages:
dpkg -l > new_system.txt
./make_update_list.sh old_system.txt new_system.txt
wc -l diff.txt
Check the version of the Kernel installed
uname -r
Install the newest available version of the Kernel (2.6.18-6) by using APT:
apt-get install linux-image-2.6.18-6-686
Remove the old Kernel from the system:
apt-get remove linux-image-2.6.18-5-686
Sec. 24.2
APT manual