Skip to content

Commit

Permalink
[mellanox] Fix in mlnx-ffb.sh (#2676)
Browse files Browse the repository at this point in the history
Fixes "No ISSU version file found /etc/mlnx/issu-version"
when rebooting to different image;
Add aditional check condition.

Signed-off-by: Stepan Blyschak <stepanb@mellanox.com>
  • Loading branch information
stepanblyschak authored and lguohan committed Mar 18, 2019
1 parent cfbc817 commit a45f41e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion platform/mellanox/mlnx-ffb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,16 @@ check_sdk_upgrade()

ISSU_VERSION_FILE_PATH="/etc/mlnx/issu-version"

[ -f "${SDK_VERSION_FILE_PATH}" ] || {
[ -f "${ISSU_VERSION_FILE_PATH}" ] || {
>&2 echo "No ISSU version file found ${ISSU_VERSION_FILE_PATH}"
break
}

[ -f "${FS_MOUNTPOINT}/${ISSU_VERSION_FILE_PATH}" ] || {
>&2 echo "No ISSU version file found ${ISSU_VERSION_FILE_PATH} in ${NEXT_SONIC_IMAGE}"
break
}

CURRENT_ISSU_VERSION="$(cat ${ISSU_VERSION_FILE_PATH})"
NEXT_ISSU_VERSION="$(cat ${FS_MOUNTPOINT}/${ISSU_VERSION_FILE_PATH})"

Expand Down

0 comments on commit a45f41e

Please sign in to comment.