Docs: Add details to Gentoo documentation #90

Merged
Nick Alberelli merged 3 commits from docs/gentoo-guide-fixes into main 2023-06-20 19:09:48 +02:00
3 changed files with 64 additions and 29 deletions
Showing only changes of commit 86f7241f68 - Show all commits

View File

@ -1,12 +1,20 @@
# Install instructions for the studio systems
If you are installing the whole system from scratch you need to first to do three things:
1. Setup a place where the iPXE boot loader can access files.
2. Install the iPXE loader onto a USB stick
3. Install the build server.
After this is done, you can start rolling out the system to the client computers.
::: warning Work in Progress
20 June 2023 - IPXE Source Files have not yet been made public yet.
:::
If you are installing the whole system from scratch you need to first to do four things:
1. Clone `Repo_to_be_determined.com` to get the files
2. Run `build.sh` to setup the files needed by the IPXE bootloader
3. Create an HTTP server to host the IPXE files.
- For example to start an HTTP server using python run ` python -m http.server 8000` from the directory containing your IPXE Files
4. Create IPXE Boot Stick by running `file_to_be_determined.sh` from the`Repo_to_be_determined.com` repo. You will need to supply the script with the address for the above HTTP server.
After this is done, you can start installation of your build server and then client computers.
## Installing the build server server
@ -39,8 +47,18 @@ When these steps are complete, one simply has to wait for the installer to finis
## Installing client workstation
Installing the client computers is **almost** exactly the same as installing the server. The only difference is that you should select the first option “Boot Gentoo installer (Blender Institute Customized)” in the iPXE boot menu.
It will pull all programs and libraries from the build server.
::: warning Warning
The Gentoo Build Server must be online for the client workstation installer to work.
:::
1. Boot from the iPXE payload on the USB stick.
2. Select the first option “Boot Gentoo installer”
3. It will ask you to select keyboard layout, press enter if you want to use the default US layout
4. When the computer has successfully booted you will be prompted to select a Hostname and install location.
5. Once the installation is complete, it will ask to press any key to reboot.Everything should have been set up and configured, no additional configuration should be required.
::: info Install Duration
This is much faster than the server install process. On a **recent** workstation computer, the installation should complete in 15-20 minutes. On the more low powered computers in the office (the Intel NUCs for example), this will take around one hour or so.
:::
As with the server, once the installation is complete, it will ask to press any key to reboot.Everything should have been set up and configured, no additional configuration should be required.

View File

@ -1,30 +1,35 @@
# Workstation System Maintenance
## How to Update Workstation Server
1. Use `su` to Login as root or login as root directly
2. Use `cd` to enter root home folder
3. Run `update_build_server.sh`
## Push Updates to Client Workstations
To perform system updates, switch to the **root** user ****on the build server and run the “update_build_server.sh” script in the home folder of the root user.
Note that this script is packaged, so no changes should be made to it locally as those will be overwritten when updating.
## How to Update Build Server & Clients
The script will pull all of the latest changes from the main gentoo repository and initiate a system update. When done, it will ask if you want to push out the changes to the clients. The clients checks for updates every five minutes. If the server signals that there are updates, they will perform a sync with the build server and download and install all updated packages.
1. `ssh user@build-server-addr` connect to your build server via ssh
2. Use `su` to Login as root or login as root directly
3. Use `cd` to enter root home folder
4. Run `update_build_server.sh`
## Update addons on `/shared/software/addons`
1. Use `su` to Login as root or login as root directly
2. Run `emerge -1 flamenco` to update the flamenco addon
3. Run `emerge -1 blender-studio-tools` to update the studio addons
The software inside the `shared/software/addons` directory are Live Packages. Live Packages are packages that tracks the source-code repository directly and is not tied to a specific release.
::: warning Temporary Solution
This is a temporary solution that will be depreciated and replace with project based addons.
:::
1. `ssh user@build-server-addr` connect to your build server via ssh
2. Use `su` to Login as root or login as root directly
3. Run `emerge -1 {package-name}` to update a live package.
- Run `emerge -1 flamenco` to update the flamenco client/addon
- Run `emerge -1 blender-studio-tools` to update the studio addons
4. Run `date -R > /var/cache/update_info/timestamp.chk` to mark this update as the latest
## Wake on LAN
Wake on LAN use the hardware information provided by the clients to wake up all that are currently offline. If this is used in combination with a system update, the client computers will turn off after the system update has completed. (Unless any users are logged into the system when the update finishes).
To wake up client computers if they are offline, run the `wol_shared_comps.py` in the root home folder of the Build server.
It will use the hardware information provided by the clients to wake up all that are currently offline.
If this is used in combination with a system update, the client computers will turn off after the system update has completed. (Unless any users are logged into the system when the update finishes).
1. `ssh user@build-server-addr` connect to your build server via ssh
2. Use `su` to Login as root or login as root directly
3. `cd` to change directory to the root home folder
4. `mkdir comps` To create a folder to store parsed client hardware info if none exists
5. `parse_output.py /var/studio_scripts/hw_data/* comps/` to parse client hardware info
6. Run `./wol_shared_comps.py comps/*` to wake any computers that are asleep

View File

@ -1,6 +1,18 @@
# Overview: Workstation Server & Client
# Overview of Operating System
[Gentoo](https://www.gentoo.org/) is a source based distro, which means you download the source code for every package and compile it yourself. The advantage of Gentoo is that we can much more easily interact with the source code to make our own changes and if we choose share those changes with the upstream project. To learn about how to work with Gentoo see the [Gentoo Handbook](https://wiki.gentoo.org/wiki/Handbook:AMD64)
The Gentoo package manager allows a single computer to compile and serve pre-built packages to a network of computers, this can be useful in a studio environment. This server is called the "Gentoo Build Server" which provides software to the client systems.
Here is an overview of how we deploy Gentoo at the Blender Studio:
![Gentoo Overview](/media/td-guide/server/gentoo_server_overview.png)
|Name|Description|
|---|---|
|**IPXE File Host**| This is simple a http server that hosts boot images. [IPXE](https://ipxe.org/) is a network based boot loader that can boot over the network|
|**Gentoo Build Server**|Server that serves pre-built packages to a network of computers. It also keeps track of client hardware info and client update error logs|
|**Client System**|Workstations for users within the studio that receive software & updates from Build Server|
Note that the clients do not strictly depend on the Build Server. The build server can be unavailable and all clients will still be able to install packages and work as normal. They will simply not receive any automatic updates or download any precompiled packages if the build server is down.