This is step by step instruction for using CRI as Linux installer. Currently CRI supports installation of following distributions: 1. TLD Linux http://tld-linux.org/ 2. Debian http://www.debian.org/ 3. Devuan http://devuan.org/ 4. Ubuntu Server LTS http://www.ubuntu.com/server You may also use CRI as rescue/recovery disk for any Linux distribution. ---------------------------------- | Step 1: pre-installation tasks | ---------------------------------- Before you will proceed with installation you must prepare your destination devices. CRI doesn't provide wizards to manage storage devices so you'll have to do everything by hand. Start with partitioning your disks with cfdisk, fdisk, gdisk or parted. If you have devices larger than 2TB be sure to choose utility that supports GPT partition tables. When your partitions are ready you may want to create RAID, LVM or LUKS volumes. Software RAID ------------- To create RAID1 array consisting of 2 SCSI partitions: # mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sda1 /dev/sdb1 Partitions for RAID devices must be of type fd or FD00 (raid auto-detect). To manually assemble previously created or existing RAID array: # mdadm --assemble /dev/md1 /dev/vda3 /dev/vdb3 /dev/vdc3 You may also try to automatically assemble all existing arrays if for some reason they were not assembled during boot: # mdadm --assemble --scan LVM --- To create new LVM volume you must first initialize physical volumes for your LVM configuration. You may do that by using command 'pvcreate'. # pvcreate /dev/md1 Next step is creation of LVM volume groups using command 'vgcreate': # vgcreate lvm_storage /dev/md1 When volume group is defined you may create logical volumes in it. For example to create 10GB volume for root filesystem and 20 GB for /home: # lvcreate -L 10G -n root lvm_storage # lvcreate -L 20G -n home lvm_storage If you have previously created or existing LVM config you may activate it manually (should be done auotmatically during boot): # vgchange -a y LUKS ---- To create encrypted LUKS volume you must use luksFormat command: # cryptsetup -v luksFormat /dev/md2 When prompted enter passphrase for your device. To access contents of LUKS volume you must use luksOpen command: # cryptsetup -v luksOpen /dev/md2 crypted_raid Creating filesystems -------------------- When your devices are ready, create filesystems of your choice. For example: # mkswap /dev/lvm_storage/swap # mkfs.ext4 /dev/md0 # mkfs.ext4 /dev/lvm_storage/root # mkfs.ext4 /dev/lvm_storage/home # mkfs.xfs /dev/mapper/crypted_raid Network based installations --------------------------- For network based installations you must configure your network devices. You may easily do it using 'netconfig' command. It is simple wizard that allows to configure ethernet and wireless interfaces. Additionally it supports creating VLAN, bonding and bridge interfaces. ------------------------ | Step 2: installation | ------------------------ You are almost ready to install your selected Linux distribution. Please mount all your destination devices on some directory. For example: # mount -t ext4 /dev/lvm_storage/root /chroot # mkdir /chroot/{boot,crypt,home} # mount -t ext4 /dev/md0 /chroot/boot # mount -t ext4 /dev/lvm_storage/home /chroot/home # mount -t xfs /dev/mapper/crypted_raid /chroot/crypt When done please execute installation procedure by using one of commands: crinstall - to install any supported system from preconfigured chroot archive debinstall - to install Debian/Devuan/Ubuntu from officiall mirrors tldinstall - to install TLD Linux from official mirrors Note: chroot archives used by crinstall may not be up to date. Be sure to update your system after boot. Using debinstall or tldinstall will result in installation of up to date system with all updates already applied. Provide directory path to which system will be installed as parameter, for example: # crinstall /chroot You will be prompted for basic system configuration like hostname, timezone, root password, first user account, bootloader installation etc. After that you will have to choose mirror or other source location to install from and choose system and/or version you wish to install. Thats all. Confirm your installation and patiently wait for it to finish. It may take few minutes especially when using debinstall or tldinstall. When completed CRI will tell you if installation was successfull or not. Installation notes ------------------ There are few problems/limitations you should be aware of before installing selected Linux distribution: 1. Some bootloaders require RAID partition used for /boot to use specific metadata format. Be sure to check this or your system may not boot. Also make sure that RAID level used for /boot is 1 (mirror). 2. When using GPT don't forget to create BIOS partition for GRUB. It must have at least 1 MB size and must be of type EF02. Without this partition GRUB will fail to install. 3. If you have used encrypted LUKS volumes for your installation remember that after reboot your system will be waiting for someone to type decryption password on local console. If this is not what you want, be sure to configure your installed system for automatic unlocking (e.g. using USB key) before rebooting. Note: CRI supports crypttab entries for LUKS volumes only! 4. It is strongly advised to use same CRI distribution as installed system. For example to install Debian use Debian based CRI image. Not doing so may cause initrd/initramfs images to be created incorrectly which will prevent your system from booting. 5. On some hardware initrd/initramfs created using CRI may not contain all necessary modules (e.g. raid or crypto ones). If your system fails to boot try forcing these modules to be added to initrd/initramfs.