Rate This Document
Findability
Accuracy
Completeness
Readability

Collecting Remote Cluster Information

Use the Kunpeng Health Inspector to collect hardware data of a remote server, download the report, and compare the data.

  1. Extract the package and go to the tool directory.
    1
    2
    tar -zxvf /home/devkit-kspect-xx.xx.xx-Linux-aarch64.tar.gz
    cd /home/devkit-kspect-xx.xx.xx-Linux-aarch64
    
  2. Edit the configuration file of the server whose data is to be collected.
    1
    vi server.ini
    

    Press i to enter the insert mode.

    [101]
    ip = 192.168.x.1
    port = 22
    username = root
    login_method = private_key
    password =
    private_key_path = /root/.ssh/id_rsa
    private_key_password =
    bmc_ip = 192.168.x.x
    bmc_username = Administrator
    bmc_password =
    
    [102]
    ip = 192.168.x.2
    port = 22
    username = root
    login_method = private_key
    password =
    private_key_path = /root/.ssh/id_rsa
    private_key_password =
    bmc_ip = 192.168.x.x
    bmc_username = Administrator
    bmc_password =

    Press Esc, type :wq!, and press Enter to save the file and exit.

  3. Encrypt the file.
    1
    ./kspect server-config -i server.ini
    

    Enter the encryption password. After the encryption is complete, the server-config-xxxxxxxx-xxxxx.ini file is generated in the current directory.

  4. Collect cluster server information.
    1
    ./kspect cluster -i server-config-xxxxxxxx-xxxxx.ini
    

    The tool collects information about the servers in the configuration file one by one, displays whether the collection is successful, and reports the collection details and report storage directory.

    Command output:

    1
    2
    3
    4
    5
    6
    7
    8
    9
    Succeeded in reading the configuration file: server-config-xxxxxxxx-xxxxx.ini.
    Enter the decryption password:
    Data of the following servers starts to be collected: 192.168.x.1:22(101); 192.168.x.2:22(102);
    
    Data of 192.168.x.1:22(109) is successfully collected.
    The archive file /home/devkit-kspect-x.x.x-Linux-aarch64/output/kspect-report-20251119-105559-192.168.x.1-22.tar.gz has been generated.
    Data of 192.168.x.2:22(108) is successfully collected.
    The archive file /home/devkit-kspect-x.x.x-Linux-aarch64/output/kspect-report-20251119-105135-192.168.x.2-22.tar.gz has been generated.
    Collection completed: 2/2 succeeded.
    
  5. View the collection result.
    1
    ./kspect report -h
    

    The collected package is automatically extracted. The extracted file contains the full information file (HTML/JSON/CSV) and dmesg log file. You can view the HTML file using a browser.

    Command output:

    1
    2
    3
    4
    5
    6
    7
    8
    ...
    ...
        -r REPORT, --report REPORT
        Indicates the report to be displayed. (You can also enter the report path. Tool collection reports and reported generated using diff/diff_x86 are supported.
        1: /home/devkit-kspect-x.x.x-Linux-aarch64/output/kspect-report-20251119-105559/kspect-json-20251119-105559.json <2025-11-19 10:55:59>
        2: /home/devkit-kspect-x.x.x-Linux-aarch64/output/kspect-report-20251119-105135/kspect-json-20251119-105135.json <2025-11-19 10:54:01>
    ...
    ...
    
  6. View the first collection report.
    1
    ./kspect report -r 1
    
    Figure 1 Report content
  7. Compare the two reports.
    In the report, the data items that exceed the threshold and different configuration items are marked in red to facilitate subsequent operations such as unified server configuration.
    1
    ./kspect report -d 1,2
    
    Figure 2 Memory information