1848637 Members
2036 Online
104034 Solutions
New Discussion

Free space - 10.20

 
Lionel Quiblier
Occasional Contributor

Free space - 10.20

Hi all,

I need to free space on my system disc to installed Ignite-ux. I am on HP-UX 10.20. I have already deleted the tmp directories. Which files can I remove (or move temporarily) ?

thanks.
10 REPLIES 10
Steve Steel
Honored Contributor

Re: Free space - 10.20

Hi

/var/tmp and /tmp are needed

What do you have loaded on machine

Give swlist or swlist -l fileset

man pages
extra languages
The cleanup command
remove core files

Are all good ways to start

Steve Steel
If you want truly to understand something, try to change it. (Kurt Lewin)
Bill Hassell
Honored Contributor

Re: Free space - 10.20

Start by locating the biggest directories on the problem filesystem. Each mountpoint is independent so use bdf to locate the nearly 100% full filesystems. Now search that filesystem and sort the directories. The two most common problems are / and /var. Assuming / is your problem:

du -kx / | sort -rn | head -15

This should look something like this:

# du -kx / | sort -rn | head -15
71792 /
33392 /etc
32608 /sbin
14736 /etc/vx
13944 /etc/opt
12536 /etc/vx/type
8552 /etc/opt/resmon
6368 /etc/opt/resmon/lbin
5888 /sbin/fs

If any non-HP-UX directory shows up, you have a misinstalled directory or application. If /dev is at the top of the list, someone very likely misspelled the name of a tape drive. /dev should be about 50 to 200 bytes. Find the bad file(s) and remove them:

find /dev -type f

(there should be nothing returned from this find command).

For /var, do the same directory summary:

# du -kx /var | sort -rn | head -15

Typical is very dependent on your usage of the system. You'll need to post the results so we can advise you further.


Bill Hassell, sysadmin
Lionel Quiblier
Occasional Contributor

Re: Free space - 10.20

Hi,

Thanks for your reply.

Where are : 'man pages', 'extra languages', 'The cleanup command' and 'remove core files' ?

Could I remove them without risk for my system ?

thanks.
Lionel
Lionel Quiblier
Occasional Contributor

Re: Free space - 10.20

Hi,

see the results of the commands :

#du -kx / | sort -rn | head -15
432678 /
272576 /usr
112658 /opt
86963 /usr/lib
74769 /usr/sbin
57510 /usr/sbin/stm
46340 /usr/sbin/stm/uut
32169 /opt/langtools
29686 /var
28123 /usr/lib/nls
23755 /usr/share
23614 /usr/lib/sw
23605 /usr/sbin/stm/uut/lib
22734 /usr/sbin/stm/uut/bin
22431 /usr/lib/sw/hpux.install

#du -kx /usr | sort -rn | head -15
272576 /usr
86963 /usr/lib
74769 /usr/sbin
57510 /usr/sbin/stm
46340 /usr/sbin/stm/uut
28123 /usr/lib/nls
23755 /usr/share
23614 /usr/lib/sw
23605 /usr/sbin/stm/uut/lib
22734 /usr/sbin/stm/uut/bin
22431 /usr/lib/sw/hpux.install
22247 /usr/sbin/stm/uut/bin/tools
18513 /usr/share/man
18234 /usr/bin
16225 /usr/sam

#du -kx /opt | sort -rn | head -15
112658 /opt
32169 /opt/langtools
19988 /opt/pd
17433 /opt/pd/lib
15796 /opt/langtools/dde
12999 /opt/dce
9128 /opt/langtools/dde/softbench
8957 /opt/perf
8495 /opt/pred
8486 /opt/ansic
8461 /opt/pred/bin
8128 /opt/dce/bin
7982 /opt/langtools/bin
6657 /opt/ansic/lbin
6385 /opt/video

What do you think about /opt/langtool and /opt/video and /usr/share ?
I think I do not need this directories.
No ?

thanks
Lionel
Petr Simik_1
Valued Contributor

Re: Free space - 10.20

1. Remove/empty non needed files
You can remove all core files by
find / - name "core" -exec rm {} \;

du - ks * or kx as mentioned is good to find files to remove.

Usually log files are taking space like syslog, mail log - check the content before deleting and find why they are this big.

It is recomended to clean log files by redirecting null ( > file.log )rather than removing and creating them again.


