Classic, Textual Install

In this section you will find the information about a classic, textual end-user installation.

Preparing for an Installation

After a successful build of T2, or after downloading a prebuild ISO image it is time to install: burn the images onto your optical media such as CD or DVD (see the section called “Creating an ISO Image (for CD-ROM Installation)”) and/or create the bootable floppies.

It is perhaps also a good idea to make backups of the partitions you intend to overwrite. The dd or cat in combination with the gzip or bzip2 command can provide a compressed byte-to-byte copy to another hard-disk or NFS mounted file system. For example:

cat /dev/disks/diskX/part1 > /mnt/net/diskX_part1.img.gz
cat /dev/disks/diskX/part1 | gzip --fast > /mnt/net/diskX_part1.img.gz
cat /dev/disks/diskX/part1 | gzip > /mnt/net/diskX_part1.img.gz
cat /dev/disks/diskX/part1 | gzip --best > /mnt/net/diskX_part1.img.gz
cat /dev/disks/diskX/part1 | bzip2 > /mnt/net/diskX_part1.img.bz

Which set of commands you want to use for the backup depends on personal taste and the time and space requirements you have. From the top down to the bottom, the listed commands with compression require more time but the images consumes less disk space for the backup file.

A compromise is lzo compression in combination with the lzop command line frontend, it compresses quite fast (usually still I/O bound) but it is not necessarily available on every rescue system.

If you are overwriting a system with a special system configuration make notes on the existing installation, especially regarding hardware settings in:

  • boot loader configuration: lilo (/etc/lilo.conf), grub (/boot/grub/menu.lst), aboot (/etc/aboot.conf), silo (/etc/silo.conf), yaboot (/etc/yaboot.conf), ...
  • X configuration (usually /etc/X11/)
  • general T2 Linux system settings (/etc/conf)

which is often captured by just creating a backup of /etc and /boot.

The way to boot the CDs depends on the architecture:

CD-ROM Booting on x86

For the x86 architecture you need to enable boot from a CD-ROM in the BIOS. Often it is enabled by default, the CD just boots when inserted. The BIOS is usually reached by pressing the del or Ctrl-ESC key combination after power-on when the BIOS is executed - or you might need to reach the SCSI Adapter's BIOS using a key combination like Ctrl-A.

Latest EFI based Apple Macintosh Intel computers ship without a BIOS and require holding down the c or Option key while booting, see the next PowerPC section for details.

CD-ROM Booting on PowerPC

On the Apple Macintosh PowerPC architecture you just need to press the c key immediately during power-on when the screen is black and the OpenFirmware is executed. On newer machines (since around 2003) it is possible to get a graphical boot chooser by pressing the Option key (also known as 'fork' or 'alt' key). If you already are in the OpenFirmware you can boot the CD by entering 'boot cd'.

When an existing MacOS should be dual-booted it is most convenient to use the MacOS Disk Partition Utility to either resize the MacOS partition size or reinstall it if the Partition Utility does not support resizing. (Make sure you de-select 'Install Mac OS 9 Disk Drivers' if you do not want to waste extra disk-space and partitions for them.)

On early IBM workstations (e.g. based on the Carolina mainboard) you need to press F4 to enter the firmware(SMS).

For newer IBM server systems, like a RS/6000, you reach the Open Firmware by pressing F8 (or just 8 on a serial terminal) after the self-test completed. Just currently have to enter 'boot cdrom:,\install.bin' in the OpenFirmware.

On Motorola embedded boards (sometimes referred to as PowerPlus) you boot the first boot image at the PPCbug prompt with 'pboot 0 41' (assuming the CDROM is at SCSI ID 4 - replace the 4 with the SCSI ID of the CDROM if not). The second image can be booted via 'pboot 0 42', and so on.

CD-ROM Booting on SPARC

On Sun Microsystem's SPARC systems you need to press Stop-A to get to the OpenFirmware and enter 'boot cdrom'.

Bootable Floppies

The floppy images are in configid/bootdisk/floppy*.img. These images can also be found on some T2 mirrors. To copy the content to floppy-disks:

dd if=floppy1.img of=/dev/floppy/0  # or alternatively of=/dev/fd0
dd if=floppy2.img of=/dev/floppy/0  # or alternatively of=/dev/fd0
#...

(The Linux Boot-disk HOWTO might include more detailed information. \cite{BootHowto}).

Boot (First Stage)

The first output of the boot CD usually contains a greeting and a prompt. At this prompt just pressing enter usually results in the default kernel to be boot up. Some other kernels or test-utilities may also be present on the CD depending on the architecture (e.g. the x86/x86-64 images include a System Memory test application named memtest86).

After some initial kernel and ramdisk loading the first stage loader needs to load the real (and bigger) T2 installer from the media or network. Thus it tries to find optical media first and usually no interaction is necessary. Only if a first pass run is not able to find the second stage interaction is required. An example probing is shown below:

T2 SDE installer (1st stage - loader) ..

The T2 install system boots up in two stages. You are now in the first stage
and if everything goes right, you will not spend much time here. Just
configure the installation source so the second stage boot system can be
loaded and you can start the installation

     0. Load second stage system from local device
     1. Load second stage system from network
     2. Configure network interfaces
     3. Load kernel modules from this disk
     4. Load kernel modules from another disk
     5. Activate already formatted swap device
     6. Run shell (for experts!)

