Go to main content

Oracle® ZFS Storage Appliance 客户服务手册

退出打印视图

更新时间: 2018 年 11 月
 
 

升级单机控制器上的软件 (CLI)

按照以下过程升级单机控制器上的软件。

开始之前

完成准备软件升级

  1. 在本地系统上,按检查和下载软件更新 (CLI) 中所述下载软件更新。

    更新数据包是一个以版本号命名的压缩文件,例如 ak-nas-2013-06-05-0-0.0.pkg.gz。如果需要,可以对该文件进行重命名;版本号已记录在映像内。更新的大小可能各不相同,但通常为几百兆字节。

  2. 要使用 CLI 将软件更新下载到设备中,请转到 maintenance system updates 并输入 download
    hostname:maintenance system updates> download
    hostname:maintenance system updates download (uncommitted)> get
                              url = (unset)
                             user = (unset)
                         password = (unset)
    
  3. url 属性设置为有效的下载 URL。

    此 URL 可以位于本地网络,也可以位于 Internet 上。URL 可以为 HTTP(以 http:// 开头)或 FTP(以 ftp:// 开头)。如果需要用户验证,可以将其包含在 URL 中(例如,ftp://myusername:mypasswd@myserver/export/mydirectory),也可以将用户名和密码放在 URL 之外,并设置用户和密码属性。

    传输该文件后,会进行自动解压缩和验证。

    hostname:maintenance system updates download (uncommitted)> set url=ftp://mydirectory/update.pkg.gz
                              url = ftp://mydirectory/update.pkg.gz
    hostname:maintenance system updates download (uncommitted)> set user=bmc
                             user = bmc
    hostname:maintenance system updates download (uncommitted)> set password
    Enter password: 
                         password = (set)
    hostname:maintenance system updates download (uncommitted)> commit    
    Transferred 157M of 484M (32.3%) ...  
    Transferred 484M of 484M (100%) ... done 
    Unpacking ... done
    
  4. 输入 list 以查看状态。
    hostname:maintenance system updates> list
    UPDATE                                 RELEASE DATE              STATUS
    ak-nas@2013.06.05.4.0,1-1.7            2015-5-1 20:13            waiting
    ...
    
  5. 在这种情况下,您可以设置任何特定于更新的属性,包括应用延迟更新。

    此外,您也可以在更新软件后应用延迟更新。安装包含延迟更新的系统更新时,您可以选择根据请求或自动应用延迟更新。建议选择在更新后过程中根据请求应用延迟更新。

    有关可用于特定更新的属性集的更多信息,请运行 help properties 命令。用户可控的属性以 update_ 前缀开头:

    hostname:maintenance system updates ak-nas@2013.06.05.4.0,1-1.6> help properties
    Properties that are valid in this context:
    
       version              => Update media version
    
       release_date         => Update release date
    
       install_date         => Update install date
    
       status               => Update media status
    
       update_zfs_upgrade   => Apply incompatible storage pool update
    
    hostname:maintenance system updates ak-nas@2013.06.05.4.0,1-1.6> get
                           version = 2013.06.05.4.0,1-1.6
                      release_date = 2015-04-21 02:38:15:45
                      install_date = 2015-04-23 09:56:03:44
                            status = waiting
                update_zfs_upgrade = deferred
    hostname:maintenance system updates ak-nas@2013.06.05.4.0,1-1.6> set update_zfs_upgrade=onreboot
                update_zfs_upgrade = onreboot
    hostname:maintenance system updates ak-nas@2013.06.05.4.0,1-1.6> 
    
    
  6. 设置任意属性后,输入 upgrade 命令,然后输入 y 启动更新。
    hostname:maintenance system updates> select ak-nas@2013.06.05.4.0,1-1.7-nd 
    hostname:maintenance system updates ak-nas@2013.06.05.4.0,1-1.7-nd> upgrade
    The selected software update requires a system reboot in order to take effect.
    The system will automatically reboot at the end of the update process. The
    update will take several minutes. At any time during this process, you can
    cancel the update with [Control-C].
    
    Are you sure? (Y/N) y
    Updating from ... ak/nas@2013.06.05.4.0,1-1.6
    Backing up smf(5) ... done.
    Loading media metadata ... done.
    Selecting alternate product ... SUNW,iwashi
    Installing Sun Storage 7120 2013.06.05.4.0,1-1.7
    pkg://sun.com/ak/SUNW,iwashi@2013.06.05.4.0,1-1.7:20091014T084500Z
    Creating system/boot/ak-nas@2013.06.05.4.0,1-1.7 ... done.
    Creating system/root/ak-nas@2013.06.05.4.0,1-1.7 ... done.
    ...
    

    更新进行过程中,将显示最新的消息。通过按 Ctrl-C 并确认操作,您可以随时取消更新:

    Updating from ... ak/nas@2013.06.05.4.0,1-1.6
    Backing up smf(5) ... done.
    Loading media metadata ... ^C
    This will cancel the current update. Are you sure? (Y/N) y
    error: interrupted by user
    hostname:maintenance system updates ak-nas@2013.06.05.4.0,1-1.7-nd>
    
  7. 启用在升级之前被禁用的任何数据服务,如Oracle ZFS Storage Appliance 管理指南,发行版 OS8.8.0 中的 启用服务 (CLI)中所述。