cancel
Showing results for 
Search instead for 
Did you mean: 

Availability

What is ‘Atleast resource dependency’?

Atleast resource dependency is useful where parent resource depends on multiple child resources but parent resource does not require all child resources to be online before parent resource comes online.

 

E.g. Let’s consider one parent resource ‘p’ which has ‘x’ number of child resources. When we link resource ‘p ‘with ‘x’ child resources using traditional VCS resource dependency, in such case ‘p’ can come online only when all ‘x’ child resources are online. This may restrict the functionality of ‘p’ resource where it does not require all child resources to be online when parent comes online. To overcome such restriction VCS has introduced ‘Atleast resource dependency’ which is available from VCS 6.2 onwards.

In Atleast resource dependency, resource ‘p’ can be linked with ‘x’ resources but ‘p’ resource can come online when ‘y’ number of resources(out of x) are online, it does not wait for all ‘x’ resources to be online.

This dependency can be useful for a case where nfs and share type of resources are configured.

 

 

Note: [In following configuration we are more focused on dependency between ip and share (share1, share2…etc.) resources.]

 

                                                                                    Traditional VCS resource dependency

 

In the below configuration, the NFS server is configured in VCS to provide highly available NFS shares. (Refer to the Veritas Cluster Server Bundle Agent Guide to know more about configuring NFS and Share resources). The resources in the service group are linked using traditional VCS resource dependency. All the resources have “Critical” attribute set to 0.

 

# hares -link ip share1

# hares -link ip share2

# hares -link ip share3

# hares -link ip share4

# hares -link ip share5

 

Snippet 1

nfs_1.PNG

Resources dependency view from CLI:

# hares -dep

#Group                    Parent                     Child

nfs_grp                    ip                             share1

nfs_grp                    ip                             share2

nfs_grp                    ip                             share3

nfs_grp                    ip                             share4

nfs_grp                    ip                             share5

nfs_grp                    ip                             proxy

nfs_grp                    lockmount               lockvol

nfs_grp                    lockvol                     diskgroup

nfs_grp                    mount                     vol

nfs_grp                    nfsrestart_L            nfs

nfs_grp                    nfsrestart_L            mount

nfs_grp                    nfsrestart_L            lockmount

nfs_grp                    nfsrestart_U           ip

nfs_grp                    share1                     nfsrestart_L

nfs_grp                    share2                     nfsrestart_L

nfs_grp                    share3                     nfsrestart_L

nfs_grp                    share4                     nfsrestart_L

nfs_grp                    share5                     nfsrestart_L

nfs_grp                    vol                           diskgroup

 

 

Drawbacks of using “Traditional resource dependency”:

1. User will not be able to offline single child resource

# hares -offline share1 -sys vcslx325

VCS WARNING V-16-1-10287 Online resources depend on resource share1. Take them offline first

2. Parent resource (ip resource) would not come online unless all child resources (share1, share2….etc.) are online.

3. If share1 resource goes into faulted state, VCS would offline all the parent resources (‘ip’ & ‘nfsrestart_U’) causing clients to lose access to the other shares (Refer snippet 2).

 

Snippet 2

nfs_2.PNG

 

How to solve the above challenges using Atleast resource dependency?

 

The existing configuration is now modified to use Atleast dependency between the IP and Share resources. The criteria of minimum 1 share resource to be available are set for the parent resource to be online.

Example:

# hares -link ip share1,share2,share3,share4,share5 -min 1

 

Snippet 3

nfs_3.PNG

 

Resources dependency view from CLI:

# hares -dep -atleast

#Group                    Parent                     Child

nfs_grp                    ip                             share1, share2, share3, share4, share5. Min = 1

nfs_grp                    ip                             proxy

nfs_grp                    lockmount               lockvol

nfs_grp                    lockvol                     diskgroup

nfs_grp                    mount                     vol

nfs_grp                    nfsrestart_L            nfs

nfs_grp                    nfsrestart_L            mount

nfs_grp                    nfsrestart_L            lockmount

nfs_grp                    nfsrestart_U           ip

nfs_grp                    share1                     nfsrestart_L

nfs_grp                    share2                     nfsrestart_L

nfs_grp                    share3                     nfsrestart_L

nfs_grp                    share4                     nfsrestart_L

nfs_grp                    share5                     nfsrestart_L

nfs_grp                    vol                           diskgroup

 

 

 

Benefits of using “Atleast resource dependency”:

1. User can offline single child resource (refer snippet 4).

# hares -offline share1 -sys vcslx325

 

Snippet 4

nfs_4.PNG

 

2. Parent resource (ip resource) would come online when any one child resource is online, IP resource will not wait all child resources (share2, share3….etc.) to come online (refer snippet 5).

 

Snippet 5

nfs_5.PNG

 

3. If share1 resource goes into faulted state, VCS would not offline the parent resources ( ‘ip’ & ‘nfsrestart_U’) . The shares exported from the other resources which are online would still be accessible to clients. (Refer snippet 6).

 

Snippet 6

nfs_6.PNG

 

Note: [All snippets are captured from VCS java GUI]

 

How to link resources using Atleast dependency?

Atleast resource dependency can be created via CLI using following command

hares -link <parent res> <child res>[,<child res>,<child res>,... -min <minimum>]

E.g.          # hares -link ip share1,share2,share3,share4,share5 -min 1

Note: Minimum criteria can vary between 1 & less than number of child resources.

 

How to unlink resources?

Resources can be unlinked via CLI using following command

hares -unlink <parent res> <child res>[,<child res>,<child res>,...]

E.g.          # hares -unlink ip share1,share2,share3,share4,share5