Operating System - HP-UX
1827459 Members
4004 Online
109965 Solutions
New Discussion

Re: How to change group number on SG cluster device

 
SOLVED
Go to solution
Mike Smith_33
Super Advisor

How to change group number on SG cluster device

Newbie sysadmin that I am, I have added a vg group into my ServiceGuard 11.16 on HPUX 11.11 cluster. This now prevents me from running make_tape_recovery.

I need the steps to safely change the group number. The device that I managed to duplicate was my cluster lock device - vglck.

It is a two node cluster, here is the output
from

prod node

# ll /dev/*/group
crw-r----- 1 root sys 64 0x000000 Jun 29 01:34 /dev/vg00/group
crw-rw-rw- 1 root sys 64 0x010000 Sep 14 05:14 /dev/vg01/group
crw-rw-rw- 1 root sys 64 0x020000 Sep 14 11:25 /dev/vg02/group
crw-rw-rw- 1 root sys 64 0x030000 Sep 14 11:33 /dev/vg03/group
crw-rw-rw- 1 root sys 64 0x040000 Sep 14 11:34 /dev/vg04/group
crw------- 1 root sys 64 0x050000 Oct 14 17:25 /dev/vg05/group
crw-rw-rw- 1 root sys 64 0x050000 Sep 20 14:11 /dev/vglck/group


Here is output from dev node

# ll /dev/*/group
crw-r----- 1 root sys 64 0x000000 Sep 28 12:47 /dev/vg00/group
crw-rw-rw- 1 root sys 64 0x010000 Sep 22 12:19 /dev/vg01/group
crw-rw-rw- 1 root sys 64 0x060000 Sep 22 11:45 /dev/vg01_dev/grp
crw-rw-rw- 1 root sys 64 0x020000 Sep 22 12:26 /dev/vg02/group
crw-rw-rw- 1 root sys 64 0x070000 Sep 22 11:30 /dev/vg02_dev/grp
crw-rw-rw- 1 root sys 64 0x030000 Sep 22 12:27 /dev/vg03/group
crw-rw-rw- 1 root sys 64 0x080000 Sep 22 12:05 /dev/vg03_dev/grp
crw------- 1 root sys 64 0x040000 Nov 2 15:20 /dev/vg04/group
crw------- 1 root sys 64 0x0a0000 Nov 2 14:42 /dev/vg04_dev/grp
crw------- 1 root sys 64 0x050000 Oct 20 16:29 /dev/vg05/group
crw------- 1 root sys 64 0x090000 Oct 20 19:40 /dev/vg05_dev/grp
crw-rw-rw- 1 root sys 64 0x050000 Sep 20 14:16 /dev/vglck/group


I would appreciate some help on this one.
13 REPLIES 13
Luk Vandenbussche
Honored Contributor

Re: How to change group number on SG cluster device

Hi

you have to change the kernel parameter
maxvgs on both nodes.

Then you can create a group file with a higher number then a (hexadecimal) or 10 (decimal)
Mike Smith_33
Super Advisor

Re: How to change group number on SG cluster device

Actually I did that I while back when I added the extra vg devices.
Kent Ostby
Honored Contributor

Re: How to change group number on SG cluster device

Mike --

Were you actually able to add the new vg into lvmtab?

I would think it would have puked with you trying to add a second group with the same group ID .

If all you have done is add the group to /dev/vg05/*, then it can removed, renamed, and then the vg re-imported on both nodes (or if you change an unshared /dev/vg05, it will only need to be changed on the one node).
"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"
Luk Vandenbussche
Honored Contributor

Re: How to change group number on SG cluster device

Can you send the cluster config file?

If vglck contains your cluster lock then i think you can solve it by simply removing vg05 on both nodes

vgexport vg05
Mike Smith_33
Super Advisor

Re: How to change group number on SG cluster device

I agree that I am suprised the whole thing did not croak. One thing I need to add, this is not something I did yesterday, it has been over a month. I have run make_tape_recovery sucessfully since then. It doesn't hang every time, only some times. HP told me I needed to change the minor number for one of them, they apparently assumed I knew how to do this.

Here is my dilemma, vg05 has data and is actively used but the cluster is not in production yet. I would like to save the data so it would seem that changing vglck would be easier to do except since it is the cluster device, I am not sure what the steps are.
Solution

Re: How to change group number on SG cluster device

Actually changing vg05 would be easier as presumably vglck contains the cluster lock disk yes?

You don't need to lose the data - vgexport doesn't delete any data from disks, just removes configuration information from /etc/lvmtab and device files from /dev - just do the following:

On first node:

1) Stop the package that uses vg05 using cmhaltpkg

2) Create a map file for vg05:

vgexport -p -s -m /tmp/vg05.map

3) Get rid of vg05 from lvmtab:

vgexport vg05

4) Re-create vg05:

mkdir /dev/vg05
mknod /dev/vg05/group c 64 0x100000
vgimport -s -m /tmp/vg05.map /dev/vg05

5) Copy /tmp/vg05.map to 2nd node.

On second node, repeat steps 3 and 4.

HTH

Duncan

I am an HPE Employee
Accept or Kudo

Re: How to change group number on SG cluster device

oops - step 2 should of course be:

vgexport -p -s -m /tmp/vg05.map /dev/vg05

HTH

Duncan

I am an HPE Employee
Accept or Kudo
Mike Smith_33
Super Advisor

Re: How to change group number on SG cluster device

In step four, shouldnt the group number be more like 0x0b0000?
Geoff Wild
Honored Contributor

Re: How to change group number on SG cluster device

The group minor can be whatever is available - just as long as it doesn't exist already....

Another tip - I would stick to a vg naming standard - don't name them vg02_dev - stick with numbers - a whole lot less confusing...

That way your group minor numbers will align (in hex) nicely with the vgXX

IE:

vg01 group minor 0x010000
.
.
vg10 group minor 0x0a0000

etc...

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.
Mike Smith_33
Super Advisor

Re: How to change group number on SG cluster device

# vgimport -p -s -m /tmp/vg05.map /dev/vg05
vgimport: Cannot open the control file "/dev/vg05/group":
No such device


I followed the steps as listed.
Geoff Wild
Honored Contributor

Re: How to change group number on SG cluster device

ll /dev/vg05/group

If not there, then you need to mknod it

mkdir /dev/vg05
mknod /dev/vg05/group c 64 0x0b0000


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.
Mike Smith_33
Super Advisor

Re: How to change group number on SG cluster device

Ok, I found the problem. I had only increase maxvgs on the dev node not the prod node. I changed this in the kernel, processed it and rebooted. Everything cool now.
Geoff Wild
Honored Contributor

Re: How to change group number on SG cluster device

Glad you got it...now - as far as maintianing environments on your cluster - talk to your HP Support Rep about CCMON - the tool is free - but it costs you a Technical Services day to have it installed (HP has to install it the first time).

http://h71028.www7.hp.com/enterprise/downloads/ccmon-service-brief.pdf

Basically, it monitors differneces in your cluster - everything from kernel parms, vgs, to individual files that you can specify...

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.