Operating Systems and Systems Integration

The Rescue Disk, Trouble Shooting and other Related Topics

1 Aim

After completing this exercise, you will:

• be aware of the usefulness of mini-Linux distributions in solving many problems, many of which are not Linux problems

• have practical experience with one of the best mini-Linux distributions, tomsrtbt,

     available from http://www.toms.net/rb/.

• be introduced to a shell script report that may be used to diagnose many computer problems, and through that:

∘ learn some aspects of shell script programming

∘ learn about the Linux /proc file system and its usefulness in describing the computer and its operation, as well as the operation of the operating system

2 Procedure

2.1 A mini-Linux distribution: tomsrtbt

The mini Linux distribution tomsrtbt is useful for recovering from many problems; it can be used to start a restore from backups after the hard disk has been completely destroyed. It is also useful as a trouble-shooting aid. This is how we will use it today.

Note that tomsrtbt uses the old libc5 libraries, which are not included in Red Hat 7.0 and later. You will need to install these libraries to be able to work with tomsrtbt. It is convenient to install them from Red Hat 6.2.

1. NFS mount the ftp directory from CSAlinux:

     $ sudo mount CSAlinux:/var/ftp/pub /mnt

2. Change to the Red Hat 6.2 RPM directory:

     $ cd /mnt/redhat-6.2/RedHat/RPMS

3. Install the libc5 libraries:

The Rescue Disk, Trouble Shooting and other Related Topics Operating Systems and Systems Integration

2

$ sudo rpm -Uhv ld.so-1.9.5-13.i386.rpm libc-5.3.12-31.i386.rpm

Use the [figure: Tab]key to complete the filenames rather than typing all the numbers in manually.

4. Change to your home directory.

5. Extract the contents of the file tomsrtbt-1.7.218.tar.gz with the command

$ tar xvzf /mnt/tomsrtbt/tomsrtbt-1.7.218.tar.gz

Again, use filename completion.

6. Unmount the network file system from CSAlinux:

$ sudo umount /mnt

7. Install tomsrtbt on your floppy disk by changing into the directory ∼/tomsrtbt-1.7.218 and typing

$ sudo ./install.s

8. If you do not see the message “Succeeded!” after a few minutes of disk activity, your floppy disk has some defects; since it needs to be formatted with a high capacity, the floppy disk needs to be in new condition. Use a new floppy disk.

9. Boot a computer with this floppy disk.

10. Log in as root.

11. Change to the directory /proc and examine the content of the files cpuinfo, meminfo, interrupts, pci. Can you imagine any uses for these files?

12. List the partition information on your computer.

2.2 The shell script report

1. Download the shell script report from http://CSAlinux.tycm.vtc.edu.hk/ossi/lab/tomsrtbt/report

(from the subject home page), and save it to your ∼/bin directory (create ∼/bin if it doesn’t exist).

2. Make it executable (you should know how!), then execute it to see what it does.

3. Take a few minutes to look at the files that have been made in the directory /tmp/reports. What could these files be used for?