How to Restore Private Region in VxVM

How to Restore Private Region in Veritas Volume Manager

Veritas Volume Manager is so vast and need good level of knowledge before fixing any private region related issues. Troubleshooting in Veritas Volume Manager is not that easy and needs very careful approach and may be assistance needed from Veritas Support.

Especially related to issues with private region corruption or needs to be fixed with absolute care. Once Disk is presented to host under Unix Linux System it must be visible to OS.As you know VxVM is the intelligent volume manager software which manage the disks efficiently and eliminates short comings of SVM and LVM.

Veritas Cluster File System

VxVM maintains it’s own device tree for management of disks efficiently. For example in Solaris VTOC volume table of contents for devices is maintained by Solaris Operating System. prtvtoc is command to see the volume table of contents. 

So once disk is taken into Veritas Volume Manager control by initializing disk using vxdisksetup disks gets divided into two regions called Private and Public Regions.

Public Regions often called as data regions where actual data gets stored on disk. Private Regions are small area of disks where disks configurations are stored which is not being used to store data.


Configurations like metadata of disk for the management of many operations on disks. Information like Disk header label, vxvm objects and log locations etc.

Default private region size is 32MB except boot disk group where private region size is 1 MB which is more than sufficient to hold several thousands of VxVM objects in disk group.

Linux Virtual Machine

In most of the cases default size of private region is sufficient for disk management purpose but it can be overwritten When disk is added via vxdiskadm command.

All the disk have a private region which holds an full copy of the configuration database for the entire disk group.

VxVM Disk Types

Various type of disks defines how VxVM access the disk and how private and public region of disks is managed .


auto : When veritas configuration daemon vxconfigd started it obtains list of known disk devices address from operating system and configures disk access records for them automatically.

nopriv : As name suggests there is no private regions all disk space is used for allocating subdisks. This is simplest disk type consisting space only for subdisks. These are most useful in defining RAM Disks etc on which private region data is not persistent across reboots.

These kind of disks does not store any configuration data or log copies and useful in encapsulating disks where no need of private regions.


Simple: Public and Private regions on the same disk area.

cdsdisk :This is mostly used disk access types also known as Cross-platform Data Sharing (CDS) which is suitable for moving disks between different operating systems.

This is default format for disks which is not used to boot the system. These disks format is not suitable for boot, root or swap disks or mirror disk or hot-relocation spares of such disks. vxcdsconvert command line utility can be used to convert disks to cds format.


VxVM Disk Group Configuration Backup Directory

VxVM takes backup of disk group configurations automatically every time disk group configurations changes happens under /etc/vx/cbr/bk.

This directory is really helpful in restoring disk group in case of issue from known good configuration almost same like Windows Desktop Last Known configuration restore to restore your desktop or laptop from previous good configurations.


VxVM Diagnostic Tools Directory

Another very important troubleshooting related stuff directory under Veritas Volume Manager is /etc/vx/diag.d which is linked to /usr/lib/vxvm/diag.d and it contains amazing tools for disk group recovery .

# ls /etc/vx/diag.d/
kmsgdump  vxalua   vxcheckconn  vxcvmdump  vxdmppr vxesd_post_event
vxmemlogserv vxscsimod verifydco  vxasldebug          vxcheckhbaapi
vxdmpalias vxdmptur      vxfmrmap          vxmemtrace   vxtestioctl 
verify_dco_header  vxaslkey vxcheckima  vxdmpattr       vxdrlmapinc    
vxfmrshowmap vxprivutil    vxverify vvr vxautoconfig    vxcodb
vxdmpdbprint  vxdskchk  vxiotimeout vxr5logutil vxwwnluid vvrcheck  
vxcachestatdiag  vxconfigdump vxdmpdd vxdump_sector vxkprint vxscsi 
vxadminiodiag vxcheckasl vxcvmdiag vxdmpdump vxecopyutil vxmediadisc
# ls /usr/lib/vxvm/diag.d
kmsgdump vxalua vxcheckconn vxcvmdump vxdmppr vxesd_post_event 
vxmemlogserv vxscsimod verifydco vxasldebug vxcheckhbaapi
vxdmpalias vxdmptur vxfmrmap vxmemtrace vxtestioctl verify_dco_header
vxaslkey vxcheckima vxdmpattr vxdrlmapinc vxfmrshowmap vxprivutil
vxverify vvr vxautoconfig vxcodb vxdmpdbprint  vxdskchk vxiotimeout 
vxr5logutil vxwwnluid vvrcheck vxcachestatdiag  vxconfigdump vxdmpdd
vxdump_sector vxkprint vxscsi vxadminiodiag vxcheckasl vxcvmdiag 
vxdmpdump vxecopyutil vxmediadisc vxscsiinq

All above tools is really helpful tools for troubleshooting disks and disk group issues. We are going to see tools related to management of private regions of disks.


Best tools for reading the Private Region of disk is vxdisk list.

