Hard drive installation

Finnix, the LiveCD for system administrators

Finnix available from grub in a Debian installation.

Full installation

Finnix versions 86.2 through 90.0 included the ability to be extracted to a hard drive and run as a full operating system, much like Knoppix's ability. However, this had several disadvantages: the procedure was complicated, and when you were done, you were essentially left with a wholly unsupported Debian installation, so why not install directly from Debian?

Plus, fundamentally, Finnix is a utility CD. It works great for what it is designed to do, but in the end, it is just not meant to be run as a permanent installation.

After version 90.0 was released, it was determined that the compatibility code to support full installation booting was hampering other functionality, and was removed as of Finnix 91.0.

LiveCD on a hard drive

Since version 87.0, Finnix has had the ability to be copied to a partition and run by grub as if it were running as a full Finnix LiveCD. This method is better than the above (deprecated) permanent installation method, as it only requires a single additional partition, and boots Finnix exactly as if it were running from a CD.

Uses

  • Install it on your workstation to always have a version of Finnix handy.
  • Sending a colocated server out of town? Install Finnix on a partition to make it easier for remote hands in case something goes wrong.
  • Install Finnix on a partition on a server that does not have a CDROM drive. If something goes wrong, it's easier to boot Finnix from the hard drive than to netboot or hunt down a USB CDROM drive.

Dedicated partition (GRUB 1)

This procedure assumes you're installing a new Linux distribution with grub. You could always install Finnix and grub on, say, a Windows workstation, but it would involve a lot more work and extra steps to get a standalone copy of grub installed.

1. While partitioning, leave an extra, empty partition available for Finnix later on. While modern systems can boot from just about anywhere, it's good form to locate the partition within the first 8GB of the disk for a bootable partition.

Make sure the partition is large enough. While Finnix CDs are currently just over 100MiB, the long-term goal of Finnix is to never get above 185MiB, so 200MiB would be a good round number for this partition, to allow for future Finnix upgrades.

Be sure to install onto a primary or logical partition. Finnix's initrd cannot find itself on LVM, software RAID or encrypted volumes (though it can mount these types of volumes once it has found itself).

While it's not required by grub, it's good form to set the partition as bootable.

For the rest of the document, we'll assume your Finnix partition is /dev/hda2.

2. Install your regular Linux distribution as normal, and boot into it.

3. Format /dev/hda2 as ext2 or vfat. Do not use ext3, as it's not needed: Finnix's stage 1 only includes ext2/vfat/iso9660 support, and the partition will be mounted read-only, so there is no need to use ext3.

# mke2fs /dev/hda2

or

# mkdosfs /dev/hda2

4. Mount the Finnix partition somewhere. This does not have to be a permanent mount, but just to copy the files from the CD into it.

# mkdir -p /mnt/finnix
# mount /dev/hda2 /mnt/finnix

5. Mount the Finnix CD and copy the contents to the Finnix partition.

# mount /cdrom
# cp -a /cdrom/* /mnt/finnix/

6. Unmount the CDROM and Finnix partition.

# umount /cdrom
# umount /mnt/finnix

7. Add a configuration block for Finnix to the appropriate section of your /boot/grub/menu.lst.

title           Finnix
root            (hd0,1)
kernel          /isolinux/linux root=/dev/hda2
initrd          /isolinux/initrd.gz

Again, (hd0,1) assumes your partition is /dev/hda2. root=/dev/hda2 isn't required, as Finnix will scan partitions to find itself, but it's slightly more efficient and reliable to specify it. Use "linux64" instead of "linux" to boot the 64-bit kernel.

8. That's it! You should now be able to boot Finnix from a hard drive partition, as if it were a CD. When a new version of Finnix comes out, simply remove the old contents of your Finnix partition, and copy the contents of the new CD in place. (Be careful that the location of the kernel and initrd haven't changed on the CD layout for new versions, though.)

NB: You can also just dd the Finnix ISO directly to a partition. However, if you do that, you will need to copy the kernel and initrd to another partition, since many grub installs cannot understand iso9660 partitions.

ISO loopback boot (GRUB 2)

As of Finnix 107, you may place individual ISOs directly on a host filesystem and set up GRUB 2 and Finnix to locate and boot from them. This relies on the ability for GRUB 2 to mount an ISO loopback to read and boot the kernel and initrd. GRUB then passes the path/name of the ISO to the Finnix initrd, which then searches for the partition containing it. It mounts that loopback, and uses it as if it were a physical CD.

Note that the ISOs must be placed on a compatible partition. No LVM or encrypted partitions (Finnix's first-stage initrd cannot recognize them), and the filesystem must be ext2, ext3 or vfat (not ext4).

Create an entry in /boot/grub/grub.cfg, as so:

menuentry "Finnix" {
        insmod part_msdos
        insmod ext2
        set root='(hd0,msdos1)'
        search --no-floppy --fs-uuid --set=root ca4ca395-84b7-4a66-8406-34898acf9fdb
        insmod iso9660
        loopback loop /path/to/finnix.iso
        linux (loop)/boot/x86/linux findiso=/path/to/finnix.iso quiet
        initrd (loop)/boot/x86/initrd.xz
}

Replace the UUID with the UUID of the filesystem containing the ISO. If you want to use the 64-bit kernel, replace "/boot/x86/linux" with "/boot/x86/linux64" (or just add a new entry for the 64-bit kernel).

Note that the path to the ISO is relative to the mount, so if the partition isn't the root of the system, adjust accordingly.

On Debian or Ubuntu systems, there is a package, grub-finnix, which helps automate this. It supports multiple Finnix ISOs, and will automatically figure out the kernel, initrd, relative paths, etc. It hooks into Debian's update-grub system, so these entries will be kept up to date. grub-finnix is not yet in Debian main (see Debian bug #693774), but in the meantime you may manually download a package from the Ubuntu PPA; they will work correctly on Debian.

Once the package is installed, edit /etc/default/grub-finnix, set FINNIX ISO to a Finnix ISO (or a directory containing multiple Finnix ISOs), and run "update-grub2".

Personal tools