Dell Networking:如何验证为 Dell Networking 交换机下载的 OS10 固件映像的校验和

Summary: 本文介绍如何验证下载到 DELL Networking OS10 交换机的固件映像的校验和。

This article applies to This article does not apply to This article is not tied to any specific product. Not all product versions are identified in this article.

Instructions

目录

  1. 为什么需要校验和。
  2. 在哪里可以找到sha256校验和文件
  3. 在 Switch 中的什么位置可以找到下载的“映像文件”
  4. 计算下载的文件的校验和

为什么需要校验和

在传输过程中,文件可能会损坏。我们可以使用校验和来检查文件的数据完整性。校验和是使用 md5、SHS224、SHA256 等校验和算法从文件中生成的数字。OS10 软件包中包含 SHA256 校验和文件,可用于检查下载到交换机的文件的数据完整性。

在哪里可以找到SHA256校验和文件

每个固件版本的校验和都不同。签入安装包以获取校验和文件。

该校验和文件包含在安装程序包中。当解压缩下载内容时,可以看到这一点。此文件为 SHA256 类型。

下面重点介绍一个示例。
校验和文件类型的屏幕截图

使用记事本或任何类似的实用程序打开文件。字符串包含 64 个字符。此 64 个字符的字符串必须与下载到映像的映像的哈希输出相匹配。

输出
示例下面是在记事本中打开的 SHA256 文件。
在记事本中打开的校验和文件的屏幕截图

此处的校验和值为“d69dd152db027cb81b80be5a1f4b6e5c63e2d187d5c0e9f73e2d6d1a3b9c6d57”。这必须与下载文件计算的校验和值匹配。

在 Switch 中的什么位置可以找到下载的“映像文件”

在执行 OS10 固件升级时,我们使用“image download”命令将软件映像从 TFTP、FTP、SCP、HTTP 或 USB 下载到交换机。此文件将下载到 /var/os10-image 文件夹。

我们可以使用“dir image”命令查看下载到交换机的文件

输出示例

Switch# dir image
Directory contents for folder: image
Date (modified)        Size (bytes)  Name
---------------------  ------------  ------------------------------------------
2020-12-18T12:54:51Z   477981208     PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin

计算下载的文件的校验和

我们可以通过下面提到的任何方法计算下载文件的 SHA256 校验和。

方法 1:在 OS10 CLI 中,使用“image verify”命令 [OS 10.5 及更高版本]

命令语法

命令 说明
Switch# image verify image://<image name> sha256 用于计算文件的 sha256 校验和的命令。

输出示例

Switch# image verify image://PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin sha256
Hash of image: d69dd152db027cb81b80be5a1f4b6e5c63e2d187d5c0e9f73e2d6d1a3b9c6d57

方法 2:在 OS10 CLI 中,使用 SHA256sum 命令

命令语法

使用该选项卡不会自动填充“system”命令。

命令 说明
Switch# system “ls /var/os10-image/” 验证下载的文件是否存在于文件夹 /var/os10-image/ 中
Switch# system "sha256sum /var/os10-image/<image file name>" 用于计算文件的 sha256 校验和的命令。

输出示例

Switch# system “ls /var/os10-image/”
PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin    ========>Verify file name

Switch# system "sha256sum /var/os10-image/</PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin"
d69dd152db027cb81b80be5a1f4b6e5c63e2d187d5c0e9f73e2d6d1a3b9c6d57  /var/os10-image/PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin ========>Verify the checksum with the checksum in file

方法 3:在 shell 中使用 sha256sum 命令

命令语法

命令 说明
Switch# system bash 登录到 Shell,我们必须提供管理员密码。
admin@Switch:~$ ls /var/os10-image/ 验证下载的文件是否存在于文件夹 /var/os10-image/ 中
admin@Switch/var/os10-image$ sha256sum /var/os10-image/<image file name> 用于计算文件的 sha256 校验和的命令。
admin@Switch/var/os10-image$ exit 退出

输出示例

Switch# system bash               ============>Provide admin password when prompted
admin@Switch:~$ ls /var/os10-image/
PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin ========>Verify file name

admin@Switch:~$ sha256sum /var/os10-image/PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin
d69dd152db027cb81b80be5a1f4b6e5c63e2d187d5c0e9f73e2d6d1a3b9c6d57  /var/os10-image/PKGS_OS10-Enterprise-10.5.0.7.745stretch-installer-x86_64.bin ========>Verify the checksum with the checksum in file

 

Affected Products

S Series, PowerSwitch S3048-ON, PowerSwitch S4048-ON, PowerSwitch S4810P, PowerSwitch S4810-ON, PowerSwitch S4820T, PowerSwitch S5000, PowerSwitch S6000 ON, Dell EMC Networking MX7116n, Dell EMC Networking MX9116n, Dell EMC Networking N3200-ON , PowerSwitch S4048T-ON, PowerSwitch S4112F-ON/S4112T-ON, PowerSwitch S4128F-ON/S4128T-ON, PowerSwitch S4148F-ON/S4148T-ON/S4148FE-ON, PowerSwitch S4148U-ON, PowerSwitch S4248FB-ON /S4248FBL-ON, PowerSwitch S5048F-ON, PowerSwitch S5148F-ON, PowerSwitch S5212F-ON, PowerSwitch S5224F-ON, PowerSwitch S5232F-ON, PowerSwitch S5248F-ON, PowerSwitch S5296F-ON, PowerSwitch S6010-ON, PowerSwitch S6100-ON, PowerSwitch Z9100-ON, PowerSwitch Z9264F-ON, PowerSwitch Z9332F-ON ...

Products

PowerSwitch S4128F-ON/S4128T-ON, PowerSwitch S4148F-ON/S4148T-ON/S4148FE-ON, PowerSwitch S4148U-ON, PowerSwitch S4248FB-ON /S4248FBL-ON, PowerSwitch S5212F-ON, PowerSwitch S5224F-ON, PowerSwitch S5232F-ON, PowerSwitch S5248F-ON, PowerSwitch S5296F-ON , PowerSwitch S5448F-ON, PowerSwitch Z9100-ON, PowerSwitch Z9264F-ON, PowerSwitch Z9332F-ON, PowerSwitch Z9432F-ON ...
Article Properties
Article Number: 000181434
Article Type: How To
Last Modified: 17 Jul 2025
Version:  11
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.