Operating System - HP-UX
1837900 Members
3303 Online
110123 Solutions
New Discussion

Inconsistent values on the lvmtab files

 
Ali Kouider
Occasional Advisor

Inconsistent values on the lvmtab files

Hi
I created the following volume groups using SAM on my new rp7410 production servers.
Then in viewing the etc/lvmtab file using strings I get the following abnormal entries.
/dev/vg01
a?%M#
/dev/dsk/c15t0d5
/dev/vg03
a?%R
/dev/dsk/c15t1d0
/dev/dsk/c16t1d0
/dev/dsk/c5t1d0
/dev/dsk/c9t1d0

When I shutdown the server and start the server , these volumes are not mounted.
A vgdisplay says that they are not there.
When I do a vgchange on these volume groups, it allows me to mount my file systems.

how to fix it
thanks
10 REPLIES 10
Michael Steele_2
Honored Contributor

Re: Inconsistent values on the lvmtab files

Done worry about:

a?%M#, etc.

These is normal.

Try this command and compare :

vgscan -a -v -p (* -p for preview *)

'vgscan' will read every disk for LVM config.

Cross reference with:

vgcfgrestore -f /etc/lvmconf/vg01 -l

This command will also list out disks belonging to its vg.

Any MC/ServiceGuard? Because this is /etc/lvmrc if so.

Support Fatherhood - Stop Family Law
Steven E. Protter
Exalted Contributor

Re: Inconsistent values on the lvmtab files

mv /etc/lvmtab /etc/lvmtab.old
vgscan -v
vgchange -a n vg01
vgchange -a y vg01
strings /etc/lvmtab
vgdisplay -v

If there are invalid volume groups you will have to vgreduce first.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Rajeev  Shukla
Honored Contributor

Re: Inconsistent values on the lvmtab files

Hi
Check your /etc/lvmrc file and i guess
AUTO_VG_ACTIVATE= is set to 0
if its 0 it wont activate the volume groups by itself and you have to manually to it or put the entries in custome_vg_activate if you go more below in this file.

So set it 1 and reboot it should activate the volume group automaticallly and then mount it.

Rajeev
Sunil Sharma_1
Honored Contributor

Re: Inconsistent values on the lvmtab files

Hi,
best way is
mv /etc/lvmatb /etc/lvmtab.old
vgscan -v
vgchange

this will work....
Sunil
*** Dream as if you'll live forever. Live as if you'll die today ***
Rajeev  Shukla
Honored Contributor

Re: Inconsistent values on the lvmtab files

When you do a vgchange and it allows you means that the /etc/lvmtab file is not corrupt its just that the volume group is not getting activated and mind it in MC/SG the /etc/lvmrc file contains AUTO_VG_ACTIVATE=0 so you'll have to define your volume group you want to automatically get activated in custom_vg_activation() function in /etc/lvmrc file.

Rajeev
Massimo Bianchi
Honored Contributor

Re: Inconsistent values on the lvmtab files

Hi,
i think that the problem, as already stated, is in the /etc/lvmrc, ant not in the /etc/lvmtab.


The lvmtab is NOT a text file, it's a binary file.

Some junk may well be present, you can ignore it.

I would not do anything like vgscan, is used not properly can do more damage than benefit.

Second thing: check your /etc/fstab, vg are opened if some of their lvol are present in the fstab for mounting (and AUTOVG_ACTIVATE=1 in /etc/lvmrc).

Massimo
Tim Adamson_1
Honored Contributor

Re: Inconsistent values on the lvmtab files

Hi Ali,

Your ouput shows:

/dev/vg01
a?%M# <<<<<<<<<< This is NORMAL
/dev/dsk/c15t0d5
/dev/vg03
a?%R <<<<<<<<<< This is NORMAL
/dev/dsk/c15t1d0
/dev/dsk/c16t1d0
/dev/dsk/c5t1d0
/dev/dsk/c9t1d0

So they are NOT abnormal entries in lvmtab. The lvmtab file is binary and the strings command will print any sequence of four or more
printing characters ending with a newline or null character. Be assured, the entries are fine.

As for the volume groups not being activated, that could be caused by several things.

Are all the disks available when the server boots so that quorum for the volume group is achieved for activation? Are there any errors in the startup log files?

Is this server part of a Service Guard cluster?


Cheers!!
Yesterday is history, tomorrow is a mystery, today is a gift. That's why it's called the present.
RAC_1
Honored Contributor

Re: Inconsistent values on the lvmtab files

Say file /etc/lvmtab.

This is not normal text/ascii file.

so what you see in it is OK.

Do vgscan -pva, check if you get all pvs.
There is no substitute to HARDWORK
Tim D Fulford
Honored Contributor

Re: Inconsistent values on the lvmtab files

As lots of people have said check /etc/lvmrc for the activation of the volumegroups. The weird ascii characters are normal.

The reason for these weird characters is that the lvmtab file stores the volume groups ID (vgid) whithin it. However it "hides" this information, sometimes this hiding is more successfull than at other times!! you can look at the vgid using "od"

Regards

Tim
-
Sarvesh A Dhuri
Advisor

Re: Inconsistent values on the lvmtab files

Hi
Check the file /etc/lvmtab file using string command as it is a binary file , u can not view it using more or any other command.


check these volumegroups using the command vgdispaly -v /dev/vg01 & vgdispaly -v /dev/vg03

check ioscan output for these disk which are mentioned under the /dev/vg01 & /dev/vg02 in lvmtab file

if they are acessibly then try to use

vgchange -a e /dev/vg01
vgchange -a e /dev/vg03
I have been betrayed by our own People