Operating System - HP-UX
1826631 Members
3418 Online
109695 Solutions
New Discussion

Increasing lvol size of the root, boot, etc

 
Walker_3
Frequent Advisor

Increasing lvol size of the root, boot, etc

Hi all,

I need to to increase lovol size of the root, boot, usr, tmp and home. How can I do this without any hassle?
16 REPLIES 16
Muthukumar_5
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

Try as,

Increase the size of a file system existing on a logical volume.

First, increase the size of the logical volume.

lvextend -L 400 /dev/vg06/lvol3

Unmount the file system.

umount /dev/vg06/lvol3

Extend the file system to occupy the entire (larger) logical volume.

extendfs /dev/vg06/rlvol3

Remount the file system.

mount /dev/vg06/lvol3 /mnt

hth.
Easy to suggest when don't know about the problem!
Arunvijai_4
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

Do you have Online JFS installed ? If yes, you can do it on the fly with SAM.
If not,
1) lvextend -L
2) umount
3) extendfs
4) mount

/tmp and /home can be done without booting into single user mode. Others do require a reboot into Single user mode ISL> hpux -iS

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
RAC_1
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

For increasing lvols - /stand, swap and root, it is difficult. You will have to use ignite tape and rebuild system with required sizes.

For other, if you have OnlineJFS installed, this can be done online.

lvextend -L "new_sizein_MB" /dev/vgxx/lvol
fsadm -b "size_in_mb" /mount_point

If you do not have OnlineJFS, then unmount, lvextend and fsadm
There is no substitute to HARDWORK
Muthukumar_5
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

You can sam as well as lvextend to do this job. How ever, It is not possible do to /root /stand directly.

Good Manual for reference:

http://docs.hp.com/en/5990-8172/ch09s01.html
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=104718
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=19353

hth.
Easy to suggest when don't know about the problem!
Arunvijai_4
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

http://docs.hp.com/en/B7961-90025/ch08s15.html
[Resizing a Volume]

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=825170

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
MarkSyder
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

I hate to copy answers - it makes it look as though I'm point-hunting - but you've been given so many incorrect answers I think it's important to confirm what RAC said: you need to use an ignite backup to increase these filesystems.

Mark Syder (like the drink but spelt different)
The triumph of evil requires only that good men do nothing
Joseph Loo
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

hi,

maybe there is a reason for doing so.

look at this, he close this thread without even assigning points:

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=962442

hmmm....;)

regards.
what you do not see does not mean you should not believe
MarkSyder
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

Joseph: are you seriously suggesting that people are deliberately giving wrong answers because he closed a thread without giving points? I hope you're wrong!

I think people have made a genuine mistake and don't realize he needs to use ignite. In my opinion, deliberately giving a wrong answer is worse than not assigning points.

Mark
The triumph of evil requires only that good men do nothing
Muthukumar_5
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

Mark,

Did you look at his question:
Please suggest me which Kernel parameters should be modified to which value to get rid of this error.

I think it is related with nfile kernel parameter correct. I hope he forgot to assign points since he is a 3 days older member to this forum ;) check his profile. He will do it soon.

PS> Assign 0 points for this post

thx.



Easy to suggest when don't know about the problem!
MarkSyder
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

Muthu,

No, I've hardly looked at that thread. The point I'm making is that I don't believe people have deliberately given a wrong answer on THIS thread because he didn't give points on THAT thread, which is what Joseph seemed to be suggesting. I really don't believe people on this forum would do that.

I hope I'm right ;-)

Mark
The triumph of evil requires only that good men do nothing
Morcos
Super Advisor

Re: Increasing lvol size of the root, boot, etc

From what I know if you want to increase the root you can do it by decreasing the size of swap, then go to maintenance mode to increase the root but this method is not recommended and the best method is doing ignite as said RAC and Mark, Also for boot ignite is the solution.
For the other filesystem you can do lvextend and after extendfs.

HTH,
Ziad
Howard Marshall
Regular Advisor

Re: Increasing lvol size of the root, boot, etc

You can do it, even without ignite, but I assure you its not a pretty sight.

The boot, swap, and root logical volumes, because of the way they are handled at boot up, have some specific requirements. They must occur in a specific order, they must not relocate bad blocks, and most important for this project, they must be contiguous.

So, the boot lv, mounted on /stand has to be first, and its likely that the next lv, usually swap, starts right where lvol1 ends. That means lvol1 can't grow contiguously without you moving the next lvol to somewhere else to get it out of the way. Then because the swap volume also has to be contiguous you will have to move anything thatâ s it the way of putting it back, and so forth.

Just so you know, this all has to be done while the system is down, you know, just to make things more complicated.

All in all, ignite is probably the lowest headache inducing of the processes but you may very well be a lvm expert by the time your done if you do it the other way.

another option that you may have to releave some space issues in the / file system is to create a new lv and file system and mount it to the directory that is filling up the file system.

Howard
Marvin Strong
Honored Contributor

Re: Increasing lvol size of the root, boot, etc

Well with onlineJFS, and if you have 2 disks in VG00 you can extend all of these on the fly.
even / though it needs to be contiguous

Since the other posts tell you how to extend the normal filesystems with lvextend and fsadm.

I will cover how I have extended / on the fly.

It is important to make sure that the logical volumes be moved in the correct order. If you move them in numeric order you should be ok.

1) Break the mirror of your root drives.
2) ensure that the second disk is properly bootable, or you will have problems when you reboot.
mkboot -a "hpux -lq" /dev/rdsk/c?t?d?
3) using the pvmove command move the logical volumes to the new disk.
pvmove /dev/vg00/lvol1 /dev/dsk/c?t?d?
lvextend -L xx /dev/vg00/lvol1
umount /stand
extendfs -F hfs /dev/vg00/rlvol1
4) pvmove /dev/vg00/lvol2 /dev/dsk/c?t?d?
lvol2 is swap and I wouldn't recommend extending swap just add a new swap device.
5) pvmove /dev/vg00/lvol3 /dev/dsk/c?t?d?
lvextend -L xx /dev/vg00/lvol3
fsadm -F vxfs -b $(( xx * 1024)) /

note: if you don't have OnlineJFS you have to do the fsadm in single user mode. However you can still lvextend the logical volume here.

6) continue with pvmove the rest of the logical volumes.

After you have pvmoved all the logical volumes reestablish your mirrors.

Granted this is an involved process but I have done it a few times, and even walked someone through it over the phone once.
Walker_3
Frequent Advisor

Re: Increasing lvol size of the root, boot, etc

Hi Guys,
I don't bother what you are talking about. I need solution.

I have JFS installed and I have taken ignite make_tape_recovery backup. Any way can anyone provide me the documents for increasing root, boot using make_tape?
Morcos
Super Advisor

Re: Increasing lvol size of the root, boot, etc

Hi,
First do make_tape_recovery to get the volume group vg00.Then reboot your server and on PDC type the command sea, then choose to boot from tape: choose [ Install HP-UX ], then [ * ]Advanced Installation, from the next screen,"Basic" make sure that the [Root disk..] corresponds to the right path. Go with tab to "File System" and here change the size as needed.

Also if you want you can keep your disk, and put a new bigger one and do the above procedure(it's my recommendation).
Walker_3
Frequent Advisor

Re: Increasing lvol size of the root, boot, etc

Its ok.