Veritas Volume Manager (VxVM) and Veritas Cluster Server (VCS) are enterprise storage and HA solutions used in large-scale data centers. RHCA candidates should understand Veritas concepts even if they primarily use LVM and Pacemaker.
Veritas vs Linux Native Tools
| Function | Linux Native | Veritas |
|---|---|---|
| Volume management | LVM | VxVM (Veritas Volume Manager) |
| Filesystem | ext4, xfs | VxFS (Veritas File System) |
| Clustering | Pacemaker/Corosync | VCS (Veritas Cluster Server) |
| Snapshots | LVM snapshots | VxVM snapshots (FlashSnap) |
Veritas Volume Manager (VxVM)
VxVM Hierarchy
Physical Disks → Disk Groups → Volumes → Filesystems
# Physical disk (plex) — equivalent to LVM PV
# Disk Group (DG) — equivalent to LVM VG
# Volume — equivalent to LVM LV
VxVM Key Commands
# Initialize disk for VxVM:
# vxdisksetup -i /dev/sdb # add disk to VxVM control
# Create disk group:
# vxdg init mydg /dev/sdb /dev/sdc
# Add disk to disk group:
# vxdg -g mydg adddisk /dev/sdd
# Create volume:
# vxassist -g mydg make myvol 10g
# Create mirrored volume (RAID-1):
# vxassist -g mydg make myvol 10g layout=mirror
# Create striped volume (RAID-0):
# vxassist -g mydg make myvol 10g layout=stripe
# List disk groups:
# vxdg list
# List volumes:
# vxprint -g mydg
# Extend volume:
# vxassist -g mydg growby myvol 5g
# Remove volume:
# vxedit -rf rm /dev/vx/rdsk/mydg/myvol
VxFS Commands
# Create VxFS filesystem:
# mkfs -F vxfs /dev/vx/rdsk/mydg/myvol
# Mount VxFS:
# mount -F vxfs /dev/vx/dsk/mydg/myvol /mnt/data
# Grow VxFS (online):
# fsadm -F vxfs -b 20g /mnt/data # extend to 20G
# Snapshot:
# vxassist -g mydg snapshot myvol snapvol
Veritas Cluster Server (VCS)
VCS Concepts
- Service Group — group of resources that fail over together (like a Pacemaker resource group)
- Resource — individual component (IP, disk, application)
- Agent — monitors and manages a resource type
- HAD — High Availability Daemon — core VCS process
VCS Commands
# Check cluster status:
# hastatus -sum # summary
# hastatus -group # per service group
# List service groups:
# hagrp -list
# Online/offline service group:
# hagrp -online websg -sys node1
# hagrp -offline websg -sys node1
# Switch service group to other node:
# hagrp -switch websg -to node2
# Freeze (prevent failover):
# hagrp -freeze websg -persistent
# Unfreeze:
# hagrp -unfreeze websg -persistent
# List resources:
# hares -list
# Check resource state:
# hares -display
# hares -state
# Bring resource online:
# hares -online web_ip -sys node1
VCS Config Files
/etc/VRTSvcs/conf/config/main.cf # main cluster config
/etc/VRTSvcs/conf/config/types.cf # resource type definitions
# Validate config:
# hacf -verify /etc/VRTSvcs/conf/config/
Troubleshooting VCS
# Check VCS logs:
# cat /var/VRTSvcs/log/engine_A.log
# Check resource faults:
# hares -display -attribute Faulted
# Clear fault:
# hares -clear web_app -sys node1