Sun Cluster Geographic Edition 系统管理指南

在应用程序联机时创建保护组

在不使应用程序脱机的情况下,要将现有应用程序资源组添加到新的保护组,请在应用程序资源组处于联机状态的群集上执行以下步骤。

在另一个群集上执行以下步骤。


示例 10–1 应用程序保持联机状态的情况下创建 Hitachi TrueCopy 保护组的示例

此示例描述了如何在应用程序不脱机的情况下创建一个保护组。

在此示例中,apprg1 资源组在 cluster-paris 群集上处于联机状态。

  1. cluster-paris 上创建保护组。


    phys-paris-1# geopg create -d tc -p Nodelist=phys-paris-1,phys-paris-2 -o Primary \
    -s paris-newyork-ps tcpg
    Protection group "tcpg" has been successfully created
  2. 将设备组 tcdg 添加至该保护组。


    phys-paris-1# geopg add-device-group -p fence_level=async tcdg tcpg
  3. 从本地激活该保护组。


    phys-paris-1# geopg start-e local tcpg
    Processing operation.... this may take a while....
    Protection group "tcpg" successfully started.
  4. 将已联机的应用程序资源组添加至该保护组。


    phys-paris-1# geopg add-resource-group apprg1 tcpg
    Following resource groups were successfully inserted:
    			"apprg1"

    验证是否已成功添加该应用程序资源组。


    phys-paris-1# geoadm status
    Cluster: cluster-paris
    
       Partnership "paris-newyork-ps"    : OK
          Partner clusters               : newyork
          Synchronization                : OK
    
          Heartbeat "hb_cluster-paris~cluster-newyork" monitoring \
    "paris-newyork-ps" OK
             Plug-in "ping-plugin"       : Inactive
             Plug-in "icrm_plugin"       : OK
             Plug-in "tcp_udp_plugin"    : OK
    
       Protection group "tcpg"           : Degraded
          Partnership                    : paris-newyork-ps
          Synchronization                : OK
    
          Cluster cluster-paris          : Degraded
             Role                        : Primary
             Configuration               : OK
             Data replication            : Degraded
             Resource groups             : OK
    
          Cluster cluster-newyork        : Unknown
             Role                        : Unknown
             Configuration               : Unknown
             Data Replication            : Unknown
             Resource Groups             : Unknown
  5. 在伙伴群集的一个节点上,如下所示检索该保护组:


    phys-newyork-1# geopg get -s paris-newyork-ps tcpg
    Protection group "tcpg" has been successfully created.
  6. 在伙伴群集上本地激活该保护组。


    phys-newyork-1# geopg start-e local tcpg
    Processing operation.... this may take a while....
    Protection group "tcpg" successfully started.
  7. 验证是否已成功创建并激活该保护组。

    cluster-paris 上运行 geoadm status 命令会产生如下输出:


    phys-paris-1# geoadm status
    Cluster: cluster-paris
    
       Partnership "paris-newyork-ps"        : OK
          Partner clusters                   : newyork
          Synchronization                    : OK
    
          Heartbeat "hb_cluster-paris~cluster-newyork" monitoring \
    "paris-newyork-ps": OK
             Plug-in "ping-plugin"           : Inactive
             Plug-in "icrm_plugin"           : OK
             Plug-in "tcp_udp_plugin"        : OK
    
       Protection group "tcpg"               : Degraded
          Partnership                        : paris-newyork-ps
          Synchronization                    : OK
    
          Cluster cluster-paris              : Degraded
             Role                            : Primary
             Configuration                   : OK
             Data replication                : Degraded
             Resource groups                 : OK
    
          Cluster cluster-newyork            : Degraded
             Role                            : Secondary
             Configuration                   : OK
             Data Replication                : Degraded
             Resource Groups                 : OK