Skip to main content

XPanel cluster management

KlustronAbout 10 min

XPanel cluster management

01 System Overview

XPanel is a GUI for Klustron users to manage Klustron database clusters and monitor cluster node status, including all cluster management functions and functional interfaces for cluster status monitoring.

02 Introduction to cluster management functions

2.1 Cluster Management

The cluster management module is one of the key functions of the system, mainly including cluster list information, cluster display and abnormal cluster list.

The cluster list information page mainly operates on the overall cluster, including: create, delete cluster, add and delete shard, add and delete computing/storage nodes, full physical backup and recovery (rollback), logical backup and recovery, online DDL and repartition, cluster Functions such as expansion and contraction, active/standby switching of storage clusters, redoing standby machines, setting and obtaining instance variables, and node monitoring;

The cluster display page mainly displays the deployment diagram information of a single cluster, which is aimed at the operation of a single cluster; the list of abnormal clusters displays abnormal cluster information.

2.1.1 Cluster list

2.1.1.1 Cluster List Information

The cluster list information page can add new clusters, full backup, rollback clusters, cluster expansion, delete clusters, add/delete shards, add/delete nodes, master-standby switchover, redo standby machines, set delay alarm time, set and get instances Variables, node monitoring and other functional modules.

Add new cluster

To add a cluster, click the Add button, fill in the information and click OK to add a cluster, as shown in Figure 1 and Figure 2. The computer to be selected for the new cluster is optional, and it is divided into storage-type computers and computing-type computers. Note: If the entire cluster_mgr has not added any type of computer, it is impossible to add a new cluster operation.

imgfigure 1

imgfigure 2

After the cluster is successfully added, as shown in Figure 3. Among them, the selection of computer, high availability mode, number of shards, number of copies, cluster name, and buffer pool size are required items, and the rest are optional items. Click the More button to fill in the optional information, as shown in Figure 4. 5.

imgimage 3

imgFigure 4

imgFigure 5

  1. Select the computer, the computer here is the computer that has been successfully added from the computer management, if you find that the selected computer is empty or there is no computer you want to choose, you can first add the computer in the computer management and then add a new cluster.
  2. High availability mode, if cluster_mgr is community edition: mgr, if cluster_mgr is enterprise edition: rbr.
  3. The number of shards is 1 by default and can be modified.
  4. The number of replicas, the default is 3.
  5. Business name, user input, required.

full backup

Full backup is to back up the existing cluster through some kind of backup storage target. After backup, you can find the relevant data backup files in the cluster backup list.

1、The prerequisite for full backup is that there must be a backup storage target in the system. If the backup storage target record is empty, backup is not allowed. Specifically, the new backup storage target will be configured during cluster_mgr and will be automatically reported after cluster_mgr is installed. Backup storage target, go to backup storage target management to see related records. The specific steps for initiating a full backup are shown in Figure 6.

imgFigure 6

2、After the backup storage target has been added, click the button to initiate a full backup, and the backup cluster working will be displayed. As shown in Figure 7.

imgFigure 7

3、Go to the full backup record to check whether the backup task just now is successful, done means success, and failed means failure. As shown in Figure 8. You can also go to the cluster backup list to view the data information that was just backed up at 2022-09-29 14:26:34. As shown in Figure 9.

imgFigure 8

imgFigure 9

Rollback cluster

Roll back the cluster, and restore a new cluster in the selected cluster. The new cluster is the same as the original cluster, and click Restore Cluster.

The rollback cluster is the data that the new cluster rolls back to a certain backup time point for the original backup cluster. Note):

  • Rollback clusters need to have more than two clusters to initiate a rollback operation.
  • After the rollback, the data of the new cluster will be overwritten by the backup data of the original cluster, and there will be a prompt on the page, please operate with caution.

1、Perform a cluster rollback operation on the cluster that already has data backup. If the cluster has not been backed up before the current time, there is no way to perform the cluster rollback operation. Will fail to rollback. As shown in Figure 10.

imgFigure 10

2、When the data backup file already exists, click the Rollback button, and a page will pop up, select the original cluster name, rollback time, and confirm the save to restore the cluster. Figure 11 shows. Note): The original cluster name and rollback time are required. Rollback time: The rollback time cannot be earlier than the earliest backup time and cannot be later than the current time.

