HPE Community read-only access December 15, 2018
This is a maintenance upgrade. You will be able to read articles and posts, but not post or reply.
Hours:
Dec 15, 4:00 am to 10:00 am UTC
Dec 14, 10:00 pm CST to Dec 15, 4:00 am CST
Dec 14, 8:00 pm PST to Dec 15, 2:00 am PST
System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

/etc/lvmtab differences in a MC SG cluster

 
SOLVED
Go to solution
Marco Shaw_1
Respected Contributor

/etc/lvmtab differences in a MC SG cluster

I had done some work to increase the size of a LV. That included adding another physical disk. It appears I missed a step or 2.

This is a 2-node MC SG cluster.

I recently tried to failover to the passive node, but the failover fails.

When I run this on both: strings /etc/lvmtab, I get 3 devices on the active, but only 2 on the passive. The disk I added is not showing on the passive.

What do I need to do to fix this?

A vgexport -m from the active, and vgimport -m from the passive? Can I do this somehow without having to umount the FS or some other service affecting set of commands?
15 REPLIES
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Yes, you could do a vgexport in preview mode in active mode and do a vgexport/mkdir/mknod/vgimport on the passive node where only two disk are visible in /etc/lvmtab

This will not affect any services

NOTE: The three disks you are taking about should be CLAIMED.
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

#vgexport â p â s â m /tmp/vgXX.map /dev/vgXX
Copy the file to passive server, and login into it
# vgexport /dev/vgXX
# mkdir /dev/vgXX
# mknod /dev/vgXX/group c 64 0x0X0000
>> Same minor number (0x0X0000)
# vgimport â s â m /tmp/vgXX.map vgXX
# strings /etc/lvmtab

NOTE: Passive server is presently not having the package(belonging to the above VG) running
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Avinash20
Honored Contributor
Solution

Re: /etc/lvmtab differences in a MC SG cluster

Dont know why its not viewable
Active node:
# vgexport -p -s -m /tmp/vgXX.map /dev/vgXX
Copy the file /tmp/vgXX.map to passive server, and login into it
# vgexport /dev/vgXX
# mkdir /dev/vgXX
# mknod /dev/vgXX/group c 64 0x0X0000
>> Same minor number (0x0X0000)
# vgimport -s -m /tmp/vgXX.map vgXX
# strings /etc/lvmtab
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Marco Shaw_1
Respected Contributor

Re: /etc/lvmtab differences in a MC SG cluster

This is what I'm returned with the flags "-p -s -m":
vgexport: Volume group "/dev/vg_foo" is still active.

Is there a way to do this without taking the FS offline?
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Thats correct..
now the map file has been created

You have to copy that to the other node
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Since the vg is active, we are running vgexport in preview mode, to get the list VGID and LVM information.

For getting this information, we dont have to deactivate the VG.

Now once the map file is created, just import it to the other node.

No downtime is required
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Marco Shaw_1
Respected Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Oh, OK, the message is just a warning. The file is still created.

I get this on the passive node:
vgimport: Volume group "/dev/vg_foo" already exists in the "/etc/lvmtab" file.

Yes, the VG is already in lvmtab, but now, there's an extra device that needs to be added.

Can vgimport be forced? I don't see a flag for it.
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

# vgexport /dev/vgXX
# mkdir /dev/vgXX
# mknod /dev/vgXX/group c 64 0x0X0000
>> Same minor number (0x0X0000) as that on the other node
# vgimport -s -m /tmp/vgXX.map vgXX
# strings /etc/lvmtab
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Marco Shaw_1
Respected Contributor

Re: /etc/lvmtab differences in a MC SG cluster

But I'm getting an error about a VG already existing...
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Please execute vgexport first

We need to remove the vg from lvmtab and again add it
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

On Passive node

# vgexport /dev/vg_foo
# mkdir /dev/vg_foo
# mknod /dev/vg_foo/group c 64 0x0X0000
>> "0x0X0000" This is a minor number and should be same as that on the other node
You could find the minor on active node via
ll /dev/vg_foo/group
check for value 0x0X0000 << Here X is a numeric value
# vgimport -s -m /tmp/vgXX.map vgXX
# strings /etc/lvmtab
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Hi Mate,

Did you forget to assign points to this post :)
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Hi Marco,

Are you still facing some other issue.
If not, please assign the point.
"Light travels faster than sound. That's why some people appear bright until you hear them speak."
Marco Shaw_1
Respected Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Sorry, I was busy. I need to research this:

root@[foo]/etc> vgimport -s -m /tmp/vg_bar.map vg_bar
Warning: Logical Volume number "7" found on physical volume not found in "/tmp/vg_bar.map".

LVOL7 exists on the active node currently and is valid.

strings /etc/lvmtab is giving me one extra disk for vg_bar which I'll also need to research.
Avinash20
Honored Contributor

Re: /etc/lvmtab differences in a MC SG cluster

Hi,

Check
# strings /tmp/vg_bar.map

Check if this contains lvol7
Compare /tmp/vg_bar.map on both the nodes
"Light travels faster than sound. That's why some people appear bright until you hear them speak."