Operating System - HP-UX
1753828 Members
8727 Online
108805 Solutions
New Discussion юеВ

Re: How to create a PVG when LVG with data exists

 
marlon_4
Occasional Advisor

How to create a PVG when LVG with data exists

Hi, can anyone help me with the following:

I have a vg00 with 2 disks. Some of the lv's are striped. I want to mirror the vg on 2 other disks. I got the suggestion that I should create a PVG, and mirror it to another PVG because the data is striped.

My question is: how do I make a PVG if the 2 pv's are already in vg00 and have data on them?


Thanx in advance,


Marlon
9 REPLIES 9
Leif Halvarsson_2
Honored Contributor

Re: How to create a PVG when LVG with data exists

Hi,

Not sure if I understand you correct. You can (of course) not creating a new volumegroup of two disks, already belonging to another volumegroup without removing the disks (and, destroying the data) from the first group (vg00 in your case).
RAC_1
Honored Contributor

Re: How to create a PVG when LVG with data exists

How did you strip it?? what is the lvol policy?? If you stripped with lvcreate -i and -I options, you can not mirror.
There is no substitute to HARDWORK
marlon_4
Occasional Advisor

Re: How to create a PVG when LVG with data exists

This is the config of one of the lvol's:


LV Name /dev/vg00/lvol10
VG Name /dev/vg00
LV Permission read/write
LV Status available/syncd
Mirror copies 0
Consistency Recovery MWC
Schedule striped
LV Size (Mbytes) 8000
Current LE 2000
Allocated PE 2000
Stripes 2
Stripe Size (Kbytes) 8
Bad block on
Allocation strict
IO Timeout (Seconds) default

As you can this on is striped. How can I make a physical volume group of the two disk in this LVG?
RAC_1
Honored Contributor

Re: How to create a PVG when LVG with data exists

you have strippped lvol onto two disks. You can not mirror it now. Also whay you want to make pvg??
There is no substitute to HARDWORK
Luk Vandenbussche
Honored Contributor

Re: How to create a PVG when LVG with data exists

I you have striped volumes you have PVG yet.

You you send / check the output of /etc/lvmpvg and / or vgdisplay -v vg00
James R. Ferguson
Acclaimed Contributor

Re: How to create a PVG when LVG with data exists

Hi Marlon:

You cannot mirror stiped logical volumes. Physical Volume Groups (PVG) and mirrored logical volumes are associated with the concept of "distributed allocation".

See the manpages for 'vgcreate', 'lvcreate' and 'lvmpvg(4)' for more information. Note, in passing, that an /etc/lvmpvg file can be made before or after a volume group is established when applicable.

In my opinion, vg00 is based housed on one physical disk with a second disk implemented as a bootable mirror. You might want to consider using Ignite to reconfigure vg00 this way.

Regards!

...JRF...
SGUX
Valued Contributor

Re: How to create a PVG when LVG with data exists

pvg's are easy to create, also when the VG allready exists. (see: man lvmpvg)
Mirroring a striped LV which allready exists is not possible. You can do this when creating the lv using the EXTEND-BASED MIRRORED STRIPES (see: man lvcreate) although i agree with James that you could/should consider setting up the vg00 again and possible create a new vg for the non-OS lv's that are in vg00 now. striping used within vg00 is not very common i guess but is used for large data lv's.
marlon_4
Occasional Advisor

Re: How to create a PVG when LVG with data exists

Thanx to all of you for your reccomendations. As I thought, I will have to recreate vg00 using ignite.

- Make an ignite tape
- revover it onto the free disks
- reboot using the new disks
- recover onto the olddisks
- reboot

That should do the trick for me :)

Thanx again
marlon_4
Occasional Advisor

Re: How to create a PVG when LVG with data exists

As I thought, I will have to recreate vg00 using ignite.

- Make an ignite tape
- revover it onto the free disks
- reboot using the new disks
- recover onto the olddisks
- reboot


Thanx