Operating System - HP-UX
1832592 Members
3132 Online
110043 Solutions
New Discussion

extending the root volume

 
SOLVED
Go to solution
Sprint Unix Team
Frequent Advisor

extending the root volume

How do i extend the root volume on a K class after bringing it down to single user mode.

I use the lvextend command, but i get an error message saying the file sytem is busy.

Please help
5 REPLIES 5
linuxfan
Honored Contributor
Solution

Re: extending the root volume

Hi,


The root filesystem / has to be a contiguous so you just can't extend it like you normally extend the other filesystem.
Still there are two options, the most commonly used is to install ignite/UX
http://www.software.hp.com/products/IUX/index.html

and run make_recovery. Even here you have two options,
(From HP doc A5779615 )
Ia. make_recovery -p -A -d /dev/rmt/tape_device
Ib. Modify the /var/opt/ignite/recovery/config.recover file:

Locate the following information in
/var/opt/ignite/recovery/config.recover:

logical_volume "lvol3" {
usage=VxFS
size=86016KB
mount_point="/"
largefiles=FALSE
bad_block_relocate=false
contiguous_allocation=true
stripes=0
stripe_size=0KB
disk[_hp_root_disk]
} # end logical_volume

Modify the above information to the appropriate size.
Ensure that you have enough space in vg00 to perform this operation.

You can shrink one logical volume so that you can increas another logical volume. Be careful not to configure more disk space that what's actually available in vg00.

Save /var/opt/ignite/recovery/config.recover.

make_recovery -r -d /dev/rmt/tape_device

The second option of make_recovery is described in
http://us-support2.external.hp.com/cki/bin/doc.pl/sid=25d8db6a18df2266e5/screen=ckiSearchResults?mode=id&searchString=LVMKBRC00005106


II. If you have Online-JFS installed, the other not-so-popular method is described in the hp DOC
KBRC00006582

-HTH
Ramesh
They think they know but don't. At least I know I don't know - Socrates
Thierry Poels_1
Honored Contributor

Re: extending the root volume

hi,

Ramesh's answer is quite complete BUT do you really need to increase /? The root filesystem is always relatively small. Maybe you can remove unwanted files, or create a filesystem for a sub directory.

just my two (euro)cents,
Thierry.
All unix flavours are exactly the same . . . . . . . . . . for end users anyway.
James R. Ferguson
Acclaimed Contributor

Re: extending the root volume

Hi:

As Ramesh has correctly noted, a cold install of your vg00 with Ignite or the extension of your root filesystem, if it is a VxFs (JFS) one, with the technique described in Technical Knowledge Base document #KBRC00006582 are you two best options.

HOWEVER, I'd like to offer the following considerations:

If you root file system is highly utilized, find out why. If there are core files there, dispose of them. If you, or others have allowed files to gather there that really belong in /var or /home, move them to their proper place. A common reason for the root filesystem to grow is the presence of ordinaray files in the /dev directory from mis-typed backups. If a backup ('tar', 'fbackup', etc.) specifies a tape as '/dev/rmt/om' instead of the intended '/dev/rmt/0m' then the backup becomes an ordinary file in /dev. Look for ordinary files in /dev that don't belong there.

If the above situation doesn't apply, or doesn't resolve your root file system requirements, and you need to expand it because you are planning an upgrade from 10.20 to 11.x, then consider doing a cold-install of 11.x in lieu of an upgrade. The likelihood of success is far better with less potential problems based on the collective experiences of many, many Forum participants.

Lastly, if for whatever reason you choose to use Ignite, download the latest version from the Ignite site, and use 'make_tape_recovery' instead of the older 'make_recovery'. The 'make_tape_recovery' provides far greater options. To make a recovery tape of vg00, which includes 'mapfiles' to subsequently 'vgimport' non-vg00 volumes (as after a cold install) do this:

# make_tape_recovery -x inc_entire=vg00 -I -v -a /dev/rmt/0mn

The '-I' option causes the Ignite process to be interactive when booting from tape. In this fashion, you can select the advanced installation tab and choose the sizes of your vg00 logical volumes. You do *not* need to edit '/var/opt/ignite/recovery/config.recover' as documented in procedures for the older 'make_recovery' command, making the process much simpler.

To obtain current Ignite software and documention, go here:

http://www.software.hp.com/products/IUX/index.html

Regards!

...JRF...
Sprint Unix Team
Frequent Advisor

Re: extending the root volume

I agree with all of you. In the first place, I dont find any reason to extend the root volume. What ferguson said is 100% true that we have unwanted files in the root volume, but we have some users who dont listen to what the sys admin say!!!

Anyways, since somebody argued with me it can be done without ignite, I wanted a second opinion.

Anyways thanks for all ur help!!
Wodisch
Honored Contributor

Re: extending the root volume

Hello Team,

regardless wether there is a point in extending the root
file system or not (sometimes ther is, at least :-) with
some precautions you can usually do it!
If you have another disk with enough unused space in
the root and boof VG, then you can "pvmove" the LV
immediately "following" the root-fs-LV to the other disk.
Using the "Advanced VxFS/Online JFS" you can now
increase the size of the root-fs *online*. Now you
"pvmove" the "next" LV to the other disk and the
previous one back (increase it if neccessary, too).
Continue with that until everything is resized and moved
to its proper place...
Been there, done that, on productive system, where we
could not afford down time (they were, of course, but
the whole principle is sound and does work even there).

Just my ?0.02,
Wodisch


HTH,
Wodisch