Veritas Volume Manager and Cluster Interview Questions & Answers

1. How to add a disk to a disk group in Veritas Volume Manager?
Ans:

To add the physical disk c0t0d0 in the disk group homedg calling it disk90 in Veritas in Volume Manager:
# vxdg -g homedg adddisk disk90=c0t0d0

2. How to remove a disk from a disk group in Veritas Volume Manager?
Ans:

To remove a disk, disk90, from a disk group, homedg, in Veritas Volume Manager:
# vxdg -g homedg rmdisk disk90

3. How to clear an import in Veritas Volume Manager after a crash?
Ans:

# vxdisk clearimport c0t0d0s0

4. How to list all disks and display their status in VxVM?
Ans:

# vxdisk list

5. How to remove a grayed out or obsolete disk, or remove a disk from a disk group in Veritas Volume Manager?
Ans:

# vxdisk rm disk01

6. How to remove a disk so that it is no longer under Veritas Volume Manager controls?
Ans:

# vxdisk rm c0t0d0

7. How to add or bring a disk under Veritas Volume Manager control?
Ans:

To add or bring a disk under Veritas Volume Manager control:
# vxdiskadd c0t0d1
or
# vxdisksetup -i c0t0d1

Note: It might help to newfs the s2 slice of the disk and perform a vxdctl enable to get it to add a disk.

8. How to remove a volume and any subdisks and plexes associated in VxVM?
Ans: 

# vxedit -rf rm volume_name

9. How to rename the disk disk90 to be called disk80 in the group rootdg in Veritas Volume Manager?
Ans:

# vxedit -g rootdg rename disk90 disk80

10. How to set disk90 in the group homedg to be a hot spare in Veritas Volume Manager?
Ans:

# vxedit -g homedg set spare=on disk90

11. How to set the comment field of subdisk subdisk01-01 to “comments are here”?
Ans:

# vxedit set comment”comments are here” subdisk01-01

12. How to sets the user to ep, the group to epgrp and the mode rw-rw-rw on the volume vg01?
Ans:

# vxedit set user=ep group=epgrp mode=0666 vg01

Disk Group
13. How to display the default disk group?
Ans:

#vxdg defaultdg

14. How to set the default disk group?
Ans:

# vxdctl defaultdg <disk group>

15. How to display disk group information?
Ans:

# vxdg list or
# vxdg list <disk group>

16. How to display free disk space in disk group?
Ans:

# vxdg free or
# vxdg –g <disk group> free

17. How to create a disk group?
Ans:

# vxdg init <disk group> cds=on|off

18. How to create a disk group with a specified disk group version no.?
Ans:

# vxdg –T <DG version> init <disk group>

19. How to make a non CDS disk group to CDS disk group or vice versa?
Ans:

# vxdg –g <disk group> set cds=on|off

20. How to import a disk group?
Ans:

# vxdg import <disk group>

21. How to import a destroyed disk group?
Ans:

First you must know the DG ID of the destroyed disk group name. You can get the DG ID by displaying the included disk of destroyed DG.
# vxdg import <DG ID>

22. How to disable/deport a disk group?
Ans:

# vxdg deport <disk group>

23. How to rename a disk group during import operation?
Ans:

# vxdg –t –n <new disk group> import <disk group>

24. How to rename a disk group during deport operation?
Ans:

# vxdg –n <new disk group> deport <disk group>

25. How to clear locks on disk group during import?
Ans:

# vxdg –C import <disk group>

26. How to forcible import the disk group?
Ans:

# vxdg –f import <disk group>

27. How to move disk group object from one DG to another?
Ans:

# vxdg –o expand move <source DG> <target DG> <DG object>
# vxdg –o expand move datadg newdatadg disk01
It will move the entire associated object with disk02 from datadg to newdatadg.

28. How to split a disk group to form a new disk group?
Ans:

# vxdg –o expand split <old DG> <new DG> disk01 disk02
It will create a new DG with two specified disks.

29. How to join two DGs into one?
Ans:

# vxdg join <source DG> <target DG>

30. How to destroy a disk group?
Ans:

# vxdg destroy <disk group>

31. How to upgrade a Disk group?
Ans:

# vxdg upgrade <disk group>
It will upgrade the DG to the highest DG version supported by VxVM.
Or
# vxdg –T <Version No.> <disk group>
To upgrade to a specified version no.
We will see vxvm volume related interview questions on next part.

