跳到主要内容

备份和恢复HA设备配置

本节提供了如何备份和恢复运行保证消息传递的配对高可用性(HA)Solace PubSub+ 设备的配置的信息。

不要在 PubSub+ Cloud 中的事件代理服务中使用此程序。在 PubSub+ Cloud 中使用此程序可能导致服务性能下降。相反,请参阅备份事件代理服务以获取更多信息。

一些配置信息未被备份,包括:

  • 产品密钥
  • TLS/SSL 服务器证书文件
  • TLS/SSL 服务器证书配置
  • 以下客户端证书:
    • 消息 VPN 桥接
    • 复制桥接
    • REST 交付点
    • 动态消息路由 (DMR)
    • 多节点路由 (MNR)
  • Kerberos Keytabs
  • 受信任的根配置(对于软件版本 8.2.0 之前的设备和版本 8.7.0 之前的软件事件代理)
  • 软件代理存储组
  • 软件代理扩展参数
  • 在代理中运行的监控代理(Datadog、SolGeneos)

此外,消息数据未被备份,包括:

  • 保证消息 spool
  • 队列消息
  • 回放日志消息

备份配置

运行保证消息传递的配对设备的默认备份过程是运行 copy current-config 特权 EXEC 命令。

然而,在创建配置文件备份之前,始终注意配对设备上保证消息传递活动的本地状态,并注意以下事项:

  • 在保证消息传递活动时创建配置文件备份会捕获备份时的保证消息传递配置.

  • 在保证消息传递不活动时(即在配对设备活动时)创建配置文件备份,会捕获此设备上次活动时的保证消息传递配置。此外,不活动设备的备份包含此设备上次活动时存在的队列和主题端点配置.

  • 队列和主题端点配置更改仅在不活动的配对设备承担活动角色时被确认.

  • Solace 建议使用命名方案为备份的保证消息传递配置文件命名,以帮助识别备份时的设备和保证消息传递活动.

例如,考虑配对设备 R1R2 的备份,其中 R1 是活动的,R2 是不活动的:

copy current-config config_R1_AD_active
copy current-config config_R2_AD_inactive

回滚到之前的配置

恢复运行保证消息传递服务的冗余设备对的配置文件的默认过程是使用 reload 特权 EXEC 命令,如下所述。结果是恢复之前备份的保证消息传递服务配置.

在以下过程中,所有 spool 消息将丢失.

要回滚到冗余设备对使用的之前的保证消息传递配置,请使用以下程序:

  1. 选择您要回滚到的主设备的备份配置文件。配置文件必须是在保证消息传递服务活动时创建的.

  2. 按照以下步骤在主设备上回滚到选定的备份配置文件:

    solace1# configure
    solace1(configure)# redundancy
    solace1(configure/redundancy)# shutdown
    solace1(configure/redundancy)# exit
    solace1(configure)# hardware message-spool
    solace1(configure/hardware/message-spool)# shutdown
    solace1(configure/hardware/message-spool)# end
    solace1# admin
    solace1(admin)# system message-spool
    solace1(admin/system/message-spool)# reset
    solace1(admin/system/message-spool)# end
    solace1# reload config <config-file>

    设备将使用恢复的配置重启。所有 spool 消息将丢失.

    solace1# configure
    solace1(configure)# hardware message-spool
    solace1(configure/hardware/message-spool)# shutdown
    solace1(configure/hardware/message-spool)# end
  3. 在次设备上,关闭冗余和消息 spool,然后重置消息 spool:

    solace2# configure
    solace2(configure)# redundancy
    solace2(configure/redundancy)# shutdown
    solace2(configure/redundancy)# exit
    solace2(configure)# hardware message-spool
    solace2(configure/hardware/message-spool)# shutdown
    solace2(configure/hardware/message-spool)# end
    solace2# admin
    solace2(admin)# system message-spool
    solace2(admin/system/message-spool)# reset
    solace2(admin/system/message-spool)# end
  4. 在主设备上声明磁盘所有权,并启动消息 spool 和冗余:

    solace1# admin
    solace1(admin)# system message-spool
    solace1(admin/system/message-spool)# assert-disk-ownership
    solace1(admin/system/message-spool)# end
    solace1# configure
    solace1(configure)# hardware message-spool
    solace1(configure/hardware/message-spool)# no shutdown primary
    solace1(configure/hardware/message-spool)# exit
    solace1(configure)# redundancy
    solace1(configure/redundancy)# no shutdown
  5. 当主设备恢复服务时,选择配对设备的备份配置文件.

  6. 运行以下命令在次设备上回滚到选定的备份配置文件:

    solace2# reload config <config-file>

    设备将使用恢复的配置重启。所有 spool 消息将丢失.

  7. 检查两个设备的活动状态:

    • 第一个设备为 local active/local active
    • 第二个设备为 mate active/mate active
  8. 如果主设备上的备份虚拟路由器为 local active,您可能希望通过在主设备上执行 revert-activity 来恢复通常状态:

    solace1# admin
    solace1(admin)# redundancy revert-activity
    solace1(admin)# end
  9. 如果 HA 对使用 SSL,则通过重新加载来恢复服务器证书。有关加载服务器证书的说明,请参阅加载服务器证书文件.

  10. 冗余设备对的配置可能需要协调。使用 Config-Sync 来断言一个设备的配置优于其配对设备。有关更多信息,请参阅断言事件代理 VPN 配置.