VxVM vxmake ERROR V-5-1-6642 Length for subdisk rootdisk

From Wiki-UX.info
Jump to: navigation, search

Abstract

The following article explains the available options to correct the VxVM error V-5-1-6642. This error occurs when the length of a subdisk is not a multiple of the disk group alignment. There are two VvVM logical volume supported alignments:

  1. Legacy 1 block (512 bytes) logical volume alignment.
  2. Cross-platform Data Sharing (CDS) 16 blocks (8 kilobytes) logical volume alignment.


NOTE: Disk groups compatible with the Cross-platform Data Sharing (CDS) requires the volume length to be a multiple of 8k or 16 blocks. There are documented procedures to change the alignment restriction or resize the logical volume to match the CDS restrictions, but on some circunstances, like a DRD clone of bootable rootdg, these methods will not allow to properly break the mirror image created by vxrootmir.


These alignment problems are normally present on HP-UX 11i v2 system migrated from VxVM 3.5 to VxVM 4.1 and | or VxVM 5.0 using Update-UX. VxVM 3.5 diskgroup version 90 used by VxVM 3.5 does not provided the CDS features, therefore no provisions are made to enforce the 16 block alignment.

Current versions of HP-UX using VxVM 4.1 or 5.0 are not affected by this problem.

Reproducing the error message

1. Mirror the rootdg diskgroup using vxrootmir script:

# /etc/vx/bin/vxrootmir -v -b c3t15d0
VxVM vxrootmir INFO V-5-2-2501 16:11: Gathering information on the current VxVM root configuration
VxVM vxrootmir INFO V-5-2-2441 16:11: Checking specified disk(s) for usability
VxVM vxrootmir INFO V-5-2-2478 16:11: Disk Media Name rootdisk02 is Disk Access Name c3t15d0
VxVM vxrootmir INFO V-5-2-1646 16:11: Mirroring all volumes on root disk
VxVM vxrootmir INFO V-5-2-1648 16:11: Mirroring volume swapvol
VxVM vxrootmir INFO V-5-2-1648 16:16: Mirroring volume tmpvol
VxVM vxrootmir INFO V-5-2-1648 16:18: Mirroring volume usrvol
VxVM vxrootmir INFO V-5-2-1648 16:22: Mirroring volume varvol
VxVM vxrootmir INFO V-5-2-1648 16:25: Mirroring volume varcrashvol
VxVM vxrootmir INFO V-5-2-1648 16:27: Mirroring volume varoptvol
VxVM vxrootmir INFO V-5-2-1648 16:28: Mirroring volume optvol
VxVM vxrootmir INFO V-5-2-1648 16:33: Mirroring volume standvol
VxVM vxrootmir INFO V-5-2-1649 16:34: Mirroring volume rootvol
VxVM vxrootmir INFO V-5-2-2462 16:36: Current setboot values:
VxVM vxrootmir INFO V-5-2-2569 16:36: Primary:  0/0/1/1.15.0
VxVM vxrootmir INFO V-5-2-2416 16:36: Alternate:        0/0/2/1.15.0
VxVM vxrootmir INFO V-5-2-2551 16:36: Making mirror disk c3t15d0 (0/0/2/1.15.0) the alternate boot disk
VxVM vxrootmir INFO V-5-2-1616 16:36: Disk c3t15d0 is now a mirrored root disk


2. Break the rootdg diskgroup mirror using the vxbrk_rootmir script.

# /etc/vx/bin/vxbrk_rootmir -g drd_rootdg -vb c3t15d0
VxVM vxbrk_rootmir INFO V-5-2-4023 16:38: Checking specified disk(s) for presence and type
VxVM vxbrk_rootmir INFO V-5-2-4025 16:38: DA c3t15d0, DM rootdisk02 is a valid root mirror
VxVM vxbrk_rootmir INFO V-5-2-4052 16:38: Saving configuration data for later restoration
VxVM vxbrk_rootmir INFO V-5-2-4022 16:38: Breaking off root mirror on DA c3t15d0
VxVM vxbrk_rootmir INFO V-5-2-4054 16:38: Setting broken off mirror on c3t15d0 as unique root disk
VxVM vxbrk_rootmir INFO V-5-2-2566 16:38: Preparing disk c3t15d0 as a VxVM root disk
VxVM vxmake ERROR V-5-1-6642 Length for subdisk rootdisk02-07 is not a multiple of the disk group alignment.
VxVM vxmake INFO V-5-1-9408 Subdisk length is 3592681 while disk group alignment is 8
VxVM vxmake ERROR V-5-1-10127 associating subdisk rootdisk02-07 with optvol-02: Record not in disk group
VxVM vxbrk_rootmir ERROR V-5-2-4020 Attempting to recreate volume meta-data on rootdisk02/c3t15d0

Symantec Support Document 325187 limitations

This error has been reported on VxVM 4.1 and 5.0 diskgroups: vxvm vxmake error v-5-1-6642 length subdisk not multiple of disk group alignment. According to this article:

