1834936 Members
2208 Online
110071 Solutions
New Discussion

root partition

 
SOLVED
Go to solution
Boris_31
Frequent Advisor

root partition

How i can increase size of / ?
13 REPLIES 13
MarkSyder
Honored Contributor
Solution

Re: root partition

Hi Boris.

The first thing to do is ask yourself: "Do I really need to do this?"

Is there any stuff in / that would be better in its own filesystem?

If your answer is that you do need to increase /, you will need to boot from an ignite backup. Other people are better qualified than I am to take you from there.

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

Re: root partition

Firstly question why you really want to extend /, as you shouldn't normally need to. Perhaps you have some core files or something taking up space?

Otherwise: -

The only way to extend / is a rebuild of the server. On a HPUX server, lvol1 (/stand) lvol2 (swap) and lvol3 (/) HAVE to be contiguous no the disk. Therefore you cannot extend /, as the rest of it will be located later on the disk, wherever lvm chooses to put it.

The procedure is as follows: -

- Ensure your Ignite/UX software is FULLY up to date (including PAX and any other patches).
- Take a FULL Ignite of your vg00 volume group.
- Take a note of any mirror configuration.
- Reboot the server off the Ignite tape, and during the Ignite install, specify the new size of "/" you require.
- Re-establish any mirrors.

If you've never done this before, PLEASE try on a test box first!

But consider whether you really need to do this!
Paul Torp
Regular Advisor

Re: root partition

The Ignite way is the absolutely best way!

Make a recovery tape..

Boot on it, choose advanced and then change the filesystem.

-paul
"sendmail is kind of fun..."
Jan Sladky
Trusted Contributor

Re: root partition

Hi Boris,

ussulaly it's not recommended. / fs must be continuous, so if you want encreasing, you must have free space behind.

The easiest way is to use Ignite backup tape
and boot from that.
After booting you can change the fs and restore to newly defined vg.

tape creation:
make_tape_recovery -a /dev/rmt/0mn -A -v -x inc_entire=vg01

try also -p option for test without writing to tape.

be careful
without -x inc_entire=vg01, only the
/dev/vg00/lvol1 /stand /dev/vg00/lvol3 / /dev/vg00/lvol7 /usr

will be written to tape, so check it twice what you want to be saved.

rgds Jan
GSM, Intelligent Networks, UNIX
Boris_31
Frequent Advisor

Re: root partition

If i have not type drive?
I can write to floppy or dvd?
Boris_31
Frequent Advisor

Re: root partition

thanx all !!!
Jan Sladky
Trusted Contributor

Re: root partition

Hi Boris,

are you able to obtain external tape drive ?

Floopy can't be used, it is not only boot tape but mainly tape for "RESTORE FROM TAPE" purpose.

I'm not absolutely sure about make_tape_recovery to DVD, but I don't thing it's gonna be working.

You must obtain external tape drive or reinstall whole OS,or wait for another hint in this thread

rgds Jan
GSM, Intelligent Networks, UNIX
Bill Hassell
Honored Contributor

Re: root partition

A floppy or CDROM isn't going to work. The floppy is way too small to be of any use on any version of HP-UX. The bootup code is perhape a dozen floppies in size. Making a bootable CD is going to talk a lot of work. However, if you have another HP-UX computer on your local network, you can use make_net_recovery to perform a backup over the network and restore your system over the network. This will involve some time in the man pages.

However, there is virtually no reason to increase the size of /. By definition, it is a static filesystem and contains only the following directories:

/dev /etc /sbin

and optionally:

/tcb /net /cdrom /tmp_mnt

Most likely you have one or more mistakes in / that have used up your / space. Start by finding which / directories are mountpoints:

find /* -prune -type M
/home
/opt
/stand
/tmp
/usr
/var

The above is fairly typical. These directories are actually other lvols with filesystems and do not occupy any space in /.

Then find out which directories are local to / (and therefore count as used space in /):

find /* -prune -type d -a ! -type M
/dev
/etc
/lost+found
/root
/sbin
/tmp_mnt

Now the above list of local filesystems is typical and other than /etc /sbin and /dev, all of the directories should be empty. NOTE: The above find command locates all directories in /*, but nothing lower (-prune) and does not show mounpoints for other filesystems (! - type M).

Now see how big the local directories are:

du -kx / | sort -rn
72696 /
33944 /etc
32616 /sbin
14736 /etc/vx
14512 /etc/opt
12536 /etc/vx/type
9104 /etc/opt/resmon
6368 /etc/opt/resmon/lbin
...

As you can see, the total size of / is 72megs, about normal for most HP-UX 11.11 systems with a few optional applications loaded. If you see /dev at the top of the list, a big spelling error has occurred, usually in /dev/rmt. Find the spelling error with:

find /dev -type f

Anything reported back from this find command should be removed. Comomon spelling errors: /dev/nul /dev/null1 /dev/null2 /dev/rmt/om, etc. These are created when a device file was intended, but the exact spelling was incorrect and a normal file was created. Only root can make this mistake since /dev/is not writable by ordinary users.

The other common error is applications which did not use the standard /opt directory but instead, created their own. These apps must be moved to a mountpoint. Another possibility is that root's HOME directory has large files. root's HOME should be quite small, a few megs at most.


Bill Hassell, sysadmin
TwoProc
Honored Contributor

Re: root partition

Suggestion - If you're "close" and you've followed the previous steps on clean up... I've been able to move /etc/opt and /etc/lp to other file systems. Neither of these are needed as far as my research tells me during the boot up until you start "leveling up" to your destination init level. Put it this way, you don't need anything in either of these directories to come up in singlue user mode - so it's a candidate to be moved to other file systems. Reason for /etc/lp: You probably don't need to print anything until you're fully up. Reason for /etc/opt... *I* don't need anything in here until I'm up - however, you *may*, need to review for yourself. Things that I can think of that may be affected by it... maybe service guard, maybe PRM... maybe not. I'm using Port Aggregation, and I don't need anything in /etc/opt until my machine starts leveling up...

Reason why you could fill up / ? Lots and lots of volume groups that you didn't have when you first came up. That is, data growth.

We are the people our parents warned us about --Jimmy Buffett
Boris_31
Frequent Advisor

Re: root partition

I'm relocate /etc/opt/OV to new partition /OV
and clean old directory. But i have interest
about increase size of /
Who know also method, write please
Rashid Hamid
Regular Advisor

Re: root partition

Hi

I just wondering whether can use online JFS to increase / .

In AIX, / can increase on fly without problem. No need to boot from recovery tape.

Regards
Rashid
I'm Parit Madirono/Parit Betak Boyz
Paul Torp
Regular Advisor

Re: root partition

boris.. assign points, please
"sendmail is kind of fun..."

Re: root partition

You can do it as well by borrowing from the next logical volume group, if it can be applied.

I did have lvol3 for / and the continious PE were from lvol4 that I could break and recreate.