Odroid C4 Cluster node

Hardkernel Odroid C4 cluster node

Hardkernel's Odroid C4 as a cluster node. As the picture shows, the board is the exact same size for the purposes of the PiCluster. It just screwed in to place on the board sled effortlessly.

A simple thing that's included in the purchase is the heatsink. Those that have read the other pages on the site will be aware that this tinkerer often laments the lack of thermodynamic engineering on various boards. In this case, however, not only is a factory heatsink provided but it is correctly oriented. Someone has done their homework.

Odroid C4 running apt upgrade minutes after unboxing

Software

Software was a breeze. It has Ubuntu 20.04 LTS factory supported. There are some odd quirks which were easy to fix. These are now noted over on the Server OS Settings page. Docker loaded exactly as documented on the Docker site and the Hello-World container just upped and ran!

The kernel used in the official Odroid minimal image is:
Linux hostd.localdomain 4.9.277-75 #1 SMP PREEMPT Sun Aug 8 23:26:32 UTC 2021 aarch64 aarch64 aarch64 GNU/Linux

whereas on the Raspberry Pi 4 and CM4 nodes:
Linux hostc.localdomain 5.4.0-1052-raspi #58-Ubuntu SMP PREEMPT Mon Feb 7 16:52:35 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux

 

Labelled as hostd.localdomain the new board immediately started taking container loads.

Software Issues

Docker Swarm has an issue with limiting container CPU utilization. It is not possible to restrict the CPU usage with this kernel, unlike the 5.4 kernel used on Pi4 machines.

NanoCPUs can not be set, as your kernel does not support CPU cfs period/quota or the cgroup is not mounted

This is no big deal, as all that needs to be done is the limit clause has to have the CPU limit removed and then the container runs fine. Obviously this becomes an issue when limits are essential. Work around by simply tagging the node appropriately and avoid scheduling on it for those workloads.

Update (2022.08.04)

A software update to Ubuntu 22.04 has resolved this issue. This node now runs the same OS version as all other nodes. The only thing left is to go back and remove the above workaround! Essentially this makes the Odroid-C4 a complete alternative for the Raspberry Pi 4GB nodes.

Reference: https://forum.odroid.com/viewtopic.php?f=52&t=44177

How to tell if your board supports docker CPU limits
Here the answer is no (Odroid C4):

root@hostd:~# ll /sys/fs/cgroup/cpu/cpu.*                                 
-rw-r--r-- 1 root root 0 Mar  3 14:21 /sys/fs/cgroup/cpu/cpu.rt_period_us 
-rw-r--r-- 1 root root 0 Mar  3 14:21 /sys/fs/cgroup/cpu/cpu.rt_runtime_us
-rw-r--r-- 1 root root 0 Mar  3 14:21 /sys/fs/cgroup/cpu/cpu.shares       

Here the answer is yes (Raspberry Pi CM4):

root@hostc:~# ll /sys/fs/cgroup/cpu/cpu.*                                 
-rw-r--r-- 1 root root 0 Mar  3 14:28 /sys/fs/cgroup/cpu/cpu.cfs_period_us
-rw-r--r-- 1 root root 0 Mar  3 10:46 /sys/fs/cgroup/cpu/cpu.cfs_quota_us 
-rw-r--r-- 1 root root 0 Mar  3 11:17 /sys/fs/cgroup/cpu/cpu.shares       
-r--r--r-- 1 root root 0 Mar  3 14:28 /sys/fs/cgroup/cpu/cpu.stat         

The SoC

The Odroid C4 uses an AmLogic S905X3 System on a Chip (SoC). At the time of writing this chip is getting on a bit now being some 3 years old. However, given the Raspberry Pi boards are currently unobtainable the O-C4 looked like a good alternative.

The board

Factory Support

Support is essentially provided via the official Wiki.