Installing, Rolling Back, and Uninstalling the CANN Cold Patch Package

The CANN package supports cold patch upgrade. That is, one or more library files can be upgraded separately. Therefore, the CANN cold patch package is released.

Restrictions

  • The cold patch can be used to upgrade only the corresponding baseline version or patch version.
  • For cold patches based on the same baseline version, ensure that the cold patch version to be installed is later than the previous cold patch version.
  • Only one cold patch version can be rolled back.
  • The cold patch package provides .run and .rpm software packages.

Impact of Installation and Rollback

  • Other maintenance operations are not allowed during installation and rollback.
  • Services will be interrupted during cold patch package installation and rollback.
  • After the cold patch package is installed or rolled back, services are not affected.

Operations Related to the CANN Cold Patch Package (.run)

The CANN cold patch package can be installed and rolled back. You can set the parameters as required. For details about the parameters, see Table 1.

For example, to install a cold patch, run the following command (replace xxx.run in the command with the actual package name):

./xxx.run --install
Table 1 Parameters supported by the patch package

Parameter

Description

--help | -h

Queries help information.

--version

Queries the software package version.

--info

Queries software package build information.

--list

Queries the software package list.

--check

Checks the consistency and integrity of software packages.

--quiet

Indicates silent installation, which skips interactive messages.

--nox11

Indicates that the X11 mode is not used.

--noexec

Skips the execution of the installation script. It is used in pair with --extract=<path> in the format of --noexec --extract=<path>.

--extract=<path>

Decompresses a software package to a specified directory. When this parameter is used, a directory is automatically created during the extraction. For example, after the --noexec --extract=./package.run command is executed, the decompressed files are automatically stored in the package directory.

--tar arg1 [arg2 ...]

Runs the tar command on the runfile. Use the options following tar as the command-line options. For example, the --tar xvf command indicates that the RUN package will be decompressed to the current directory.

--install

Installs the cold patch package.

--rollback

Rolls back to the previous version.

--uninstall

Deletes the backup library file of the source version. Rollback is not supported.

--install-path=<path>

Specifies the installation path of the cold patch package.

The running user must have the read and write permissions on the specified path.

If no installation path is specified:

  • The installation path in the global configuration file ascend_cann_install.info is read first.
    You can run the following command to check whether the file exists in the following directory:
    • root user: /etc/Ascend
    • Non-root user: ${HOME}/Ascend
  • If ascend_cann_install.info does not exist in the current environment, the patch package is installed in the default path.
    • For installation as the root user, the default installation path is /usr/local/Ascend.
    • For installation as a non-root user, the default installation path is ${HOME}/Ascend.