lbcli Create Server
Add a new server to an existing cluster (when you need to replace the existing server). Note: You will need to create a new server first. In order to create a new server, edit the Ansible inventories files (hosts, /host_var/new_server.yaml) and add the new server. Then run the ansible-playbook with the same parameters as before and add the following parameter: --limit:<new_server name>
Example:
ansible-playbook -i /tmp/inventory/cluster_example/hosts playbooks/deploy-lightos.yml \
-e new_etcd_member=true \
-e extend_etcd_cluster=true \
--limit <new_server> -vv
In order to find the new server uuid run the following on the new server: cat /etc/node-manager/node-manager.yaml |grep serverUUID
Example Command
lbcli create server --uuid=ad69f2c6-4b9a-5a72-8ff6-daf949ef61b4 --endpoints=https://10.19.117.3:2380
A -J flag after lbcli indicates that the JWT is not stored in the lbcli configuration file.
Example Output
x
lbcli create server --uuid=ad69f2c6-4b9a-5a72-8ff6-daf949ef61b4 --endpoints=https://10.19.117.3:2380
lbcli list server
NAME UUID State RiskOfServiceLoss State LightbitsVersion
server01 8fb42404-2b8c-5639-a528-8fc41a6afb3d Enabled InRiskOfServiceLoss 2.0.2
ad69f2c6-4b9a-5a72-8ff6-daf949ef61b4 Creating InRiskOfServiceLoss
server00 850b2d56-4025-5268-a373-610ff45980c8 Enabled InRiskOfServiceLoss 2.0.2
server02 3e625b5e-322a-5df4-8fc2-326e6a640d03 Enabled InRiskOfServiceLoss 2.0.2
Note: This will take ~ 3-4 minutes to become Enabled.
Was this page helpful?