# vxdisk list tagmastore-usp0_0129
Device:    tagmastore-usp0_0129
devicetag: tagmastore-usp0_0129
type:      auto
disk:      name= id=1603711955.13.server1
group:     name= id=1603712110.15. server1
info:      format=cdsdisk,privoffset=256,pubslice=3,privslice=3
flags:     online ready private autoconfig
pubpaths:  block=/dev/vx/dmp/tagmastore-usp0_0129s3 char=/dev/vx/rdmp/tagmastore-usp0_0129s3
guid:      {f18d4b1c-177e-11eb-aba4-cc45bb5e1897}
udid:      HITACHI%5FOPEN-V%5F0775B%5F0129
site:      -
version:   3.1
iosize:    min=512 (bytes) max=1024 (blocks)
public:    slice=3 offset=65792 len=6217472 disk_offset=0
private:   slice=3 offset=256 len=65536 disk_offset=0
update:    time=1603712421 seqno=0.17
ssb:       actual_seqno=0.0
headers:   0 240
configs:   count=1 len=51360
logs:      count=1 len=4096
Defined regions:
config   priv 000048-000239[000192]: copy=01 offset=000000 enabled
config   priv 000256-051423[051168]: copy=01 offset=000192 enabled
log      priv 051424-055519[004096]: copy=01 offset=000000 enabled
lockrgn  priv 055520-055663[000144]: part=00 offset=000000
Multipathing information:
numpaths:   2
sdh             state=enabled
sda             state=enabled

We have diagnostic tool vxprivutil which is especially designed to manage private region of the disks in disk groups. vxprivutil command have various options like scan, list, dumplog, dumpconfig and set options.

vxprivutil options
scan : It prints private region header.
list : It prints private region header and table of contents.
dumplog : This prints on-disk kernel log.
dumpconfig : This prints on-disk configuration database.
set : It is used to change disk attributes, such as dgname , hostid , diskid
dgid , and flags etc.

Let us see few examples of it’s usages. Lets see scan option.

Linux Red Hat

# /etc/vx/diag.d/vxprivutil scan /dev/vx/dmp/tagmastore-usp0_0129
diskid:  1603711955.13.server1
group:   name= id=1603712110.15.server1
flags:   private noautoimport cds
version: 3.1
iosize:  512
public:  slice=3 offset=65792 len=6217472
private: slice=3 offset=256 len=65536
update:  time=1603712421  seqno=0.17
ssb:     actual_seqno=0.0
headers: 0 240
configs: count=1 len=51360
logs:    count=1 len=4096

Lets see dumpconfig option. This option is helpful in validating available configuration backup before restoring disk group configurations.

#/etc/vx/diag.d/vxprivutil dumpconfig /dev/vx/dmp/tagmastore-usp0_0129 
> /var/tmp/tagmastore-usp0_0129.cfgrec
# cat /var/tmp/tagmastore-usp0_0129.cfgrec |vxprint -D - -ht
Disk group: newdg
dg newdg        default      default  19000   1603712110.15.server1
dm testdisk01   -            -        -        -        -

Lets see dumplog in kernel as mentioned above.

Linux Red Hat

#/etc/vx/diag.d/vxprivutil dumplog /dev/vx/dmp/tagmastore-usp0_0129
LOG #01
BLOCK 0: KLOG 0  :   COMMIT tid=0.1029 tid2=0.1031

Let us understand this whole exercise by use of these restore tools. For example you are importing disk group and getting error like below.

# vxdg -Cf import oradg
VxVM vxdg ERROR V-5-1-10978 Disk group oradg: import failed: 
Disk group has no valid configuration copies.

How to fix Disk Group Has no valid configuration copies

Please verified private region contained a valid configuration copy using vxprivutil tool.

#/etc/vx/diag.d/vxprivutil dumpconfig /dev/vx/dmp/tagmastore-usp0_0129

This happens due to bug with udid. You can refer veritas doc:303722.So we need to rebuilt disk group configuration and import disk group with the help of available config.

#/etc/vx/diag.d/vxprivutil dumpconfig /dev/vx/dmp/tagmastore-usp0_0129
|vxprint -D - -mvphsr > /var/tmp/tagmastore-usp0_0129.out
#vxdisk -f init tagmastore-usp0_0129 privoffset=<> privlen=<> puboffset=<> publen=<>
#vxdg init <dg> <dmname>=<device>
#vxdg -g <dg> adddisk dmnaem=<device>
#vxmake -g <dg> -d /var/tmp/tagmastore-usp0_0129.out

That’s it about what is the configuration file to store private region disk information in Veritas Volume Manager. I hope you will find this information really handy to restore private region information and using those information will enable you to restore your disk group.


In case of any new idea related to the topic please do not hesitate to share in comment section for improving reading quality of related information which will definitely add value to our readers and please share as much as you can for making sure it will reach to intended user to get benefited with shared information.

Other Similar Topics may be of your interest.

How to Increase File System in VXVM

Extend VxFS in Solaris

How to check disk size in VxVM