aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'docs/guides/Guide-Controller')
-rw-r--r--docs/guides/Guide-Controller60
1 files changed, 60 insertions, 0 deletions
diff --git a/docs/guides/Guide-Controller b/docs/guides/Guide-Controller
new file mode 100644
index 0000000..d618c36
--- /dev/null
+++ b/docs/guides/Guide-Controller
@@ -0,0 +1,60 @@
+# Guide for controller build
+
+The controller is a set of functions and scripts inside the initramfs image which is a product created by dracut package
+To read more about the controller's concep read man gse.5, while to read more about the controllers options read man ctfse.1
+Both of those man pages are under t he docs directory inside the project's git directory
+
+Note: Before you attempt to build the controller, your system (the one you use for the build) must support (include) the following packages:
+ - sys-apps/pciutils
+ - sys-fs/btrfs-progs
+ - sys-fs/cryptsetup
+ - app-crypt/gnupg
+ - sys-block/open-iscsi
+ - sys-block/nbd
+ - net-fs/nfs-utils
+ - net-nds/rpcbind
+ - dev-libs/openssl
+ - app-admin/syslog-ng
+ - sys-fs/device-mapper
+ - net-misc/dhcp
+ - sys-apps/iproute2
+
+The above packages are required for the dracut modules to function. A guid and detailed list about those can be found at: https://wiki.gentoo.org/wiki/Dracut
+
+
+To build the controller, run
+ - Create a kernel image with the modules and builtins you wish
+ - Build the controller:
+ - cd bin
+ - ./gse --build-controller --opt1 --opt2 --opt3 ...
+
+The created image will be saved inside dist.d directory. To use this image you need to create a bootable device.
+The device can be any physical medium that can be made bootable and support bootloader functions.
+
+The methos based on the drive's interface variate
+You can find a guide about configuring the devices for boot at the Gentoo wiki: https://wiki.gentoo.org/wiki/Handbook:AMD64/Full/Installation#Introduction_to_block_devices
+And you can find more informations about grub(if you choose grub as the bootloader) at: https://www.gnu.org/software/grub/manual/grub.html
+
+When you have a bootable medium there are only 4 steps left.
+ 1) Move the kernel & controller image to the bootable medium
+ 2) Update the grub.cfg entries to link on those images
+ 3) Pass the following parameters at grub.cfg kernels cmdline:
+ - root=LABEL=SYSFS
+ - rd.neednet=1
+ - ip=dhcp
+ - ctetc=1
+ Example: linux /vmlinuz-4.12.5-gentoo root=LABEL=SYSFS rd.neednet=1 ip=dhcp
+ 4) Create 3 partitions on the device/s you want with the following labels: SYSFS BACKUPFS BOOTFS
+ The BOOTFS label must be given to the bootable partition you created.
+ Example, if you wish to use /dev/sdb2 for system, /dev/sdc2 for backup partition
+ and your bootloader is on /dev/sda2 and all those partitions host ext4 filesystem, then:
+ e2label /dev/sda2 BOOTFS && mkfs.ext4 -L SYSFS /dev/sdb2 && mkfs.ext4 -L BACKUPFS /dev/sdc2
+
+ There is 1 more Label that can be created on anextra partition, but it is not essential for the boot process
+
+ This is: USERDATAFS. The USERDATAFS should be given at any drive that you wish to use for storage.
+ The USERDATAFS label provides an extra security layer from the controller, since all controller's actions are shielded on a device with such a label.
+
+When done, plug the bootable medium to a machine and boot it. If everything was done as should, the process should fetch an image, configure it and boot it.
+
+