1748163 Members
3803 Online
108758 Solutions
New Discussion юеВ

Changing PE size?

 
SOLVED
Go to solution
Kenneth Platz
Esteemed Contributor

Changing PE size?

Is it possible to change the PE size on an existing volume group? We made the unfortunate mistake of failing to specify the PE size on one of our volume groups when we created it, and now we are unable to extend a logical volume beyond 256GB (65535 * 4). The only other option we have is to perform a full backup on the data, export the VG, and re-create the VG with a new PE size, and of course we'd rather not do that if we can avoid it.

Thanks in advance
I think, therefore I am... I think!
10 REPLIES 10
Cesare Salvioni
Trusted Contributor
Solution

Re: Changing PE size?

hi
very very sorry: no way !!!!

PE size is one of the few parameter you MUST decide when you create the VG.
Changing this parameter means to destroy the vg and recreate it.
Be carefull and think about also the parameters:
MAX PE per PV
MAX PV
MAX LV
above all the first one which, with the PE size, limits the maximum disk size you can handle inside a created vg

hope it helps
twang
Honored Contributor

Re: Changing PE size?

├п┬╝┬┤he PE size ├п┬╜ ├п┬╜ ├г ├п┬╜ ├г ├п┬╝┬╢├п┬╝┬з├г can not be chan
Slawomir Gora
Honored Contributor

Re: Changing PE size?

Hi,

you can change PE size only during creating
new vg. The only way is:
1. backup
2. remove vg
3. create new vg with new PE size
4. restore



twang
Honored Contributor

Re: Changing PE size?

The PE size of a VG can not be changed without recreating it.
Sorry for above reply.
Rita C Workman
Honored Contributor

Re: Changing PE size?

Using a tip that JRF passed on, I have found it handy, provided you have available diskspace, to do:

create a new vg with the right settings
create dummy filesystem/mountpoints
...(I like x-oldmountpointname)

Now leave both of these mounted up and
do a simply use fbackup/frecover to copy your data. I tend to do this last part when I can take things down, so everything is clean..

cd /oldmountpoint
# fbackup -i . -f - | (cd /x-mountpoint; frecover -Xsrf -)

Rgrds,
Rita

Kenneth Platz
Esteemed Contributor

Re: Changing PE size?

Well, I was afraid you were going to say that, but you never know. Sometime someone has a very 'clever' way of getting around those limitations...
I think, therefore I am... I think!
Kenneth Platz
Esteemed Contributor

Re: Changing PE size?

Rita, that's a great idea, but unfortunately we don't have the free disks available to do it. It looks like we're just going to have to take an outage to do this. Thanks everyone.
I think, therefore I am... I think!
Gerhard Roets
Esteemed Contributor

Re: Changing PE size?

Hi Kenneth

Rebuilding the VG is the only way. Also keep an eye on the value for MAX PE per PV as this might come back later on as a new issue.

The default MAX PE per PV size is double the number of PE's on your largest disk in that specific volume group.

HTH
g3jza
Esteemed Contributor

Re: Changing PE size?

Hi,

I don't want to start a new thread so I'd like to ask here:

I would like to re-create volume group so I can change the current value of PE Size(4MB) to higher value(16MB). Does the recreation of volume group corrupt data? The only reason I want to do this is that I need to extend some mounts

I've read a lot about this and found out something about vgexport command.
These are my steps I'd like to do in order to achieve higher value of PE Size:

1. umount all mounts using vg01
2. vgchange -a n /dev/vg01
3. vgexport /dev/vg01

4. mkdir /dev/vg01
5. mknod /dev/vg01/group c 64 0x010000

6. pvcreate -f /dev/c0t5d0
7. vgcreate -s 16 /dev/vg01 /dev/dsk/c0t5d0
8. recreate all logical volumes and mount them back.

On my testing system, I actually found out that it worked since all of the data in remounted LV's was there and readable.
Is this not going to corrupt any data?
Offcourse I should consider to backup all of the data first...

Thank you for your opinions