Performing an automatic nondisruptive upgrade using the CLI

You can use the command line interface (CLI) to verify that the cluster can be upgraded nondisruptively, install the target ONTAP image on each node, and then, execute an upgrade in the background.

Before you begin

About this task

The cluster image validate command checks the cluster components to validate that the upgrade can be completed nondisruptively, and then provides the status of each check and any required action you must take before performing the software upgrade.
Note: Modifying the setting of the storage failover modify -auto-giveback command option before the start of an automatic nondisruptive upgrade (ANDU) has no impact on the upgrade process. The ANDU process ignores any preset value to this option during the takeover/giveback required for the update. For example, setting -autogiveback to false prior to beginning ANDU does not interrupt the automatic upgrade before giveback.


  1. Delete the previous ONTAP software package:cluster image package delete -version previous_ONTAP_Version
  2. Download the target ONTAP software package: cluster image package get -url location
    Note: If you are upgrading from ONTAP 9.3 to 9.7, download the software package for both ONTAP 9.5, and then use the same command to download the software package for 9.7.
    cluster1::> cluster image package get -url
    Package download completed.
    Package processing completed.
  3. Verify that the software package is available in the cluster package repository: cluster image package show-repository
    cluster1::> cluster image package show-repository
    Package Version  Package Build Time
    ---------------- ------------------
    9.7              MM/DD/YYYY 10:32:15
  4. Verify that the cluster is ready to be upgraded nondisruptively: cluster image validate -version package_version_number
    • If you are upgrading a two-node or four-node MetroCluster configuration, you must run this command on all nodes before proceeding.
    • If you are upgrading from ONTAP 9.3 to 9.7, use the 9.7 package for verification. You do not need to validate the 9.5 pacakage separately.
    cluster1::> cluster image validate -version 9.7
    WARNING: There are additional manual upgrade validation checks that must be performed after these automated validation checks have completed...
  5. Monitor the progress of the validation: cluster image show-update-progress
  6. Complete all required actions identified by the validation.
  7. Required: Generate a software upgrade estimate: cluster image update -version package_version_number -estimate-only
    The software upgrade estimate displays details about each component to be updated, and the estimated duration of the upgrade.
  8. Perform the software upgrade: cluster image update -version package_version_number
    • If you are upgrading a MetroCluster configuration, you run this command on only one of the two clusters.
    • If you are upgrading from ONTAP 9.3 to 9.7, use the 9.7 package_version_number in the above command. The automated upgrade process uses the 9.5 image in the background to complete the update to 9.7. It is not necessary for you to upgrade to 9.5, then do a separate upgrade to 9.7.
    • If the cluster consists of 2 through 6 nodes, a rolling upgrade is performed. If the cluster consists of 8 or more nodes, a batch upgrade is performed by default. If desired, you can use the -force-rolling parameter to specify a rolling upgrade instead.
    • After completing each takeover and each giveback, the upgrade waits for 8 minutes to enable client applications to recover from the pause in I/O that occurs during the takeover and giveback. If your environment requires more or less time for client stabilization, you can use the -stabilize-minutes parameter to specify a different amount of stabilization time.
    cluster1::> cluster image update -version 9.7
    Starting validation for this update. Please wait..
    It can take several minutes to complete validation...
    WARNING: There are additional manual upgrade validation checks...
    Pre-update Check      Status     Error-Action
    --------------------- ---------- --------------------------------------------
    20 entries were displayed
    Would you like to proceed with update ? {y|n}: y
    Starting update...
  9. Display the cluster update progress: cluster image show-update-progress
    Note: If you are upgrading a 4-node or 8-node MetroCluster configuration, the cluster image show-update-progress command only displays the progress for the node on which you run the command. You must run the command on each node to see individual node progress.
  10. Verify that the upgrade was completed successfully on each node.
    cluster1::> cluster image show-update-progress
                                                 Estimated         Elapsed
    Update Phase         Status                   Duration        Duration
    -------------------- ----------------- --------------- ---------------
    Pre-update checks    completed                00:10:00        00:02:07
    Data ONTAP updates   completed                01:31:00        01:39:00
    Post-update checks   completed                00:10:00        00:02:00
    3 entries were displayed.
    Updated nodes: node0, node1.
  11. Trigger an AutoSupport notification: autosupport invoke -node * -type all -message "Finishing_NDU"
    If your cluster is not configured to send AutoSupport messages, a copy of the notification is saved locally