Chapter 4. Installing your Image

After installing a new HDD into the KuroBox (or perhaps one from another machine) the KuroBox will boot into a reserved mode. This reserved mode will run a telnet daemon and an ftp daemon which you can use to transfer your new image to the disk.

4.1. Preparation

After you've telnet'ed into your KuroBox, the first thing to do is to prepare the HDD to accept an image. For this we will run the mfdisk -c command on our HDD:

# mfdisk -c /dev/hda
       
This command works exactly like the well-known fdisk command so I won't bother with a detailed explanation. Just make sure that you reflect in the ${IMAGE}/etc/fstab file the same work you do partitioning the disk. You must also make sure that the mount point directories exist before mount tries to mount the disk partitions during the init script.

For example purposes for my own use I simply created two partitions:

partitionpurpose
/dev/hda1root filesystem
/dev/hda2swap

After you've created all your partitions you then have to format them. I'm not 100% sure of all the formats that are supported by the KuroBox kernel, but I do know that ext3 works and is a good filesystem for most purposes. The command to format your partitions with ext3 is mkfs -j:

# mkfs -j /dev/hda1
       

Be sure create and format your swap partition too:

# mkswap /dev/hda2
       

Now that your partitions are ready to go, mount them:

# mkdir /mnt/root
# mount /dev/hda1 /mnt/root