-
Notifications
You must be signed in to change notification settings - Fork 0
Automated OS Install
Because life is treacherous, one of our servers can go down and lose its data. It is important to be able to restore functionality to the server as fast as possible to minimize downtime. One of the steps to allow this is to be able to install and set up the OS automatically without any manual intervention. It is also important for this to be an offline process, as the wifi in NIAEFEUP's room depends on the servers, making a circular dependency.
Our solution was Rocky NInux, a customized image of Rocky Linux designed to run on our servers, able to be installed automatically with everything needed and no human intervention.
- Clone the niployments repo from GitHub.
- Make sure you have xorriso installed in your machine.
- Run
create_iso.sh
in foldernode
. This will download an image for Rocky Linux (rocky.iso
) and create the custom ISO imageninux.iso
. - Copy
ninux.iso
to a bootable flash drive (for example, using Gnome Disks or dd in the command line). - Plug the flash drive into the server and boot it from the flash drive.
- Patiently wait for the OS to be automatically installed. Hopefully you won't need to touch the computer at all for this process to be concluded successfully.
Rocky Linux is a free, open-source version of Red Hat Linux. We chose this over Debian Linux because Rocky allows for an offline automatic installation, while Debian requires internet connectivity to be installed. We also needed to configure some custom settings in the original Rocky ISO, and that's why we called it NInux :)
Some default configurations were set up, like the keyboard and system language. Most importantly, a default SSH key is set up, to enable remote access to the new node. We also made the OS boot in grub, as to allow booting in both BIOS and UEFI mode.
- username: ni
- password: n1bl04t:)
πππππππππππ (βΈβΈβΈ>οΉ<βΈβΈβΈ)