imgFigure 11

3、After filling in the information, click OK to restore a new cluster, as shown in Figure 12 and Figure 13.

imgFigure 12

imgFigure 13

Cluster expansion

Cluster expansion is to migrate the table to a new shard when the load of a certain shard is too large to reduce the load and achieve the purpose of capacity expansion.

The premise of cluster expansion is that there are at least two shards in a cluster, and there are tables in the computing nodes of the cluster before the cluster expansion operation can be performed.

Cluster expansion includes manual table selection expansion and automatic table selection expansion.

Manually select the table to expand the specific operation, as shown in the following figure. 14~18.

imgFigure 14

imgFigure 15

imgFigure 16

imgFigure 17

imgFigure 18

Automatic table selection and expansion, specific operations, as shown in Figure 19~22 below.

imgFigure 19

imgFigure 20

imgFigure 21

imgFigure 22

delete cluster

To delete a cluster, click Settings on the cluster list information page to enter the single cluster management page to perform cluster deletion operations. As shown in Figure 23, Figure 24, Figure 25, and Figure 26, after the cluster is successfully deleted, it is shown in Figure 27.

Note): After deleting the cluster operation, the data will be permanently lost, please operate with caution.

imgFigure 23

imgFigure 24

imgFigure 25

imgFigure 26

imgFigure 27

add shard

The following is to add a shard to the vito cluster, as shown in Figure 28~32 below. After the shard is added successfully, as shown in Figure 35-4 and 35-5. In the shard list, you can view the ip, port, active and standby nodes, node status and other information under the shard.

imgFigure 28

imgFigure 29

imgFigure 30

imgFigure 31

imgFigure 32

delete shard

To delete a shard, cluster list —> cluster list information —> select the setting on the right side of the vito cluster —> shard list —> select the delete button of shard_2, and click the delete operation to delete the shard. As shown in Figure 33~35.

imgFigure 33

imgFigure 34

imgFigure 35

add node

Adding nodes includes adding computing nodes and adding storage nodes.

1、Add computing nodes, as shown in Figure 36~40.

imgFigure 36

imgFigure 37

imgFigure 38

imgFigure 39

imgFigure 40

2、Add storage nodes, as shown in Figure 41~45.

imgFigure 41

imgFigure 42

imgFigure 43

imgFigure 44

imgFigure 45

delete node

Deleting nodes includes deleting computing nodes and deleting storage nodes.

1、Delete the storage node, as shown in Figure 46~49.

imgFigure 46

imgFigure 47

imgFigure 48

imgFigure 49

2、Delete the computing node, as shown in Figure 50~53.

imgFigure 50

imgFigure 51

imgFigure 52

imgFigure 53

Active/standby switchover

Active-standby switchover is mainly for the nodes under the cluster shard to perform active-standby switchover. The active-standby switchover is divided into manual active-standby switchover and automatic active-standby switchover. The active/standby switchover of XPanel is manually triggered. The specific operation is shown in Figure 54~57. Note): The backup node is not required, if not selected, the background will automatically switch randomly for the selected backup node.

imgFigure 54

imgFigure 55

imgFigure 56

imgFigure 57

Redo the standby node

Redo the standby node. When a certain standby node is abnormal, you need to redo the standby node. The redo standby machine field includes parameters such as selecting the shard name, the standby machine node to be redone, whether to pull data from the master node, master-standby delay, whether to back up, backup storage target, speed limit, etc.

Note):

  1. Standby nodes that need to be redone, this option is required, multiple choices are allowed, and multiple standby nodes can be redone at one time;
  2. If you want to pull data from the master node, if you select Yes, you don’t need to enter the master-standby delay time; otherwise, the default master-standby delay time is 30s, which is required and can be modified;
  3. If whether to backup, select Yes, the backup storage destination cannot be empty, and the default value of whether to backup is No;
  4. The default speed limit is 10KB/s, which can be modified.

The specific operation is shown in Figure 58~60.

imgFigure 58

imgFigure 59

imgFigure 60

Set the delay alarm time

The default alarm delay time is 100s. If it is not set, if it exceeds 100 by default, an abnormal alarm will be displayed in the cluster list. If the alarm time is set, it will be based on the latest alarm time, and if the set value is exceeded, a list exception alarm will appear.