2.check the diskspace and you can extend diskspace of your system disk by extending lvm. man lvextend to find this:

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
Mel Burslan
Honored Contributor

Re: Free space - 10.20

you can safely remove core files with the command given on the previous posting.

check your /var/adm/crash directory. if you have any crash dumps in it, and you are not planning a dump analysis done on that, you can clean this directory contents.

use the cleanup command as such

cleanup -c 1

which will remove the patches superseeded more than once.
________________________________
UNIX because I majored in cryptology...
Bill Hassell
Honored Contributor

Re: Free space - 10.20

Aha. Someone has bypassed the standard installation completely by putting what looks like everything in one giant filesystem. Running out of space on a single filesystem is a lot more complicated to resolve, but most important, your system will almost always crash when this happens. On a typical HP-UX layout using LVM to carve up the disk, there are separate filesystems for /usr /var /tmp /home and all of these are separate from /. Now if someone makes a big mistake and fills up /tmp, the system won't crash but some processes may fail.

This type of layout is common for workstation users but the problems and reliability issues are the same for both servers as well as workstations. Igt looks like this is a graphics workstation so you will have a lot of space consumed with Xwindows directories in /usr. As far as files and directories that can be removed, start with the biggest items:

- /usr/lib/nls: Is English your only language on this computer? If so. you may want to use swremove to delete the Native Language Support files to gain more space.

- /opt/pd: Do you need HP DPS? This is the distributed Print Server, virtually useless on a single workstation. It is used to manage hundreds of printers on dozens of HP-UX servers. Use swremove to remove this product.

- Have you run the cleanup tool? This will help /var/adm/sw.

It appears that you have an incredibly small disk, perhaps 1Gb (since 432megs is currently in use and you said you're out of space). I would certainly look at replacing this disk with at least a 4Gb model. If this is already in the plan, then the easiest way is to add another disk, create a volume group and two lvols with filesystems on it (each one at least 250megs), then create these directories on your system:

/opt/ignite
/var/opt/ignite

Now create mountpoints for the two directories in /etc/fstab:

/dev/vg01/lvol1 /opt/ignite vxfs defaults 0 2
/dev/vg01/lvol1 /var/opt/ignite vxfs defaults 0 2

Now mount the two filesystems:

mount /opt/ignite
mount /var/opt/ignite
bdf

Now you can load Ignite/UX. Perform your make_tape_recovery command (do NOT use make_recovery) and specify the options: -I -v -x inc_entire=vg00. Now when you restore your system, the tape will pause and ask you about creating new lvols and mountpoints. Definitely create /usr /opt /var /tmp /home and resize them when you restore your system. Here are some useful values: /usr and /var=1000megs, /opt=250megs, /tmp=150megs, /home=whatever...


Bill Hassell, sysadmin
Lionel Quiblier
Occasional Contributor

Re: Free space - 10.20

hello,

thanks for your help.

First, my HP9000 is a HP-UX 10.20 server (sorry to have not mentioned it front). And I do not have any utility of graphic functions.

The idea to created another mountpoints for Ignite seems to be very good. But in this case I can not for the moment . (maybe on another server)
Here, I am condemned to remove files.

I have no core file and no crash dumps file.

I used swremove to delete some files of language (14 Mo).

I did not find the cleanup tool. how could I make space in the /var/adm/sw ?

What else ???

thanks a lot
Lionel
Bill Hassell
Honored Contributor

Re: Free space - 10.20

Sounds like this server has all the graphics packages loaded (which you don't need). You can save a *lot* of space by running swremove interactively and removing the Xwindows, HP DPS (distributed print system), all video and audio products. SinThe cleanup command is in /usr/sbin/cleanup. If it is not, then your old system is probably way out of date on all patches. Unfortunately, HP has removed the final patch bundles for 10.20 (which were released in Dec 2001).

What model is this computer? Is there a reason you can't add an external disk? This system is barely functioning with such a small disk.


Bill Hassell, sysadmin
Lionel Quiblier
Occasional Contributor

Re: Free space - 10.20

Hi,

I have used swremove to delete video packages, native languages, some manuals and other help files. I saved 70Mo and that is enough for me.
This server is an HP9000 E45. In fact I manage some other old HP9000 which have all the same probleme and I can not add external disk on all of them.

thanks all
Lionel