Veritas notes
The following notes are for Veritas Volume Manager 3.2 for Solaris.
"vxvm:vxconfigd: ERROR: enable failed: Error in disk group
configuration copies
Disk group has no valid configuration copies; transactions are
disabled."
When receiving this error during system boot and when running vxinstall, follow the steps
detailed in http://www.eng.auburn.edu/pub/mail-lists/veritas-users.May99/msg00048.html
In my case, the rootdg configuration was apparently corrupted. After
issuing touch
/etc/vx/reconfig.d/state.d/install-db and rebooting the
machine,
I was able to run vxinstall.
vxvm:vxdg: ERROR: Disk group disk_group:
import failed: Disk group has no valid configuration copies"
This error can occur when attempting to import a disk group that was
configured using a later version of VxVM. In this case, the disk group
was configured with VxVM 3.2, but VxVM 3.1.1 was installed.
# pkginfo -l VRTSvxvm
PKGINST:
VRTSvxvm
NAME: VERITAS Volume Manager, Binaries
CATEGORY: system
ARCH: sparc
VERSION: 3.1.1,REV=01.30.2001.22.21
Upgrading to at least the same version of VxVM used to configure the
disk group will allow the disk group to be imported.
"ld.so.1: vxconfigd: fatal: libdevid.so.1: open failed: No such
file or directory"
With Solaris 8 and VxVM 3.2, the shared library libdevid.so.1 does not get copied
to /etc/vx/slib after
installing
Veritas. If you do not manually copy this shared library to /etc/vx/slib, your system will not
boot. Follow these steps to make your system bootable:
1. Boot off a CD-ROM.
2. Mount your root and usr file systems.
3. Copy /usr/lib/libdevid.so.1
to /etc/vx/slib
4. Unmount your root
and usr file systems and
reboot.
More information:
http://marc.theaimsgroup.com/?l=veritas-vx&m=102636855529467&w=2
Clearing device locks
To clear a device lock, use the vxdisk
clearimport command:
vxdisk clearimport devicename
ex. vxdisk clearimport c0t1d0
Using a Sun StorEdge A5000 disk array with Veritas
Make sure the array(s) are recognized by the operating system.
# luxadm probe
Found Enclosure(s):
SENA
Name:a1 Node WWN:50800200000276e0
Logical Path:/dev/es/ses2
Logical Path:/dev/es/ses7
SENA
Name:a2 Node WWN:5080020000028020
Logical Path:/dev/es/ses3
Logical Path:/dev/es/ses6
SENA
Name:a0 Node WWN:5080020000026f38
Logical Path:/dev/es/ses4
Logical Path:/dev/es/ses5
SENA
Name:a3 Node WWN:5080020000027060
Logical Path:/dev/es/ses8
Logical Path:/dev/es/ses9
Run Veritas' device discovery program.
# vxdctl enable
Determining maximum size of a
volume
vxassist [ -g diskgroup ]
maxsize layout=layout [attributes]
Example:
vxassist -g datadg maxsize layout=concat
layout may be concat, mirror, raid5, mirror-stripe, or stripe-mirror.
Veritas disk requirements
Disks managed by VxVM must have
(1) two free partitions and (2) 2048 sectors of free space. The prtvtoc command displays how many
sectors are in a disk cylinder:
# prtvtoc /dev/rdsk/c0t86d0s2
* /dev/rdsk/c0t86d0s2 partition
map
*
* Dimensions:
* 512
bytes/sector
* 133
sectors/track
*
27 tracks/cylinder
* 3591 sectors/cylinder
* 4926 cylinders
* 4924
accessible cylinders
In this example, leave at least 1 cylinder free in your disk
layout to allow for VxVM. If the disk is a boot disk, VxVM can shrink
the swap partition to create space for VxVM's configuration data, but
two free slices are essential for encapsulation.
Creating a volume with vxassist
ex.
# vxassist -g datadg maxsize
Maximum volume size: 35356672
(17264Mb)
# vxassist -g datadg make volume 35356672
Create the vxfs file system:
# mkfs -F vxfs /dev/vx/rdsk/datadg/db_backups
version 4
layout
35356672
sectors, 17678336 blocks of size 1024, log size 16384 blocks
unlimited
inodes, largefiles not supported
17678336 data
blocks, 17657432 free data blocks
540 allocation
units of 32768 blocks, 32768 data blocks
last
allocation unit has 16384 data blocks
Create the mount point:
# mkdir /db_backups
Mount the vxfs file system:
# mount -F vxfs
/dev/vx/dsk/datadg/db_backups /db_backups
Add an /etc/vfstab
entry to mount the file system after a reboot.
Replacing a failed disk
After replacing a failed disk in a SENA, make sure to run vxdctl enable for device discovery.
Otherwise, you may encounter vxdmpadm
errors:
Initialization of disk
device c1t74d0 failed.
Error: vxvm:vxdmpadm:
ERROR: Error in ioctl/open
vxdmpadm: No such file or
directory
vxvm:vxdmpadm: ERROR: Invalid
da_name
vxvm:vxdmpadm: ERROR: Invalid
da_name
vxdisksetup: c1t74d0: Device
address must be of the form cCtTdD or mcCtTdD where
C = host bus
adapter controller number
T = target
device controller number, if used
D = logical
unit (disk) number within target device controller
# vxdisk list c1t74d0s2
Device:
c1t74d0s2
devicetag: c1t74d0
type:
sliced
flags:
online error private autoconfig
errno:
Device path not valid
Multipathing information:
numpaths: 2
c1t74d0s2
state=disabled
c5t74d0s2
state=disabled
When replacing a failed internal disk on a Sun E450 running Solaris 8,
I had to spin the disk down using ssaadm
stop /dev/rdsk/cxtxdxs2as
the vxdiskadm's "Disable
(offline) a disk device" did not seem to spin the disk down. If you are
using a Sun system with FC-AL devices, you will want to use the luxadm command.
After replacing the disk, I enabled device discovery with vxdctl enable and un-relocated the
failed subdisks back to this disk using /usr/lib/vxvm/bin/vxunreloc -g disk_group replaced_disk.
Adding additional users to VxVM electronic mail notifications
By default, VxVM sends electronic mail to the root user when failures
are detected and hot-relocation is being performed. To notify
additional
users,
1. Edit /etc/init.d/vxvm-recover
2. Change the line containing vxrelocd
root & to vxrelocd root user1 user2 ... &
This will preserve the change across system reboot.
3. To have the change take effect immediately, make sure that
hot-relocation is not currently being performed by running vxtask list, kill the vxrelocd process, and run nohup vxrelocd root user1 user2 ... &
Miscellaneous
Adding a
disk to a disk group:
vxdiskadd disk_name
Creating a subdisk:
vxmake [-g groupname] sd subdisk
diskname,offset,length
Creating a plex:
vxmake [-g groupname] plex plex sd=subdisk1[,subdisk2,...]
Creating a volume with vxmake:
vxmake [-g groupname] -U
fsgen vol volume plex=plex1[,plex2,...]
Note: use gen instead of fsgen if you are creating a raw
file
system for RDBMS usage. fsgen
is appropriate for general file system usage. More
information on fsgen vs. gen.
After creating the volume, initialize the volume with vxvol start volume. If applicable,
create the file system with newfs,
create the mount point, and mount the volume as a file system.
Associating subdisks with plexes:
vxsd assoc plex subdisk1 [subdisk2 subdisk3 ...]
Displaying free disk space in a diskgroup:
vxdg [-g groupname] free
Dissociating subdisks from plexes:
vxsd dis subdisk
Dissociating subdisks from plexes, removing subdisk from VxVM:
vxsd -o rm dis subdisk
Dissociating and removing plexes and all associated
subdisks:
vxplex -o rm dis plex
Removing a disk from a disk group:
vxdg [-g groupname] rmdisk diskname
Renaming a disk:
vxedit rename old_diskname new_diskname
Removing a volume (vxassist):
vxassist remove volume volume
Removing a volume
(vxedit):
vxedit [-r] [-f] rm volume
-r -- recursive removal
-f -- force removal; needed if
volume is enabled
Moving hot-relocated subdisks back to their original disk with vxunreloc:
/usr/lib/vxvm/bin/vxunreloc [-g groupname]original_disk
Back
to brandonhutchinson.com.
Last modified: 12/01/2003