Operating System - HP-UX
1829589 Members
8023 Online
109992 Solutions
New Discussion

Re: Add a new vg in cluster

 
ani007
Super Advisor

Add a new vg in cluster

Hi,
Could you please check the below procedure & let me know whether i need to modify anything.

suppose I have 2 node cluster.Hp-UX version 11.23.MCSG is up & running.

NodeA
suppose i have created a vg named vgdata. & mount it with data.Then copy the map file from NodeA to NodeB.In nodeB I have import the map file with the same minir no.& created the vgdata.

NodeA
unmount /data
vgchange -a n /dev/vgdata
vgchange -c y /dev/vgdata
vgchange -a e /dev/vgdata
mount /data


#vi /etc/cmcluster/cmclconf.ascii
(VOLUME_GROUP /dev/vgdata)

#vi /etc/cmcluster/pkgA/pkgA.cntl

(Add the VG, LVOL and mount points to the package control script that
controls the new VG.)

Now I have to copy this cmclconf.ascii & pkgA.cntl file to NodeB.

After that what else I have to do ..

Regards,
Ani






14 REPLIES 14
Manix
Honored Contributor

Re: Add a new vg in cluster

If you have imported the VG on the other node
& VG`s are visible from each node ..once at a time for sure ( -a e )

You have did the changes in cluster.conf file
& package.cntrl file & script then you are ready to apply the binary configurations on the nodes for 1 ) cluster 2 ) package

cmcheckconf -C /etc/cmcluster/conf.ascii

cmapplyconf -C /etc/cmcluster/conf.ascii


cmcheckconf -v -P $dir/pkg1.conf
cmapplyconf -v -P $dir/pkg1.conf

Hope this help.

Thanks & Regards

Manix
HP-UX been always lovable - Mani Kalra
ani007
Super Advisor

Re: Add a new vg in cluster


HI,
Thanks for the reply.I have some question ..please let me know how many files I have to modify?
a.cmclconf.ascii
b.pkg.cntl
c.??
d.??

If you go through the follwoing thread
http://h30499.www3.hp.com/t5/Serviceguard/MCSG-Adding-a-Package-to-a-Running-Cluster/m-p/4432269#M16744


here Mr.Sujit Kumar Sing clearly mention in his 1st reply that ""So in case you have the VGs made cluser aware using vgchange -c y you need not put those entries in the cluster.ascii file."""

So my question is it require to add the new VG entry in cmclconf.ascii & do the following ?

cmcheckconf -C /etc/cmcluster/conf.ascii
cmapplyconf -C /etc/cmcluster/conf.ascii

Regards,
Ani

Manix
Honored Contributor

Re: Add a new vg in cluster

yes !! you are correct the VG entries are in

1 ) cluster.conf.ascii file

2 ) package.cntrl.script

so cmcheckconf /applyconf will do.

package VG can be manually activated & lvol can be mounted without even restart.

Thanks

Manix
HP-UX been always lovable - Mani Kalra
ani007
Super Advisor

Re: Add a new vg in cluster

sorry it's not clear to me.... just give me the steps ...whatever I mention in my 1st post is there anything else i hv to do?

2.I dont think i hv to do vi /etc/cmcluster/cmclconf.ascii as i hv already did vgchange -c y /dev/vgdata

Manix
Honored Contributor

Re: Add a new vg in cluster

On node1:

vgchange -a n vg_shared

# vgexport -p -s -m /tmp/vg_shared.map /dev/vg_shared

3.# scp /tmp/vg_shared.map node2:/tmp/

Going to node2:
5.
# ls /dev/vg_shared/group - note minor number (0x020000 for example)
# vgexport vg_shared

6.
# mkdir /dev/vg_shared
# mknod /dev/vg_shared/group c 64 0x020000 (same minor here)

7.
# vgimport -v -s -m /tmp/vg_shared.map /tmp/vg_shared

vi cluster.conf.ascii file


List of cluster aware LVM Volume Groups. These volume groups will
# be used by package applications via the vgchange -a e command.
# Neither CVM or VxVM Disk Groups should be used here.
# For example:
# VOLUME_GROUP /dev/vgdatabase
# VOLUME_GROUP /dev/vg02
VOLUME_GROUP /dev/vg0_shared.


vi $dir/package.cntrl.scritp

#VOLUME GROUPS
VG(0)=/dev/vg_shared
#FILESYSTEMS
LV(0)=/dev/vg_shared/lvol1
FS(0)=/tmp/mount1

now ..every thing is set ..

cmcheckconf & cmapplyconf will do !!

HP-UX been always lovable - Mani Kalra
ani007
Super Advisor

Re: Add a new vg in cluster

now ..every thing is set ..

cmcheckconf & cmapplyconf will do !!

you mean I have to fire the following right
#cmcheckconf -C /etc/cmcluster/conf.ascii
#cmapplyconf -C /etc/cmcluster/conf.ascii
#cmcheckconf -v -P $dir/pkg1.conf
#cmapplyconf -v -P $dir/pkg1.conf


So as you are making entry in cluster.ascii file so no need to do the follwoing right?

unmount /data
vgchange -a n /dev/vgdata
vgchange -c y /dev/vgdata
vgchange -a e /dev/vgdata
mount /data


Manix
Honored Contributor

Re: Add a new vg in cluster

reply

vgchange -c y & vgchange -a e
will be done automatically by cluster startup
as stated in cluster.conf.ascii file (below)

no other command is needed apart from

1 ) vgchange -a n vgname
2 )cmcheckconf -C /etc/cmcluster/conf.ascii
3 )cmapplyconf -C /etc/cmcluster/conf.ascii


# List of cluster aware LVM Volume Groups. These volume groups will be used by package applications via the vgchange -a e command.
# Neither CVM or VxVM Disk Groups should be used here.
# For example:
# VOLUME_GROUP /dev/vgdatabase
VOLUME_GROUP /dev/vg02
VOLUME_GROUP /dev/vg_shared
HP-UX been always lovable - Mani Kalra
ani007
Super Advisor

Re: Add a new vg in cluster

no other command is needed apart from

1 ) vgchange -a n vgname
2 )cmcheckconf -C /etc/cmcluster/conf.ascii
3 )cmapplyconf -C /etc/cmcluster/conf.ascii

the follwoing command is also reqire also right?

#cmcheckconf -v -P $dir/pkg1.conf
#cmapplyconf -v -P $dir/pkg1.conf
Manix
Honored Contributor

Re: Add a new vg in cluster

No Anil !!

As i said only 3 commands ..no changes to
package.conf.ascii file so not needed to apply
a new package configurations.

Only three commands as i mentioned.

Thanks

Manix
HP-UX been always lovable - Mani Kalra
ani007
Super Advisor

Re: Add a new vg in cluster

Hi,
I have to modify cluster.conf.ascii & pkg.cntl file to Node1 right.
cmcheckconf & cmapplyconf also should be fire from the Node1.

The cmapplyconf will automatically distribute the custer.conf.ascii file to node2. SO i need to copy only the pkg.cntl file to node2 right?
Benoy Daniel
Trusted Contributor

Re: Add a new vg in cluster

In lastest SG versions, you dont need to specify VG name in the cluster ascii file. Its is needed only in package control file.

You only need to copy the package control file to node B.
Manix
Honored Contributor

Re: Add a new vg in cluster

Hello Anil,

You are correct only control.script needs to be copied rest has been already done.

Thnaks

Manix
HP-UX been always lovable - Mani Kalra
P Arumugavel
Respected Contributor

Re: Add a new vg in cluster

Hi Anil,

Steps to add a Volume Group to a Package

node1# pvcreate [ -f ] /dev/disk/new_disk1
node1# pvcreate [ -f ] /dev/disk/new_disk2
node1# mkdir /dev/vg_new
node1# mknod /dev/vg_new/group c 64 0x140000
node1# vgcreate vg_new /dev/disk/new_disk1 /dev/disk/new_disk2
node1# vgexport -v -p -s -m /tmp/vg_new.map vg_new
node2# rcp node1:/tmp/vg_new.map /tmp/.
node2# mkdir /dev/vg_new
node2# mknod /dev/vg_new/group c 64 0x140000
node2# vgimport -N -v -s -m /tmp/vg_new.map vg_new
node1# vgchange -c y vg_new
node1# vgchange -a n
node1# cmhaltpkg pkg_name

Modify the control scripts on both systems to insure this new vg is activated when the package starts and to insure all new filesystems in this nre volume group are mounted.
node1# cmrunpkg -v pkg_name
node1# cmmodpkg -v -e pkg_name

Rgda...
ani007
Super Advisor

Re: Add a new vg in cluster

Thank you all. sorry for delay.