VCS

few veritas cluster – storage foundation – infoscale command examples

# Display information about all Clusters

# for clu in `haclus -list`;do echo -e "\nCluster ${clu}"; haclus -display ${clu} ;done

# Display information about all Systems

# for sys in `hasys -list`; do echo -e "\nSystem ${sys}"; hasys -display ${sys} ;done

# Display information about all unique ServiceGroups

# for grp in `hagrp -list |awk '{print $1}'|sort|uniq`;do echo -e "\nServiceGroup ${grp}"; hagrp -display ${grp};done

# Display information about all unique Resources

# for res in `hares -list |awk '{print $1}'|sort|uniq`;do echo -e "\nResource ${res}"; hares -display ${res};done

# Display information about all unique Agents which are actually in use

# for res in `hares -list |awk '{print $1}'|sort|uniq`;do hares -display ${res}|grep " Type " ;done |awk '{print $4}'|sort|uniq |awk '{print "\nAgent "$1; system("haagent -display "$1);}'

Create diskgroup

# vxdg init diskgroup1 disk1

# vxdg -g diskgroup1 disk2 …

# vxdg -g diskgroup1 diskX

or remove disks

# vxdg -g diskgroup1 rmdisk diskX

… and remove diskgroup

# vxdg destroy diskgroup1

Rename disks

# vxedit -g diskgroup1 rename long-hard-to-remember-disk-name1 d1

# vxedit -g diskgroup1 rename long-hard-to-remember-disk-name2 d2

create subdisks and use max size what was displayed during listing

Run vxprint and note the disk sizes:

# vxprint -g diskgroup1 -htr Create subdisks:

# vxmake -g diskgroup1 sd d1-01 d1,0,211944000

# vxmake -g diskgroup1 sd d2-01 d2,0,211944000

create plexes

Create plexes p1 and p2. with a concat layout they are just as stripes with fancier name. # vxmake -g diskgroup1 plex p1 layout=concat sd=d1-01,d2-01

# vxmake -g diskgroup1 plex p2 layout=concat sd=d3-01,d4-01

create/remove mirrored volume

make a mirrored volume of previously made plexes or stripes

# vxmake -g diskgroup1 vol v1 plex=p1,p2 remove volume

# vxassist -g diskgroup1 remove volume v1

start/stop volume

# vxvol -g diskgroup1 start v1 # vxvol -g diskgroup1 stop v1

create vxfs

# mkfs.vxfs /dev/vx/dsk/diskgroup1/v1

make cluster conf RO or RW

# haconf -makerw # haconf -dump -makero

stop/offline and freeze servicegroup

# hagrp -offline myservicegroup -sys clusternode1

# hagrp -freeze myservicegroup -persistent

unfreeze and start/online servicegroup

# hagrp -unfreeze myservicegroup -persistent

# hagrp -online myservicegroup -sys clusternode1

Import and deport disk group

# vxdg import diskgroup1 # vxdg deport diskgroup1

If you found this useful, say thanks, click on some banners or donate, I can always use some beer money.