Exceptional Installation Methods (for Expert Use)

Here we outline some exotic ways how to copy the build output or installed system to another location including the installation on other machine.

Extracting the Boot-Disks to a Hard-Disk

It is also possible to copy the cd-rom or floppy distribution to a disk partition and boot into that for installation.

For example untar the contained directories (on a newly mounted partition):

tar xvIf 2nd_stage.tar.gz

Now you have a tiny rescue or install system as present on the boot cd. You might like to modify your existing lilo.conf to point to the new partition or chroot into it:

chroot .
mount /dev
mount /proc

With extreme esoteric hardware you may have to install the Linux kernel sources and recompile the kernel using the chroot environment mentioned below.

Before rebooting from a changed lilo it is a good idea to set the root password and create (and test) a rescue floppy for your existing system. Or use one of the images from: http://www.ibiblio.org/pub/Linux/system/recovery/!INDEX.html (see also \cite{BootHowto}). It is also possible to dd the running kernel to a floppy and use rdev to set the root device and specify other switches. It is suggested to test that floppy on a system before running lilo!

Edit lilo.conf and run lilo (chroot'ed).

Direct Installation

Right after the build or on a binary CD/DVD distribution you basically have all the built binary packages packed in tar or GEM files. To install T2 Linux there is no real need to use the install program! It is quite easily just to create a target root directory (with or without NFS) and untar the packages you really need. Just as fast and often just as handy:

cd /mnt/target
for file in  list-of-tars ; do
  tar xvfI $file
done

Or you can use the mine (when you have the new T2 Linux GEM files):

mine -i -v -R/mnt/target list-of-gem-files

After a successful extraction it is the time to run some post-install programs, setting up the network environment, runlevels, services, X and other packages:

chroot /mnt/target /bin/bash
mount /dev
mount /proc
ldconfig
for x in /etc/cron.daily/*; do $x; done
source /etc/conf/devfs
stone

Of course this way it is also possible to run T2 chroot'ed on another distribution or a second T2 in T2.

1:1 Copy Using DD

Once you have a binary image, or an installed T2 system, you may want to deploy it across others.

Duplicating partitions can be done with dd:

dd if=/dev/discs/disc0/part7 of=/dev/discs/disc0/part5

Mind, this destroys everything on the target device (part5 in the above example). Be very careful in what you do here!

1:1 Copy Using Tar

A safer and more useful way - especially when the devices or partitions differ in size - is to tar up the file system and untar into the a new one. This way it is also possible to use another filesystem on the target device (e.g. exT2 to ReiserFS convertion):

cd /
echo 'dev
proc
sys
mnt' > exclude.txt
tar cp --exclude-from=exclude.txt . | (cd /mnt/target ; tar xpv)
mkdir /mnt/target/{dev,proc,mnt}

1:1 Copy Using Rsync

The safest, easierst and often fastest method, if available, to transfer a whole system is the rsync program. Rsync i a remote synchronisation application designed to transfer as few difference data as possible, and running it is as simple as:

rsync -axP / /mnt/target

Make sure to use the '-x' argument, as it prevents rsync from tranferring the content of additionally mounted file-systems, such as the virtual file-systems /dev, /proc, and /sys - but also remote shared etc. are not synced. However to transfer additional partitions mounted to /boot, /home and so on you need to add them additionally.

Making it bootable

Re-read section the section called “Boot Loader” for getting the system ready to boot from the new partition.