The VERITAS Volume Manager 4.1 Administrators Guide explains why you are getting the error "VxVM vxmake ERROR V-5-1-6642 Length for subdisk is not a multiple of the disk group alignment."
Disk Group Alignment Constraints on Volumes
Certain constraints apply to the length of volumes and to the numeric values of size attributes that apply to volumes. If a volume is created in a disk group that is compatible with the Cross-platform Data Sharing (CDS) feature, the volumes length and the values of volume attributes that define the sizes of objects such as logs or stripe units, must be an integer multiple of the alignment value of 16 blocks (8 kilobytes). If the disk group is not compatible with the CDS feature, the volumes length and attribute size values must be multiples of 1 block (512 bytes).
To fix the alignment, run the following command:
# vxdg -g your_dg_name set align=1

For no bootable diskgroups, there is a documented procedure to rebuild the affected diskgroup using the vxcdsconvert script to resize the logical volumes. This method requires at least two disks on the diskgroup, with enough free space to hold a copy the largest logical volume of the other. The script uses space availabe as stepping stone to resize the volumes that does not comply with the cDS alignment restrictions.

This command cannot be used on bootable volumes that contains root or swap volume groups. The command will fail with the following message:

# /etc/vx/bin/vxcdsconvert -g rootdg -A group
VxVM vxcdsconvert ERROR V-5-2-2760 rootdisk01: Contains a volume with use-type of 'root' or 'swap'
VxVM vxcdsconvert ERROR V-5-2-3120 Conversion process aborted
NOTE: The -A flag runs the script in Preview (Analyze) Mode.


You can manually reduce the size of the non aligned volume groups to match the aligned restrictions. This will required to reduce the file system using OnlineJFS fsadm command and the volume groups itself using VxVM command.This is not support for boot critical volumes standvol, rootvol and swapvol.

If any of this volume are affected by alignment problems, Ignite-UX will be required to rebuild the system with correct alignments.

Determine which logical volumes do not comply with CDS alignment restrictions

Using the output of the vxprint -g <diskgroup> command, it is possible to determine which logical volumes do not comply with the CDS 16 block (8k) alignment restriction. For example, to test rootdg diskgroup:

# vxprint -g rootdg | grep ^v > /tmp/rootdg.out
# cat /tmp/rootdg.out
v  optvol       fsgen        ENABLED  3592681  -        ACTIVE   -       -
v  rootvol      root         ENABLED  851034   -        ACTIVE   -       -
v  standvol     fsgen        ENABLED  516000   -        ACTIVE   -       -
v  swapvol      swap         ENABLED  4194304  -        ACTIVE   -       -
v  tmpvol       fsgen        ENABLED  1048576  -        ACTIVE   -       -
v  usrvol       fsgen        ENABLED  3116526  -        ACTIVE   -       -
v  varcrashvol  fsgen        ENABLED  843776   -        ACTIVE   -       -
v  varoptvol    fsgen        ENABLED  843776   -        ACTIVE   -       -
v  varvol       fsgen        ENABLED  2764800  -        ACTIVE   -       -
# /tmp/rootdg.out | awk '{printf "%-20s\t%10d\t%10.2f\n", $2, $5, $5 / 8}'
optvol                     3592681       449085.12
rootvol                     851034       106379.25
standvol                    516000        64500.00
swapvol                    4194304       524288.00
tmpvol                     1048576       131072.00
usrvol                     3116526       389565.75
varcrashvol                 843776       105472.00
varoptvol                   843776       105472.00
varvol                     2764800       345600.00

Note that optvol, rootvol and usrvol logical volumes are not multiples of 8 kilobytes (16 blocks).

Use Ignite-UX to rebuild the rootdg diskgroup

The safest method to resolve this alignment problem is taken a system image of the whole rootdg using Ignite-UX recovery commands and rebuild the system from this image. HP-UX current bundle version of VxVM 4.1 and 5.0 enforces the creation of CDS aligned logical volumes.

1. Create recovery image using Ignite-UX recovery command. For example, for a network base recovery:

# make_net_recovery -v -s igniteserver -x inc_entire=rootdg

2. Rebuild the system with this image. Is not required to manually change the size of the volumes on the itool() File System tab, because the nearest aligned size will be automatically used.

3. Check the rootdg volume size after rebuilding the system.

# vxprint -g rootdg | grep ^v | awk '{printf "%-20s\t%10d\t%10.2f\n", $2, $5, $5 / 8}'
optvol                     3592680       449085.00
rootvol                     851032       106379.00
standvol                    256000        32000.00
swapvol                    4194304       524288.00
tmpvol                     1048576       131072.00
usrvol                     3116520       389565.00
varcrashvol                 843776       105472.00
varoptvol                   843776       105472.00
varvol                     2764800       345600.00

Note that optvol, rootvol and usrvol logical volumes were slightly reduced to match with the alignment restrictions.

Reference

Authors