Skip to content

Install Control Plane

Prerequisites

Before starting the deployment, make sure that the following prerequisites as described in the hardware prerequisites and software prerequisites section are met.

Control Plane Installation

The first step when installing simplyblock on plain Linux (Docker) is to install the control plane. The control plane manages one or more storage clusters. If an existing control plane is available and the new cluster should be added to it, this section can be skipped.

In this case, the following section can be skipped to Storage Plane Installation.

Firewall Configuration (CP)

Simplyblock requires a number of TCP and UDP ports to be opened from certain networks.

The following is a list of all ports (TCP and UDP) required to operate as a management node. Attention is required, as this list is for management nodes only. Storage nodes have a different port configuration.

Service Direction Hosts Network Port(s) Protocol(s)
ICMP egress control Control - ICMP
storage-node-api egress storage Control 5000 TCP
NVMf (client-target) egress client Storage 4420-4499 TCP, UDP (1)
FoundationDB ingress, egress control Control 4500 TCP
control-plane-API ingress control Control 80 TCP
storage-node-RPC ingress, egress storage, control Control 8080-9044 TCP
Monitoring Stack (2) ingress, egress control Control 12202, 13301, 13302, 9200, 9090 TCP

1 The NVMf port range carries both transports. NVMe-oF/TCP uses it over TCP, NVMe-oF/RDMA over UDP. Only the protocol of the transport(s) in use has to be opened.
2 The monitoring stack is optional. Its ports only have to be opened where it is deployed.

With the previously defined subnets, the following snippet configures the iptables automatically.

Network Configuration
#!/bin/bash

# ICMP ingress
iptables -A INPUT -p icmp -j ACCEPT

# storage-node-api — TCP 5000, ingress + egress
iptables -A INPUT  -p tcp --dport 5000 -j ACCEPT
iptables -A OUTPUT -p tcp --dport 5000 -j ACCEPT

# NVMf — TCP 4420-4499, ingress + egress
iptables -A INPUT  -p tcp --dport 4420:4499 -j ACCEPT
iptables -A OUTPUT -p tcp --dport 4420:4499 -j ACCEPT

# FoundationDB — TCP 4500, ingress
iptables -A INPUT -p tcp --dport 4500 -j ACCEPT

# Control plane API — TCP 80, egress
iptables -A OUTPUT -p tcp --dport 80 -j ACCEPT

# Control plane RPC — TCP 8080-9044, ingress + egress
iptables -A INPUT  -p tcp --dport 8080:9044 -j ACCEPT
iptables -A OUTPUT -p tcp --dport 8080:9044 -j ACCEPT

# Monitoring Stack — optional
# iptables -A INPUT  -p tcp -m multiport --dports 12202,13301,13302,9200,9090 -j ACCEPT
# iptables -A OUTPUT -p tcp -m multiport --dports 12202,13301,13302,9200,9090 -j ACCEPT

Management Node Installation

Now that the network is configured, the management node software can be installed.

Simplyblock provides a command line interface called sbctl. It's built in Python and requires Python 3 and Pip (the Python package manager) installed on the machine. This can be achieved with yum.

Install Python and Pip
sudo yum -y install python3-pip

Afterward, the sbctl command line interface can be installed. Upgrading the CLI later on uses the same command.

Install Simplyblock CLI
sudo pip install sbctl --upgrade

Recommendation

Simplyblock recommends to only upgrade sbctl if a system upgrade is executed to prevent potential incompatibilities between the running simplyblock cluster and the version of sbctl.

At this point, a quick check with the simplyblock provided system check can reveal potential issues quickly.

Automatically check the configuration
curl -s -L https://install.simplyblock.io/scripts/prerequisites-cp.sh | bash

If the check succeeds, it's time to set up the primary management node:

Deploy the primary management node
sbctl cluster create --ifname=<IF_NAME>

Important cluster deployment options can be found in the Cluster Deployment Options.

The output should look something like this:

Example output of control plane deployment
[root@demo ~]# sbctl cluster create --ifname=eth0 --ha-type=ha
2025-02-26 12:37:06,097: INFO: Installing dependencies...
2025-02-26 12:37:13,338: INFO: Installing dependencies > Done
2025-02-26 12:37:13,358: INFO: Node IP: 192.168.10.1
2025-02-26 12:37:13,510: INFO: Configuring docker swarm...
2025-02-26 12:37:14,199: INFO: Configuring docker swarm > Done
2025-02-26 12:37:14,200: INFO: Adding new cluster object
File moved to /usr/local/lib/python3.9/site-packages/simplyblock_core/scripts/alerting/alert_resources.yaml successfully.
2025-02-26 12:37:14,269: INFO: Deploying swarm stack ...
2025-02-26 12:38:52,601: INFO: Deploying swarm stack > Done
2025-02-26 12:38:52,604: INFO: deploying swarm stack succeeded
2025-02-26 12:38:52,605: INFO: Configuring DB...
2025-02-26 12:39:06,003: INFO: Configuring DB > Done
2025-02-26 12:39:06,106: INFO: Settings updated for existing indices.
2025-02-26 12:39:06,147: INFO: Template created for future indices.
2025-02-26 12:39:06,505: INFO: {"cluster_id": "7bef076c-82b7-46a5-9f30-8c938b30e655", "event": "OBJ_CREATED", "object_name": "Cluster", "message": "Cluster created 7bef076c-82b7-46a5-9f30-8c938b30e655", "caused_by": "cli"}
2025-02-26 12:39:06,529: INFO: {"cluster_id": "7bef076c-82b7-46a5-9f30-8c938b30e655", "event": "OBJ_CREATED", "object_name": "MgmtNode", "message": "Management node added vm11", "caused_by": "cli"}
2025-02-26 12:39:06,533: INFO: Done
2025-02-26 12:39:06,535: INFO: New Cluster has been created
2025-02-26 12:39:06,535: INFO: 7bef076c-82b7-46a5-9f30-8c938b30e655
7bef076c-82b7-46a5-9f30-8c938b30e655

If the deployment was successful, the last line returns the cluster id. This should be noted down. It's required in further steps of the installation.

Additionally to the cluster id, the cluster secret is required in many further steps. The following command can be used to retrieve it.

Get the cluster secret
sbctl cluster get-secret <CLUSTER_ID>
Example output get cluster secret
[root@demo ~]# sbctl cluster get-secret 7bef076c-82b7-46a5-9f30-8c938b30e655
e8SQ1ElMm8Y9XIwyn8O0

Secondary Management Nodes

A production cluster requires at least three management nodes in the control plane. Hence, additional management nodes need to be added.

On the secondary nodes, the network requires the same configuration as on the primary. Executing the commands under Firewall Configuration (CP) will get the node prepared.

Highly Available Control Plane

When simplyblock is deployed with an HA control plane, an external load balancer is required to distribute requests of the storage plane to active control plane nodes. This is required to ensure that the control plane is not a single point of failure when one or more management nodes are down.

Afterward, Python, Pip, and sbctl need to be installed.

Deployment preparation
sudo yum -y install python3-pip
pip install sbctl --upgrade

Finally, the management node software is deployed and joins the control plane cluster.

Secondary management node deployment
sbctl mgmt add <CP_PRIMARY_IP> <CLUSTER_ID> <CLUSTER_SECRET>

Running against the primary management node in the control plane should create an output similar to the following example:

Example output joining a control plane cluster
[demo@demo ~]# sbctl mgmt add 192.168.10.1 7bef076c-82b7-46a5-9f30-8c938b30e655 e8SQ1ElMm8Y9XIwyn8O0
2025-02-26 12:40:17,815: INFO: Cluster found, NQN:nqn.2023-02.io.simplyblock:7bef076c-82b7-46a5-9f30-8c938b30e655
2025-02-26 12:40:17,816: INFO: Installing dependencies...
2025-02-26 12:40:25,606: INFO: Installing dependencies > Done
2025-02-26 12:40:25,626: INFO: Node IP: 192.168.10.2
2025-02-26 12:40:26,802: INFO: Joining docker swarm...
2025-02-26 12:40:27,719: INFO: Joining docker swarm > Done
2025-02-26 12:40:32,726: INFO: Adding management node object
2025-02-26 12:40:32,745: INFO: {"cluster_id": "7bef076c-82b7-46a5-9f30-8c938b30e655", "event": "OBJ_CREATED", "object_name": "MgmtNode", "message": "Management node added vm12", "caused_by": "cli"}
2025-02-26 12:40:32,752: INFO: Done
2025-02-26 12:40:32,755: INFO: Node joined the cluster
cdde125a-0bf3-4841-a6ef-a0b2f41b8245

From here, additional management nodes can be added to the control plane cluster. If the control plane cluster is ready, the storage plane can be installed.