lvm

 
Hans Hendriks_1
Frequent Advisor

lvm

Hi All,

We have a 3 node HP7405 cluster, with online jfs.

The problem is that we have 2 volumegroups with the same Major number (on different nodes)
So, we can,t switch that package to the node where the same Major numbers are used.

Is there a way to change the Major number of the volumegroup (online)?


Thx for your response!
7 REPLIES 7
Pete Randall
Outstanding Contributor

Re: lvm

Hans,

You be able to vgexport the VG, then reimport it with a different minor number:

vgexport -s -m /tmp/vg01map /dev/vg01
mkdir /dev/vg01
mknod /dev/vg01/group c64 0x??0000 << ??=minor number
vgimport -s -m /tmp/vg01map /dev/vg01
vgchange -a y /dev/vg01


Pete

Pete
KapilRaj
Honored Contributor

Re: lvm

Hans,
I am no good in cluster but I think u should be talking of changing minor number as major number denotes the class of the device which point to a device driver.

Minor number can be changed by a vgexport / vgimport .. As u have a cluster ,logically u should be able to do it online.. Let's wait for the giants to comment on how to ?

Kaps
Nothing is impossible
Roberto Polli
Trusted Contributor

Re: lvm

Sorry!I've not understood clearly.

You have 2VGs addressed by the same couple on different nodes.
Do you use nfs to export nodes?
Which package do you have to switch?
I don't know any method to do that but the right question can be: "do you _really_ need to do that"?

Peace, R.
Johan Lorimier
Frequent Advisor

Re: lvm

Hi,

You cant do that online. All that you can done is to move the pkg on an other node if as I think, the third node of your cluster is a failover node for the 2 others.
But due to the time taken to switch the package on an other node, il will be faster to follow the steps given by PETE. But in all case, you have to stop the package.

Johan
Robert-Jan Goossens
Honored Contributor

Re: lvm

No you can not do this online.

By the way, the major number is always 64

Note: The major number is always 64, and the hexadecimal minor number has the form 0xhh0000, where hh must be unique to the volume group you are creating. Use the same number as you used on other node.

http://www4.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000068402107

Document description: SG: loading the correct disks into the lvmtab file on the secondary node
Document id: A5843182

You could check above doc for the necessary steps.

Regards,
Robert-Jan
Pete Randall
Outstanding Contributor

Re: lvm

As I originally read the question, the steps I gave you are exactly the answer you need. Judging from your point assignment, I must have misunderstood your question. Could you elaborate just what it is you're asking, please?


Pete

Pete
Geoff Wild
Honored Contributor

Re: lvm

No, there in no way to change the Major number of the volumegroup (online)...

As other have said, you will need to vgexport the vg - on the node that is running the package, create a map file:

vgexport -v -p -s -m /tmp/vgXX.map /dev/vgXX
where XX is the name of your volume group...

On the other node, blow away the vg, then recreate it:

vgexport /dev/vgXX
mkdir /dev/vgXX
mknod /dev/vgXX/group c 64 0xHH0000

XX is the vg name, and HH is the Hex number - make it the same as the /dev/vgXX/group from the node where you created the map file.

Put the map file from the node running the package on the other 2 nodes...then vgimport it:

vgimport -v -s -m /tmp/vgXX.map /dev/vgXX

Rgds...Geoff

Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.