How do I manually install clusterctrl?

~ 0 min
2021-04-02

If you're using one of the provided ClusterCTRL images the cluserctrl tool will already be installed but those using the ClusterCTRL Stack or only want to manage power for a ClusterHAT for example may want to install it manually.

To install the tool manually you can normally run through the following steps as the root user (you can usually switch to the root user by using "sudo -i").

TMPINSTALL=/tmp/clusterhat
apt install git libusb-1.0-0-dev python-usb python-libusb1 python-smbus # When using Python2 (for example Raspberry Pi OS)
apt install git libusb-1.0-0-dev python3-usb python3-libusb1 python3-smbus python-is-python3 # When using Python3 (for example Ubuntu 20.10)
git clone https://github.com/burtyb/clusterhat-image.git $TMPINSTALL
mkdir /usr/share/clusterctrl/
cp $TMPINSTALL/files/usr/sbin/cluster* /usr/sbin/
cp $TMPINSTALL/files/usr/share/clusterctrl/default-clusterctrl /etc/default/clusterctrl
cp $TMPINSTALL/files/etc/udev/rules.d/90-clusterctrl.rules /etc/udev/rules.d/
cp $TMPINSTALL/files/usr/lib/systemd/system/clusterctrl-init.service /usr/lib/systemd/system/
cp -r $TMPINSTALL/files/usr/share/clusterctrl/python/ /usr/share/clusterctrl/
echo 'TYPE=c' >> /etc/default/clusterctrl
udevadm control --reload-rules
systemctl enable clusterctrl-init
raspi-config nonint do_i2c 0 # Not needed on Ubuntu 20.10
rm -rf $TMPINSTALL

If you see an error on any of these stages please create a new thread on the support forum or open a support ticket with details of the distribution you're using and the issue you're having.

Now disconnect and reconnect the USB cable (if using a ClusterCTRL device) and then check it's found the device.

clusterctrl status

This should then find and show the status of either a ClusterHAT and/or any ClusterCTRL devices you have connected.

Average rating 5 (1 Vote)

You cannot comment on this entry