Operating System - HP-UX
1834916 Members
2366 Online
110071 Solutions
New Discussion

Re: How to extend /usr logical volume?

 
SOLVED
Go to solution
Todd Larchuk
Advisor

How to extend /usr logical volume?

I am trying to install an HP-UX quality pack for 11.0. Swinstall fails and says I need to increase the size for /usr. I tried using SAM but it says I cannot extend the /usr LV because it is in use and cannot be unmounted. I used fuser to see what processes are using /usr, and there are about 20 kernel processes using /usr. I am afraid to kill all those processes. Should I just go ahead and try killing them, or is there a more rational way to extend the /usr LV?
12 REPLIES 12
Christopher McCray_1
Honored Contributor
Solution

Re: How to extend /usr logical volume?

Hello,

Unless you have Online JFS, then your only alternatve is to boot into single-user mode. From there you will perform your lvextend and extendfs.

Hope this helps

Chris
It wasn't me!!!!
Richard Darling
Trusted Contributor

Re: How to extend /usr logical volume?

Pete Randall
Outstanding Contributor

Re: How to extend /usr logical volume?

Hi Todd,

Unless you have Online JFS installed, the only way you're going to be able to do this is to boot into single user mode - you'll never be able to unmount /usr otherwise.

Perhaps a better solution would be to boot from an Ignite recovery tape, re-sizing file systems in the process.

Pete

Pete
Robert-Jan Goossens
Honored Contributor

Re: How to extend /usr logical volume?

Hello,

If you do not have online jfs,

#shutdown -ry 0

While system comes up, disturb the boot sequence and get in to ISL prompt, Then you type this
ISL>hpux -lm

system will come up in the LVM maintenance mode

#vgchange -a y /dev/vg00
#lvextend -L size_in_mb /dev/vg00/lvolxx
#extendfs /dev/vg00/lvolxx
#mount /usr
#cd /usr
#bdf .

If you have online jfs

#cd /
#lvextend -L size_in_mb /dev/vg00/lvolxx
#fsadm -F vxfs -b size_in_mb /usr


Hope it helps,

Robert-Jan
Oleg Zieaev_1
Regular Advisor

Re: How to extend /usr logical volume?

Todd.

You'll have to go single user if you do not have online JFS installed.
If you do have it, use fsadm -F vxfs -b {newsize} /usr
Make sure you've extended lvol first.

From single user, extend lvol and then extendfs. Detailed instruction are hereabove, so no need to repeat.

Hope this helps,
0leg

Professionals will prevail ...
Steve Post
Trusted Contributor

Re: How to extend /usr logical volume?

There are two single-user modes:
1. Run the shutdown command? This does NOT help you.
2. Run it like the people here say. POWER DOWN the computer. Interupt the boot process while it comes back up.

If you boot into single user mode and the /usr filesystem is already mounted, you are in wrong type of single-user. I've never seen this documented. I know this because I was told to extend /usr by WRONG single-user mode method....for months.
Christopher McCray_1
Honored Contributor

Re: How to extend /usr logical volume?

Steve,

I am intrigued by your post, so could you please dig up this reference you are talking about?

every time I boot into single-user mode using shutdown -r , /usr has never been mounted; only / and /stand.

hpux -is is the command I use to boot into single-user mode, what do you use?

Chris
It wasn't me!!!!
Steve Post
Trusted Contributor

Re: How to extend /usr logical volume?

I use "hpux -is" at the boot prompt, just like you.

What I was TOLD years ago was:
"log in as root, in multi-user mode.
Run shutdown
You are now in single user mode.
Now /usr should be unmounted.
If not run umount /usr.
If it still refuses to unmount, run fuser on the logical volume used by /usr to get a list of processes that are still running. Then kill these processes. "

But one of the processes is UNIX. I felt like I was told to stand on a rug, then pull on edge of the rug REAL HARD.
This was a few years ago. And it was NOT a document. It was 3rd party support telling me this,...then HP agreed. All verbally.

Eventually I got an email from hp support that told me how to REALLY bring it into single-user mode. Ever since I have called the proper way the:
"Super-Secret Power-Down Single-User mode."

Steve







Martin Johnson
Honored Contributor

Re: How to extend /usr logical volume?

I had a problem where after I powered down and came up in single user mode, I did the lvextend, then attempted the extendfs. The extendfs did not work. I had to mount /usr, then umount /usr before extendffs would work.

Go figure.

Marty
Christopher McCray_1
Honored Contributor

Re: How to extend /usr logical volume?

Hello, Steve

Sorry, didn't mean to put you on the spot; it's just that that was a new one to me. I really was interested in the source of this information is all.

But like I said, I never had a problem by just doing a shutdown -r, and I've seen other recent posts on this forum that instruct the author to do the same:

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x88525c7609e9d61190050090279cd0f9,00.html

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x0b324b3ef09fd611abdb0090277a778c,00.html

Sorry for the confusion and if I offended anyone.

Chris
It wasn't me!!!!
Steve Post
Trusted Contributor

Re: How to extend /usr logical volume?

oh that's ok. I wasn't offended at all. ^_^
I guess I like to talk about the old issue because I thought it was pretty funny.

I must write WAY to dark. Maybe Stephen King has competition.
Steve

Paul Sperry
Honored Contributor

Re: How to extend /usr logical volume?

I usually do it his way

add new lvm usr2

cd /usr

find . ???print | cpio ???pcxvdmu /usr2

edit fstab comment out usr and change usr2 to usr

reboot

remove unused volumes.

this of course assumes you have unused disk space.