Upgrading the AtlasEdge Using CLI

Prerequisites

AtlasEdge has been installed.

Software Preparation

  • You have downloaded the upgrade package. For details, see Obtaining the Software Package.
  • You have uploaded the software package and signature file to the system (for example, to the /home/work directory).

Upgrade Procedure

  1. Log in to the system background as the root user.
  2. Run the following command to go to the AtlasEdge installation path/AtlasEdge directory:
    cd AtlasEdge_installation_path/AtlasEdge
  1. Upgrade the AtlasEdge software.
    ./run.sh upgrade -i Upgrade mode -f Upgrade package path -s Signature file path -c CRL file path -e Effective mode -t AtlasEdge

    Table 1 describes the parameters. During the upgrade process, the system automatically verifies the software package. If the verification fails, the system displays a message indicating that the upgrade fails.

    Command example:

    ./run.sh upgrade -i normal -f /home/work/Ascend-mindxedge-atlasedge_x.x.x_linux-aarch64.tar.gz -s /home/work/Ascend-mindxedge-atlasedge_x.x.x_linux-aarch64.tar.gz.cms -c /home/work/Ascend-mindxedge-atlasedge_x.x.x_linux-aarch64.tar.gz.crl -e now -t AtlasEdge

    x.x.x indicates the version of the software package.

    Table 1 Parameter description

    Parameter

    Description

    -i Upgrade mode

    Upgrade mode. The options are as follows:

    • normal: a normal upgrade, which involves the version number check. If the target version number is smaller than the source version number, the upgrade cannot be performed.
    • force: a forced upgrade, which skips the version number check.
    NOTE:

    For version 2.0.3 and later, the forcible upgrade in descending order of version numbers is not supported. Though the value is set to force, the upgrade is performed in normal mode. For details about how to downgrade the version to an earlier version, see How Do I Uninstall the Pre-installed Software and Install New Software in Batches?.

    -f Upgrade package path

    Path of the target AtlasEdge installation package, for example, /home/work/Ascend-mindxedge-atlasedge_{version}_linux-{arch}.tar.gz. Ascend-mindxedge-atlasedge_{version}_linux-{arch}.tar.gz is obtained after Ascend-mindxedge-atlasedge_{version}_linux-{arch}.zip is decompressed.

    -s Signature file path

    Path of the signature file for verifying the installation package during the upgrade, for example, /home/work/Ascend-mindxedge-atlasedge_{version}_linux-{arch}.tar.gz.cms. Ascend-mindxedge-atlasedge_{version}_linux-{arch}.tar.gz.cms is obtained after Ascend-mindxedge-atlasedge_{version}_linux-{arch}.zip is decompressed.

    -c CRL file path

    Path of the CRL file for verifying the installation package during the upgrade, for example, /home/work/Ascend-mindxedge-atlasedge_{version}_linux-{arch}.tar.gz.crl. Ascend-mindxedge-atlasedge_{version}_linux-{arch}.tar.gz.crl is obtained after Ascend-mindxedge-atlasedge_{version}_linux-{arch}.zip is decompressed.

    NOTE:

    The CRL in the installation package is used to verify the integrity of the installation package during the upgrade. If the CRL expires, the upgrade fails. You can import a new CRL by referring to Importing a CRL and then upgrade the software. The CRL can be imported only when the AtlasEdge software version is upgraded from 20.2.x (MindX Edge V100R020C20) to a later version.

    -e Effective mode

    Upgrade effective mode. The options are as follows:
    • now: The upgrade takes effect immediately after the upgrade.
    • delay: The upgrade takes effect only when a command is executed.

    -t AtlasEdge

    Type of the software package to be upgraded. For an AtlasEdge upgrade, set this parameter to AtlasEdge.

    -o (optional) operation mode

    Operation mode:
    • install (default): upgrade
    • effect: The operation mode takes effect.
    NOTE:
    • During the upgrade, if -e is set to now, you do not need to specify -o.
    • During the upgrade, if -e is set to delay, you need to run the following command to make the upgrade take effect:
      ./run.sh upgrade -o effect -t AtlasEdge
  2. After the upgrade, you need to go to the AtlasEdge working directory again to ensure that subsequent commands can be executed. For example, if the current directory is /usr/local/AtlasEdge, run the cd /usr/local/AtlasEdge command.