Managing Nodes
The following commands require an active KSDK session
For KSDK login instructions see the Authentication page.
Consulting Nodes¶
Listing Nodes¶
All the available Nodes can be consulted with the kelvin node list command:
kelvin node list
Success
[kelvin.sdk][2020-07-28 15:58:40][R] Retrieving nodes..
[kelvin.sdk][2020-07-28 11:28:30][I]
*************************** Nodes ***************************
+--------------------+--------------------+--------------------------+---------------------------------------------+
| Name | Title | Node Status | Last seen |
|--------------------+--------------------+--------------------------+---------------------------------------------|
| squad1-node1 | squad1-node1 | Connected | 2020-07-28 10:23:29 +0000 (a minute ago) |
| squad3-node1 | squad3-node1 | Connected | 2020-07-28 10:24:48 +0000 (13 seconds ago) |
| squad4-node1 | squad4-node1 | Connected | 2020-07-28 10:24:43 +0000 (18 seconds ago) |
+--------------------+--------------------+--------------------------+---------------------------------------------+
Alternatively, you can manage Nodes on <instance>.kelvininc.com directly through the Control Center web interface.
Searching Nodes¶
In addition to listing all Nodes, you can search for specific Nodes with the kelvin node search command:
# kelvin node search <query>
kelvin node search "node"
Success
[kelvin.sdk][2020-07-28 15:58:39][I] Searching nodes that match "node"
[kelvin.sdk][2020-07-28 15:58:40][R]
*************************** Nodes ***************************
+------------------+------------------+--------------------------+---------------------------------------------+
| Name | Title | Node Status | Last seen |
|------------------+------------------+--------------------------+---------------------------------------------|
| squad1-node1 | squad1-node1 | Connected | 2020-07-28 10:27:38 +0000 (15 seconds ago) |
| squad3-node1 | squad3-node1 | Connected | 2020-07-28 10:26:08 +0000 (a minute ago) |
| squad4-node1 | squad4-node1 | Connected | 2020-07-28 10:27:48 +0000 (5 seconds ago) |
+------------------+------------------+--------------------------+---------------------------------------------+
Details of a Node¶
Detailed information of a Node can be obtained through the kelvin node show command.
# kelvin node show <node name>
kelvin node show x-wing
Success
[kelvin.sdk][2020-07-28 11:29:42][I] Retrieving node details for "x-wing "
[kelvin.sdk][2020-07-28 11:29:42][I] Node metrics available. Retrieving metrics for "x-wing"
[kelvin.sdk][2020-07-28 11:29:44][I]
*************************** Node Info ***************************
cluster_name: x-wing
created: 2020-12-21 21:46:54.108137+00:00
kelvin_info:
edge_app_version: 2.0.0-rc.592
manifests_scrape_enabled: True
manifests_scrape_interval: 86400
metadata: None
metrics_enabled: True
metrics_scrape_interval: 30
name: x-wing
network_info:
node_name: x-wing
status_scrape_enabled: True
status_scrape_interval: 30
system_info:
architecture: amd64
hostname: x-wing
name: Ubuntu 20.04.1 LTS
os: linux
release: 5.4.0-58-generic
vendor: ubuntu
version: 20.04
title: x-wing
updated: 2020-12-21 21:50:22.238631+00:00
Node Metrics
Allocation:
CPU capacity: 2.0
CPU usage: 0.21
Memory capacity: 4.1 GB
Memory usage: 283.1 MB
CPU utilization:
Timestamp (date): 2020-08-31 18:29:51 (now)
Value: 3.0333333333336063
Disk data:
Total capacity: 31.2 GB
Used capacity: 8.7 GB
Memory usage:
Timestamp (date): 2020-08-31 18:29:51 (now)
Value: 2.2 GB
Network data:
Transmitted (Tx): 6.8 GB
Received (Rx): 6.0 GB
*************************** Workloads ***************************
+----------------------------------+----------------------------+-------------+-------------------+---------------+-------------------+---------------------------------------------+
| Name | Title | Node Name | App Name | App Version | Workload Status | Last Seen |
|----------------------------------+----------------------------+-------------+-------------------+---------------+-------------------+---------------------------------------------|
| plunger-simulato-1fa62596e637945 | plunger-simulator Workload | x-wing | plunger-simulator | 0.0.2 | Running | 2020-07-28 10:29:19 +0000 (25 seconds ago) |
| qamm-sdk-app-00-0e5a171f2de404f0 | qamm-sdk-app-00 Workload | x-wing | qamm-sdk-app-00 | 0.0.3 | Stopped | 2020-07-28 10:29:19 +0000 (25 seconds ago) |
| qamm-sdk-app-00-eab6d0e09ce6bb8f | qamm-sdk-app-00 Workload | x-wing | qamm-sdk-app-00 | 0.0.1 | Stopped | 2020-07-28 10:29:19 +0000 (25 seconds ago) |
| qamm-workload-03 | QAMM-WORKLOAD-03 | x-wing | qamm-sdk-app-00 | 0.0.3 | Stopped | 2020-07-28 10:29:19 +0000 (25 seconds ago) |
| workload-kskd-qamm-02 | qamm-sdk-app-00 Workload | x-wing | qamm-sdk-app-00 | 0.0.1 | Stopped | 2020-07-28 10:29:19 +0000 (25 seconds ago) |
| workload-kskd-qamm-last | qamm-sdk-app-00 Workload | x-wing | qamm-sdk-app-00 | 0.0.4 | Running | 2020-07-28 10:29:19 +0000 (25 seconds ago) |
+----------------------------------+----------------------------+-------------+-------------------+---------------+-------------------+---------------------------------------------+
Managing Nodes¶
Setting up a Node¶
Much like Control Center, the KSDK provides a simple way for users to get the provision script required to set up a Node.
The kelvin node provision-script command takes no arguments and its output provides detailed instructions:
kelvin node provision-script
Success
[kelvin.sdk][2020-08-13 17:57:17][I] Retrieving the provision script..
[kelvin.sdk][2020-08-13 17:57:18][I]
# 1 - Prepare your Node Host
> Install Ubuntu 18.04 on your host that has at least 2GB of RAM, 10GB of Disk and has a x86-64 Processor.
# 2 - Install all necessary dependencies
> To install and run Kelvin Orchestration System, execute the following command on your host and follow the
instructions prompted:
KELVIN_TOKEN="your_token_will_be_automatically_placed_here=" bash <(curl -f https://demo.kelvininc.com/provision)
Deleting a Node¶
A Node can be deleted from the platform using the kelvin node delete command.
# kelvin node delete <node_name>
kelvin node delete x-wing
Success
[kelvin.sdk][2021-01-14 16:30:41][W]
This operation will remove the Node from the platform.
The Node's local data will be lost.
Are you sure? [y/N] y
[kelvin.sdk][2021-01-14 16:30:43][R] Node "x-wing" successfully deleted from the platform