Operating System - HP-UX
1837645 Members
3525 Online
110117 Solutions
New Discussion

Increasing the size of root

 
Preeti Khanna
Occasional Advisor

Increasing the size of root

Hi
Can I increase the logical Volume of root(/)through SAM . root is using vxFS file system. My system is running on HP-UX 11.0
Currently size of root is 140MB .
What all Precaution should i have to take care while increasing the size of root through SAM.

Thanks
Preeti
Mission Impossible
13 REPLIES 13
John Palmer
Honored Contributor

Re: Increasing the size of root

No you can't. Well not directly anyway.
To increase the root volume you have to have it unmounted which means that you have to be running on a different root volume - either a recovery CD or an alternate root disk.

You also have to ensure that the root volume is contiguous.

Why do you want to increase it? It sounds big enough to me. Can you not accomplish what you want to achieve by creating a new filesystem and mounting it at /.
Alex Glennie
Honored Contributor

Re: Increasing the size of root

Not using sam anyway ....read on

At HP-UX 11.0, how can I extend the root file system?

Solution

There are three primary ways to extend the root logical volume
at HP-UX 11.0:

1. Re-install HP-UX 11.0, specifying a larger size for root.
Refer the Installing HP-UX 11.0 and Updating HP-UX 10.x
to 11.0 manual (HP part number B2355-90153) for the installation
procedure.

2. If a larger spare disk is available, copy the root file system
from the original disk to the spare disk. Refer to the
"Tasks that You Can Perform Only with HP-UX Commands"
section of Chapter 5 of the Managing Systems and Workgroups manual
(HP part number B2355-90157) for details on creating alternate
boot disks.

3. Use your recovery tape created with make_recovery(1M). This
would tend to be the least time-intensive process. make_recovery
is provided as part of the product Ignite-UX, which is free of
charge and available on the Applications Release media or
at URL:
http://www.software.hp.com
Refer to the make_recovery man page (once the product has been
installed) for details.

Make sure you have a reliable backup and recovery strategy prior to
attempting any system configuration change of this magnitude.



Preeti Khanna
Occasional Advisor

Re: Increasing the size of root

Hi
Thanks for Reply.
actually when i see the size it's 89% full.
so, that i thought to increase the size of root.

Thanks
Preeti
Mission Impossible
CHRIS_ANORUO
Honored Contributor

Re: Increasing the size of root

I don't agree with John. The best way to increase the size of root is by using the make_recovery tape. On reinstallation/recovery, you have the option of incresing filesystems. But what do you have in your /root directory?
When We Seek To Discover The Best In Others, We Somehow Bring Out The Best In Ourselves.
Stefan Farrelly
Honored Contributor

Re: Increasing the size of root


No, you cant increase / using SAM or even manually. However, someone in an earlier similar question came up with a method which seems very promising; see if you can find it, it was something like;

1. add in a new disk to vg00.
2. pvmove / (lvol3) to the new disk. Then extend it (as the rest of the disk its on is free so you can add some contiguous space to it - with OnlineJFS you can even do this without a reboot)
3. pvmove lvol1, then lvol2, 4,5,6 etc.
4. vgreduce the original disk out of vg00. change boot path with setboot and you have increased / without a reinstall.
Im from Palmerston North, New Zealand, but somehow ended up in London...
John Palmer
Honored Contributor

Re: Increasing the size of root

I was trying to make the point that extending / is not a trivial exercise and effectively involves rebuilding the boot disk.

/ should not be a volatile filesystem and 89% of 140Mb is not a problem.

Preeti,

Check you root filesystem for largeish files that are not required. You might find /core or something similar.

Regards,
John
Victor BERRIDGE
Honored Contributor

Re: Increasing the size of root

Hello Preeti,
With / of 140 MB you should be full at most 30%.
So look for what has been installed in the wrong place, check of core dumps look especially at /dev
I once found a file (a tar file ) /dev/tape....
Good luck
Victor
Tom Danzig
Honored Contributor

Re: Increasing the size of root

As Victor pointed out, look for any non-device files in the /dev hierarchy.

minor typo's (like /dev/rmt/om vs. /dev/rmt/0m) can create large files that shouldn't be there.

Bill Hassell
Honored Contributor

Re: Increasing the size of root

As mentioned before, way less than 100 megs is all that is needd for the / (root) directory. If it is 89% full, something has been stored there that does not belong. / is a static directory and badly written applications are often the cause (they install in / without permission).

To find what does not belong in the root directory, start by analyzing just what is in the root directory:

du -kx / | sort -rn > /var/tmp/du.root

Typically, at 11.0, the largest directories should be:

/ (about 40 megs)
/sbin (less than 20 megs)
/etc (less than 18 megs)

The only directories local to / should be:

/etc
/dev
/sbin

Everything else should be a separate mountpoint. To get rid of files that don't belong, find out how they got there and if it is an application, try to un-install it and re-install it on a separate disk.


Bill Hassell, sysadmin
Preeti Khanna
Occasional Advisor

Re: Increasing the size of root

Hi Bill
Thanks for your reply . yes i have found a directory prod having some file which is not related to our application.Right now i have moved this directory to /usr . Can you please tell me for what all these are used . I am attaching this file.The owner of this file is 500 and i haven't seen any user having id 500.

Thanks
Mission Impossible
Vincente Fernandes
Valued Contributor

Re: Increasing the size of root

A size of 140MB for "/" file system is more then sufficient. Someone must have copied the file on "/prod" directory. This files are definately not part of HP-UX. From the names of the files, looks like they are games packages or like.
Bill Hassell
Honored Contributor

Re: Increasing the size of root

The example file called prod is definitely not part of HP-UX. It looks very much like a bill of materials for manufacturing. Is this computer used to manage purchasing, materials management, assembly, etc? The use 500 is just a user ID number that does not exist in yourt password file. It may have come from restoring a tape from another computer or was created with a valid user that was subsequently removed from the passwd file, or someone (or some program or script) simply changed the owner to 500.


Bill Hassell, sysadmin
Vikas Khator
Honored Contributor

Re: Increasing the size of root

Hi ,

From the *.pkg extension , it looks like Solaris files. If you know it shouldn't be there , move it to /var and not /usr otherwise next time around you will have problems identifying it and then you wouldn't even risk removing stuff from /usr.

If it's a mission critical system or politically visible system I suggest you also create a symbolic link to wherever you move it to . This will prevent things from breaking .
Keep it simple