Create new Veritas Disk Group

Earlier I posted about how to add a new LUN to a Solaris 9 server. Today I’ll go through the process of adding that disk (emcpower6) to a new disk group and making it usable with a file system. This server has EMC Powerpath installed as well as the Veritas Storage Foundation running on it.

First, setup the disk inside Veritas, in this example I’ll use the sliced format (emcpower6 is the Veritas Device name – not the PowerPath pseudo name – use vxdisk list to see the name):

# /etc/vx/bin/vxdisksetup -i emcpower6 format=sliced

Initiate the disk group by adding the disk to a new group (tempdg-tmp). The device name is emcpower6 and the name of the disk inside the disk group will be called tempdg-tmp01:

# vxdg init tempdg-tmp cds=off tempdg-tmp01=emcpower6

See how big we can make the disk group:

# vxassist -g tempdg-tmp maxsize
Maximum volume size: 733952000 (358375Mb)

Setup the disk group to the maximum size (templv-tmp is the logical volume name):

# vxassist -g tempdg-tmp -b make templv-tmp 733952000 tempdg-tmp01 layout=nostripe

At this point you can take a look at what you created with vxprint:

# vxprint
Disk group: tempdg-tmp

dg tempdg-tmp tempdg-tmp – – – – – –

dm tempdg-tmp01 emcpower6s2 – 733952000 – – – –

v templv-tmp fsgen ENABLED 733952000 – ACTIVE – –
pl templv-tmp-01 templv-tmp ENABLED 733952000 – ACTIVE – –
sd tempdg-tmp01-01 templv-tmp-01 ENABLED 733952000 0 – – –

Create a file system on the logical volume, using VXFS:

# /opt/VRTS/bin/mkfs -F vxfs /dev/vx/rdsk/tempdg-tmp/templv-tmp
version 6 layout
733952000 sectors, 366976000 blocks of size 1024, log size 65536 blocks
largefiles supported

Create a mount point, mount it, see it mounted:

# mkdir /u2

# mount -F vxfs /dev/vx/dsk/tempdg-tmp/templv-tmp /u2

# df -h /u2
Filesystem size used avail capacity Mounted on
/dev/vx/dsk/tempdg-tmp/templv-tmp 350G 153M 328G 1% /u2


Leave a comment

Your email address will not be published. Required fields are marked *