Cluster preparations

The Raspberry Pi4 are now up and running. Now there is some customizing needed before we can start settting up the kubernetes cluster. First a member of a cluster a called node. Each kubernetes cluster has a master node which is orchestrating the whole installation. So every node of your cluster should get a unique names like

boinc-master
boinc-node01
boinc-node02
boinc-node03

You can simply change your hostname with the handy config tool raspi-config. Navigate to System Options / Hostname to change the name of your raspberry pi

sudo raspi-config

Since we are running headless there is no need to reserve shared memory for the gpu. Navigate to performance options / GPU Memory and set the amount to 16. This will keep more RAM free for crunching. You will need at least 16 MB for your GPU, otherwise the Pi won’t boot.

I also suggest to switch your ethernet connections to a static address since your IPs might be changed from your DHCP Service. You can set a fixed IP in file /etc/dhcpcd.conf

sudo nano /etc/dhcpcd.conf

Scroll down a little bit and set a static ip_adress, static routers and static domain_name_servers as needed (uncomment the lines you are changing):

# Example static IP configuration:
#interface eth0
static ip_address=192.168.1.21/24
#static ip6_address=fd51:42f8:caae:d92e::ff/64
static routers=192.168.1.11
static domain_name_servers=192.168.1.11

In my network I do not need WiFi connections and also no bluetooth connections. I would also like to save Raspberry ressources as much as possible. To disable these services on bootup, just add the following lines to the file /boot/config.txt

# Disable Bluetooth and WiFi
dtoverlay=disable-bt
dtoverlay=disable-wifi

After reboot, the Raspberry will start without bluetooth and wifi support. You might want to remove also the software packages for these services to save some MB on your SDcard:

sudo systemctl disable hciuart.service
sudo systemctl disable bluealsa.service
sudo systemctl disable bluetooth.service
sudo apt-get purge bluez -y
sudo apt-get autoremove -y

To prevent as much I/O as possible for the SDcard in order to extend its lifetime I decided to switch off swap space on the Raspberry Pi4

sudo dphys-swapfile swapoff && \
sudo dphys-swapfile uninstall && \
sudo systemctl disable dphys-swapfile

After reboot you can check with free -h that your SWAP is set to 0.

jan
jan

Hey, I am Jan. I am an IT Project and Technical Application Manager specialized on Output Management und CCM Solutions.

I have always been that hands on guy. Since it has not been possible in my business to get in touch with kubernetes I decided to do something on my own. Crunching with BOINC looks reasonable for me here.

I first registred for SETI@Home on 07. July in 1999. Happy crunching!

Artikel: 25

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert

Diese Website verwendet Akismet, um Spam zu reduzieren. Erfahre, wie deine Kommentardaten verarbeitet werden.