Installing the npu-smi Tool
The npu-smi tool is installed by default during the installation of the .run package driver. After an NPU 1.X.X or NPU 20.0.0 software package is installed, npu-smi is stored in the /usr/local/sbin/ directory. After an NPU 20.0.0 or later or NPU 20.1.X or later software package is installed, npu-smi is stored in the /usr/local/bin/ and /usr/local/sbin/ directories.
When NPU 1.X.X software packages are used for installation, the RPM package of the npu-smi tool can be installed independently. This section describes how to install the RPM package. If the npu-smi tool has been installed, you need to run the upgrade command to perform the upgrade. For details about the upgrade operations, see section "Upgrading the npu-smi Tool" in the Atlas 300I Inference Card 1.0.0.SPC200 and Later NPU Driver and Firmware Upgrade Guide (Models 3000, 3010).
Prerequisites
The driver of the Atlas 300I inference card (model 3000) has been installed. For details, see Installing the Driver (*.rpm).
Checking the Environment
The ld-linux-aarch64.so.1 file in the /lib64 directory is required for running the npu-smi tool. If the file does not exist in the /lib64 directory, the npu-smi tool fails to run.
Before installing the npu-smi tool, ensure that the ld-linux-aarch64.so.1 file exists in the /lib64 directory.
If the ld-linux-aarch64.so.1 file does not exist in /lib64, perform the following steps:
- Use PuTTY to log in to the OS CLI of the server where the Atlas 300I inference card (model 3000) is located. For details, see Logging In to the CLI Using PuTTY over a Network Port.
- Run the following command to switch to the root user:
su - root
- Run the find / -name ld-linux-aarch64.so.1 command to check the directory where the ld-linux-aarch64.so.1 file is located.
- If the file does not exist, install the GNU C library of the aarch64 version.
- If the file exists, go to 4.
- Run the mkdir -p /lib64 command to create the /lib64 directory.
- Run the ln -s /xxx/ld-linux-aarch64.so.1 /lib64 command to create a link pointing to the ld-linux-aarch64.so.1 file.
xxx indicates the directory where the ld-linux-aarch64.so.1 file is stored.
Procedure
- Obtain the npu-smi tool installation package A800-3000-NPU-EulerOS2.8-ARM-Vx.x.x.zip. For details, see Obtaining Software Packages.
- Log in to the server holding the Atlas 300I inference card (model 3000) as the root user.
- Upload the A800-3000-NPU-EulerOS2.8-ARM-Vx.x.x.zip package to a directory on the Linux OS, for example, /opt.
- Run the unzip A800-3000-NPU-EulerOS2.8-ARM-Vx.x.x.zip command to decompress the installation package. The .rpm installation package A800-3000-NPU-EulerOS2.8-Dsmitool-ARM-Vx.x.x.rpm is obtained.
- Run the following command to install the .rpm package:
rpm -ivh A800-3000-NPU-EulerOS2.8-Dsmitool-ARM-Vx.x.x.rpm
- Run the npu-smi -v command to check whether the npu-smi tool is successfully installed.If information similar to the following is displayed, the installation is successful. Otherwise, the installation fails. Contact Huawei technical support.
npu-smi Version : 1.0.2