Clustering colorOS nodes provides interoperability between the clustered nodes. For example, one colorOS node can send a command to another colorOS node in the same cluster, and display the results. The only requirements are that both clustered nodes utilize the same MQTT Message Broker and are connected to the same network.
Enabling Clustering
- Define the following macros in coloros.h and rebuild the kernel:
#define CLUSTER
#define DRIVE "SD:" - Configure Messaging
- Set the system property cluster-node, e.g. to set the cluster node acme when logged into a System account, or if logins not enabled:
OK, set cluster-node acme - Reboot after setting the cluster-node property, e.g. when logged into a System account, or if logins not enabled:
OK, reboot
Do you want to reboot this computer? yes
*** REBOOT *** - Verify that clustering is enabled by using the show cluster command (may take 1 to 2 minutes after a reboot to see nodes):
OK, show cluster
Cluster Status @ Nov 1 18:58:20.9
Node Name IPV4 Address Services Provided Age
acme 10.0.1.88 cluster,echo,telnet,web 4
aramis 10.0.1.71 cluster,echo,telnet,web 4
athos 10.0.1.86 cluster,echo,telnet,web 4
porthos 10.0.1.87 cluster,echo,telnet,web 4