Operating System - HP-UX
1830733 Members
1841 Online
110015 Solutions
New Discussion

How to extend lvol using space from unused lvol

 
SOLVED
Go to solution
Robert Peregrin
Frequent Advisor

How to extend lvol using space from unused lvol

Hi,

I want to extend /dev/vg00/lvol5 using space from /dev/vg00/lvol4 which is unused. vg00 is using only one physical volume which is /dev/dsk/c2t0d0. How should I do it?


Regards,

Robert Peregrin
8 REPLIES 8
sujit kumar singh
Honored Contributor
Solution

Re: How to extend lvol using space from unused lvol

HI Robert,

what is the FS mounted on /dev/vg00/lvol4.
have you online JFS?

if you have free space in VG this straight forward adnd have online JFS
a) lvextend -L

b) fsadm -b



there are various way to do the same.
take a backup of /dev/vg00/lvol4.

if so you have
1)do a defrag on the FS:
fsadm -dD -eE /dev/vg00/lvol4

Reduce the FS:
2) fsadm -b M

if that is successful,

3) lvreduce -L /dev/vg00/lvol4

regards
sujit
sujit kumar singh
Honored Contributor

Re: How to extend lvol using space from unused lvol

HI Robert,

what is the FS mounted on /dev/vg00/lvol5.
have you online JFS?

if you have free space in VG this straight forward adnd have online JFS
a) lvextend -L

b) fsadm -b



there are various way to do the same.
take a backup of /dev/vg00/lvol4.

if so you have
1)do a defrag on the FS:
fsadm -dD -eE /dev/vg00/lvol4

Reduce the FS:
2) fsadm -b M

if that is successful,

3) lvreduce -L /dev/vg00/lvol4

follow this by:

a) lvextend -L

b) fsadm -b



regards
sujit
Robert Peregrin
Frequent Advisor

Re: How to extend lvol using space from unused lvol

Hi,

lvol5 is used for /opt and lvol4 is used for /home.

Do I have to reboot the machine after the changes you suggested?


Regards,

Robert
HP-UX_Ali
Regular Advisor

Re: How to extend lvol using space from unused lvol

Hello Robet,

No reboot is not required, this is all online activity.


Regards,
Ali
Robert Peregrin
Frequent Advisor

Re: How to extend lvol using space from unused lvol

Hi,

One more question. I have VxFS in the 2 logical volumes that I will work with. JFS is equivalent to VxFS in HPUXX right? If yes, then the procedure you provided should apply to the file system I have on the server.


Regards,

Robert

Re: How to extend lvol using space from unused lvol

yes jfs is equivalent to vxfs ,
if you have online jfs then use the folowing

fsadm -b
lvreduce -L

if not then,

umount the FS

use extendfs , go through the man page
lvreduce -L

mount the FS
Robert Peregrin
Frequent Advisor

Re: How to extend lvol using space from unused lvol

Thanks guys. Unfortunately we don't have a license for fsadm. But we found a way to do it using sam.
Robert Peregrin
Frequent Advisor

Re: How to extend lvol using space from unused lvol

We don't have a license for fsadm but we found another way to do it using sam.