Sun Cluster Software Installation Guide for Solaris OS

ProcedureHow to Create an NFS Application Resource Group on the Secondary Cluster

Before You Begin

Ensure that you completed steps in How to Create an NFS Application Resource Group on the Primary Cluster.

Steps
  1. Access nodeC as superuser.

  2. Register SUNW.nfs as a resource type.


    nodeC# scrgadm -a -t SUNW.nfs
    
  3. If SUNW.HAStoragePlus has not been registered as a resource type, register it.


    nodeC# scrgadm -a -t SUNW.HAStoragePlus
    
  4. Create an application resource group for the devicegroup.


    nodeC# scrgadm -a -g nfs-rg \
    -y Pathprefix=/global/etc \
    -y Auto_start_on_new_cluster=False \
    -y RG_dependencies=devicegroup-stor-rg
    
    nfs-rg

    The name of the application resource group.

    Pathprefix=/global/etc

    Specifies a directory into which the resources in the group can write administrative files.

    Auto_start_on_new_cluster=False

    Specifies that the application resource group is not started automatically.

    RG_dependencies=devicegroup-stor-rg

    Specifies the resource groups that the application resource group depends on. In this example, the application resource group depends on the replication resource group.

    If the application resource group is switched over to a new primary node, the replication resource group is automatically switched over. However, if the replication resource group is switched over to a new primary node, the application resource group must be manually switched over.

  5. Add a SUNW.HAStoragePlus resource to the application resource group.


    nodeC# scrgadm -a -j nfs-dg-rs -g nfs-rg \
    -t SUNW.HAStoragePlus \
    -x FileSystemMountPoints=/global/mountpoint \
    -x AffinityOn=True
    
    nfs-dg-rs

    Is the name of the HAStoragePlus resource for the NFS application.

    -x FileSystemMountPoints=/global/

    Specifies that the mount point for the file system is global.

    -t SUNW.HAStoragePlus

    Specifies that the resource is of the type SUNW.HAStoragePlus.

    -x AffinityOn=True

    Specifies that the application resource must perform an affinity switchover for the global devices and cluster file systems defined by -x GlobalDevicePaths=. Therefore, when the application resource group fails over or is switched over, the associated device group is switched over.

    For more information about these extension properties, see the SUNW.HAStoragePlus(5) man page.

  6. Add a logical hostname resource to the application resource group.


    nodeC# /usr/cluster/bin/scrgadm -a -L -j lhost-nfsrg-sec -g nfs-rg \
    -l lhost-nfsrg-sec
    

    lhost-nfsrg-sec is the logical hostname of the application resource group on the secondary cluster.

  7. Add an NFS resource to the application resource group.


    nodeC# /usr/cluster/bin/scrgadm -a -g nfs-rg \
    -j nfs-rs -t SUNW.nfs -y Resource_dependencies=nfs-dg-rs
    
  8. Ensure that the application resource group does not come online on nodeC.


    nodeC# /usr/cluster/bin/scswitch -n -j nfs-rs
    nodeC# /usr/cluster/bin/scswitch -n -j nfs-dg-rs
    nodeC# /usr/cluster/bin/scswitch -n -j lhost-nfsrg-sec
    nodeC# /usr/cluster/bin/scswitch -z -g nfs-rg -h ""
    

    The resource group remains offline after a reboot, because Auto_start_on_new_cluster=False.

  9. If the global volume is mounted on the primary cluster, unmount the global volume from the secondary cluster.


    nodeC# umount /global/mountpoint
    

    If the volume is mounted on a secondary cluster, the synchronization fails.

Next Steps

Go to Example of How to Enable Data Replication