The specific setting operation is shown in Figure 61 and Figure 62. After the setting is successful, when selecting the corresponding shard, the maximum delay time will be the latest setting time.

imgFigure 61

imgFigure 62

Setting and getting instance variables

Set the instance variable, select the storage node under shard to set, the variable types are int and string, just input the variable name and variable value to save. As shown in Figures 63 and 64. After the setting is successful, as shown in Figure 63-64.

imgFigure 63

imgFigure 64

get instance variable

To obtain an instance variable, select a node in the shard under the cluster, and enter the variable name to obtain the value of the instance variable. As shown in Figure 65. imgFigure 65

node monitoring

Node monitoring only needs to monitor the storage nodes and computing nodes, and display the basic connection information of the nodes. If you log in for the first time, you need to enter the account name and password, both of which are admin.

Node monitoring for storage nodes. As shown in Figures 66 and 67.

imgFigure 66

imgFigure 67

Node monitoring for storage nodes. As shown in Figures 68 and 69.

imgFigure 68

imgFigure 69

2.1.1.2 Cluster display

The cluster display mainly shows the deployment diagram of a single cluster. It shows the shards and computing nodes contained in a single cluster. The storage nodes are hidden by default. Click the + sign to expand the view, as shown in Figure 70 and Figure 71.

imgFigure 70

img

1、You can click the redio button in front of different clusters to switch between different clusters, as shown in Figure 72.

imgFigure 72

2、Click the icon of each node in the cluster to monitor the node.

Storage node monitoring. As shown in Figure 73 and Figure 74.

imgFigure 73

imgFigure 74

Compute node monitoring, as shown in Figure 75 and Figure 76. imgFigure 75

imgFigure 76

2.1.2 Cluster backup list

The cluster backup list mainly displays the list information of the backup cluster. When it was backed up, which cluster was backed up, and other related lists. It is mainly used to facilitate viewing of backup data. For example, I have successfully backed up the test cluster in the cluster list (as shown in Figure 77), then I can enter the cluster backup list to see the cluster information just backed up (as shown in Figure 78).

imgFigure 77

imgFigure 78

2.1.3 Backup Storage Target Management

The backup storage target management is to prepare for the backup cluster, because when backing up the cluster, there must be a backup storage target to back up successfully. Currently there is only one target type, which is HDFS. To add a backup storage target, click the Add button on the page and enter the target name; select the target type, currently there is only one type, HDFS, and it will be added later; enter the IP address and port number, and click OK to add a backup storage target. After clicking OK, the interface returns synchronously. As shown in Figure 79 and Figure 80

imgFigure 79

imgFigure 80

Edit backup storage destination

The editing operation is to update the existing storage target. The name cannot be edited during editing, and others can be edited. As shown in Figure 81 and Figure 82.

imgFigure 81

imgFigure 82

delete backup storage target

Search for the corresponding data by entering the target name, and click the delete button on the right to delete the storage target. As shown in Figure 83 and Figure 84 Note): The delete operation will be permanently deleted, please operate with caution.

imgFigure 83

imgFigure 84

2.2 Operation records

The operation record is mainly used to check the execution status of calling the background interface. If the status of going is in progress, the execution is not completed; if the status is done, it means that the execution is completed and the execution is successful; if the status is failed, it means that the execution failed. As shown in Figure 85.

Click the blue task ID button to view the details of the newly added cluster, as shown in Figure 86.

imgFigure 85

imgFigure 86

2.3 Cluster cut-off setting

According to business needs, it may be necessary to set the cut-free setting. The specific operation in XPanel is shown in Figure 87, Figure 88, and 89. imgFigure 87 imgFigure 88 imgFigure 89

Delete the cut-free settings, as shown in Figure 90 and Figure 91.

imgFigure 90 imgFigure 91

2.4 cluster_mgr status

You can check which cluster_mgr master is, and then which cluster_mgr is connected, and how many cluster_mgr nodes there are. The details are shown in Figure 92. imgFigure 92

2.5 Metadata cluster management

In the metadata cluster management, the metadata node list can view the information of the current metadata node. As shown in Figure 93. imgFigure 93

END