What do you want to do [0-6] (default=0)?

Select a device for loading the second stage system from:

     1. /dev/hdc SCSI or ATAPI CD-ROM

Enter number or device file name (default=1):

Select a second stage image file:

     1. 2nd_stage
     2. 2nd_stage_small

Enter number or image file name (default=1):

Using /dev/hdc: snd_stage
Extracting second stage filesystem ...

Since the second stage is loaded into the systems memory, the small and feature-reduced '2nd_stage_small' is needed for old system with less system memory.

Installation (Second Stage)

The second stage will only ask about the terminal type to use. Again, unless you are on a serial or network line you just want to hit enter:

T2 SDE installer (2nd stage) ...

This is a small Linux distribution, loaded into your computer's memory.
It has everything needed to install T2 Linux, restore an old installation
or perform some administrative tasks.

If you use a serial terminal, enter the names of terminal devices to use,
for example '/dev/ttyS0' for the first serial port or just '/dev/console',
just hit enter otherwise. (default=vc/1 vc/2 vc/3 vc/4 vc/5 vc/6):

Just type 'stone' now, if you want to perform a normal installation of T2.

Now you already have a fully functional Linux system to your fingertips, running from the systems RAM. It can be used for rescue maintenance tasks and to install T2 now:

stone

The installation is integrated into the T2 Linux Setup Tool One (STONE), which is stared via the command stone.

Partitioning the Hard-Drives

After asking for the keyboard layout the next screen will let you repartition the hard-disk by selecting the disk node and create file-systems or swap-space by selecting one of the partitions.

Partitioning the hard drive is a matter of taste. It is a good practice to have a partition with a basic bootable Linux system - and a working bootloader (which is great if you need something to fall back on). That can be very convenient for performing maintenance tasks. Some people like a small /boot partition for their kernels or need this due to and odd '1024 cylinder limitation' in older PC BIOSes, a partition for swap space and a large partition for the rest. Recommended are:

  • Another Operating System's partitions

    Since other operating systems might have limitations to be only bootable from the first partition or the habit to wipe the systems boot-configuration or Master-Boot-Record, it is the easiest just to install them first.

  • swap-space

    The 'swap-space' can be provided to allow the kernel to swap out pages of the system memory onto the hard-disk in order to provide more virtual memory then available as RAM inside the system.

    Size: For normal systems this is recommended and should be of the size: 2 x RAM - but does not need to exceed 256 MB. Since hard-disk are faster in the outer regions which is usually mapped to the beginning, the 'swap-space' should be in the beginning of the disk for performance reasons.

  • /

    The root partition where the system fits on.

    Size: Currently around 5GB for a complete installation with all provided packages.

  • /home

    The partition containing the end user files and application settings. It is convenient to have the user data on a separate partition to make a future installation or update easier.

    Size: Normally all the empty space left.

Optional partitions include:

  • /boot

    Some people like to separate the boot loader and kernel images into an own partition. This might even be necessary for old x86 boxes where the BIOS can only access the first 1024 cylinders. On PowerPC systems with Yaboot as boot loader a '/boot' partition must not be used.

    This seperate partition might also be necessary if a filesystem such as Ext4, Reise4, etc. or LVM/RAID is used which the boot-loader does not support to read.

    Size: Only a few MB are needed.

  • a second /

    For rescue or maintenance purposes a second, minimal installation can be considered.

    Size: Some hundred MB, depending on the rescue feature set.

For architecture dependent examples see Appendix Appendix A, Partitioning Examples. When you finished the partition of the disk select 'Install the system ...'. If you have trouble in this phase you hopefully find help in section the section called “Troubleshooting”.

Installation Source

Now you can select an install source - usually a CD-ROM or a network URL. For a normal installation the default values are ok and you simply select 'Start gasgui Package Manager (recommended)'.

The installer will read the package database from the installation source and present a list of profiles (e.g. minimal or full workstation) with default package selections. You can alter the list including using automated dependency resolution.

Selecting 'install' will extract all the package selected and ask for the disk if a CD installation is performed. Make sure you have your preferred tea, coffee of book handy.

Post Installation

After the package extraction the STONE utility will lead you through a number of questions like the root password, keyboard mapping, language, hardware, network and offer you the possibility to setup your favorite boot loader. Do not forget to enable one of the boot-loaders if you want like to be able to boot into the freshly installed system later.

You can rerun this setup anytime in your installed system by executing stone.

If you want or need to perform other changes before the first boot, you can do so by chroot-ing into the new target system in /mnt/target:

chroot /mnt/target /bin/bash

If the machine you are installing on has no monitor it may be useful to set up serial support for the bootloader and init (for more information see Appendix Appendix B, Serial Console).

Cross fingers: Now you should be able to boot into your freshly installed system. Unmount the file-systems and reboot executing the minimalistic 'shutdown' present on the install-system.

Since T2 Linux users like to keep their systems up-to-date they usually make a copy of their /etc and /home directories and, with reasonable efficiency, duplicate the older settings.

To automate rebuilding your configuration it is possible to use Cfengine (the GNU Configuration Engine, see appendix the section called “CFEngine - a Configuration Engine”).