Check out the wonderful VXVM commands Man page.
[showglossary gid=”1717?]All the VXVM command’s manual pages have been contributed by JAIS.
JAIS’s Linked In Profile
JAIS’s Google +
JAIS’s Facebook

32. What are the different service group types ?
Ans:

Service groups can be one of the 3 type :
1. Failover – Service group runs on one system at a time.
2. Parallel – Service group runs on multiple systems simultaneously.
3. Hybrid – Used in replicated data clusters (disaster recovery setups). SG behaves as Failover within the local cluster and Parallel for the remote cluster.

33. Where is the VCS main configuration file located ?
Ans:

The main.cf file contains the configuration of the entire cluster and is located in the directory /etc/VRTSvcs/conf/config.

34. How to set VCS configuration file (main.cf) ro/rw ?
Ans:

To set the configuration file in read-only/read-write :

# haconf -dump -makero (Dumps in memory configuration to main.cf and makes it read-only)
# haconf -makerw (Makes configuration writable)

35. Where is the VCS engine log file located ?
Ans:

The VCS cluster engine logs is located at /var/VRTSvcs/log/engine_A.log. We can either directly view this file or use command line to view it :

# hamsg engine_A

36. How to check the complete status of the cluster
Ans:

To check the status of the entire cluster :

# hastatus -sum

37. How to verify the syntax of the main.cf file
Ans:

To verify the syntax of the main.cf file just mention the absolute directory path to the main.cf file :

# hacf -verify /etc/VRTSvcs/conf/config

38. What are the different resource types ?
Ans:

1. Persistent : VCS can only monitor these resources but can not offline or online them.
2. On-Off : VCS can start and stop On-Off resource type. Most resources fall in this category.
3. On-Only : VCS starts On-Only resources but does not stop them. An example would be NFS daemon. VCS can start the NFS daemon if required, but can not take it offline if the associated service group is take offline.

39. Explain the steps involved in Offline VCS configuration?

Ans:

1. Save and close the configuration :

# haconf -dump -makero
2. Stop VCS on all nodes in the cluster :

# hastop -all
3. Edit the configuration file after taking the backup and do the changes :

# cp -p /etc/VRTSvcs/conf/config/main.cf /etc/VRTSvcs/conf/config/main.cf_17march
# vi /etc/VRTSvcs/conf/config/main.cf
4. Verify the configuration file syntax :

# hacf -verify /etc/VRTSvcs/conf/config/
5. start the VCS on the system with modified main.cf file :

# hastart
6. start VCS on other nodes in the cluster.

40. How to check the status of various GAB ports on the cluster nodes?

Ans:

To check the status of GAB ports on various nodes :

# gabconfig -a

41. Whats the maximum number of LLT links (including high and low priority) can a cluster have ?
Ans:

A cluster can have a maximum of 8 LLT links including high and low priority LLT links.

42. How to check the detailed status of LLT links ?
Ans:

The command to check detailed LLT status is :

# lltstat -nvv

43. What are various GAB configuration files and their function ?
Ans:

The file /etc/gabtab contains the command to start the GAB.

# cat /etc/gabtab
/sbin/gabconfig -c -n 4
here -n 4 –> number of nodes that must be communicating in order to start VCS.

44. How to start/stop GAB?

Ans:

The commands to start and stop GAB are :
# gabconfig -c (start GAB)
# gabconfig -U (stop GAB)

45. How to start HAD or VCS ?
Ans:

To start HAD or VCS on all nodes in the cluster, the hastart command need to be run on all nodes individually.

# hastart

46. What are the various ways to stop HAD or VCS cluster ?
Ans:

The command hastop gives various ways to stop the cluster.

# hastop -local
# hastop -local -evacuate
# hastop -local -force
# hastop -all -force
# hastop -all

47. How to list all the resource dependencies?
Ans:

To list the resource dependencies :

# hares -dep

48. How to enable/disable a resource ?
Ans:

# hares -modify [resource_name] Enabled 1 (To enable a resource)
# hares -modify [resource_name] Enabled 0 (To disable a resource)

49. How to list the parameters of a resource?
Ans:

To list all the parameters of a resource :

# hares -display [resource]

For more  Click Here


For Course Content  Click Here