Parameters and Commands
Description
One-click software installation is supported in the command line. You can select commands as required to complete the installation. All parameters below are optional.
Installation command syntax: ./xx.run [options]
Table 8-7 describes the supported options.
Replace the xx in the driver package based on the actual situation.
If the parameter queried by running the ./xx.run --help command is not in the following table, the parameter is reserved or applies to other processor models.
Parameter |
Description |
---|---|
--run |
Indicates the running type: installs only the files required in a running scenario. |
--devel |
Indicates the developer installation type: includes only the header files required for application development. The firmware subpackage does not support this parameter. |
--full |
Indicates full installation: installs all files. |
--docker |
Indicates the container-based installation mode for the driver subpackage only. Other subpackages use the full installation mode by default. |
--install-username=<username> |
Initial installation: You can specify the running user name. Otherwise, HwHiAiUser is used by default. Overwrite installation: The username used in the last installation applies. NOTE:
|
--install-usergroup=<usergroup> |
Initial installation: You can specify the running user group name. Otherwise, HwHiAiUser is used by default. Overwrite installation: The user group used in the last installation applies. NOTE:
This parameter must be used together with --install-username=<username>, and the value of usergroup must be the same as that of the created user group (Creating a Running User). |
--install-path=<path> |
Specifies the installation directory. Otherwise:
The running user must have the read and write permissions on the specified path. The path can contain letters, digits, underscores (_), hyphens (-), periods (.), and a slash (/). Note that periods (.) are not allowed in a relative path and slashes (/) are not allowed in a file or directory name. NOTE:
The firmware installation path cannot be specified. The driver installation path is shared. |
--install-for-all |
Allows all users to have the same installation group permission. If this option is included in the installation command, all users have the same permission on the directories and files created by the runfile installer as the installation group. If the --install for all option is used during the initial installation, retain it during any overwrite installation. Example: ./xx.run --full --install-for-all NOTE:
|
--reset |
Restores the initial configuration. (This parameter applies only to the firmware subpackage.)
After the initial configuration is restored, the original personal configuration data on the device becomes invalid and needs to be reconfigured. The personal configuration data includes the SSH login password and SSH enabling status. After the initial configuration is restored, change the SSH login password of the device (including the passwords of the HwHiAiUser and root users) immediately. NOTE:
|
--uninstall |
Performs uninstallation. |
--nox11 |
Indicates that the graphical terminal window is not displayed during the installation. Example: ./xx.run --full --nox11 NOTE:
This parameter applies only to NPU 21.0.4 and later versions. |
--noexec |
Skips the execution of the installation script. This parameter is used together with the --extract=path parameter, in the format of --noexec --extract=path. |
--extract=<path> |
Extracts the runfile to a specified path. When this parameter is used, a directory is automatically created during the extraction. For example, after the --noexec --extract=./package command is executed, the decompressed files are automatically stored in the package directory. |
--upgrade |
Performs the upgrade.
|
--help or -h |
Displays help information. |
--check |
Checks the software package integrity and the mapping between installed software packages. |
--version |
Queries the version. |
--tar arg1 [arg2 …] |
Runs the tar command on the installation package. Arguments following tar are used as the command arguments. For example, the --tar xvf command decompresses a package to the current path. |
--list |
Lists the files in the installation package. |
--info |
Displays detailed information of a data packet. |
--quiet |
Indicates silent installation, which skips interactive messages. In silent installation mode, if the permission on the installation directory is greater than 755, security risks are reported. In this case, you can choose to terminate the installation or re-execute the runfile in another directory with permission 755. Example: ./xx.run --full --quiet NOTE:
This option cannot be used together with --uninstall for driver and firmware software packages. |
--repack [package_name] |
Builds a new driver package. package_name indicates the name of the newly built xx.run driver package. NOTE:
If package_name is left blank, a file named Original driver package name-custom.run is generated in the current path. |
--repack-path=<path> [package_name] |
Builds a new driver package in the specified path.
NOTE:
If package_name is left blank, a file named Original driver package name-custom.run is generated in the current path. |
--force |
This option only installs the package. You need to restart the system for the package to take effect. (This parameter applies only to the driver subpackage.) This option must work with any one among --run, --full, --upgrade, and --uninstall, for example, ./xx.run --full --force. NOTE:
This parameter applies only to NPU 22.0.0 and later versions. If this parameter is used when the driver is installed for the first time, you must restart the system before uninstalling or overwriting the installation. Otherwise, the uninstallation or overwriting installation may fail. |
Example:
- Installation in full mode
- ./xx.run --full: without installation path specified
- ./xx.run --full --install-path=installation_path: with installation path specified
- Installation in Docker mode (applies to the driver only)
- ./xx.run --docker: without installation path specified
- ./xx.run --docker --install-path=installation_path: with installation path specified
- Installation in run mode
- ./xx.run --run: without installation path specified
- ./xx.run --run --install-path=installation_path: with installation path specified
- Installation in developer mode
- ./xx.run --devel: without installation path specified
- ./xx.run --devel --install-path=installation_path: with installation path specified