solaris 8 / disk space almost full

Hi All,

My Solaris 8 firewall server is getting full on the / filesystem. I don't know which one should I delete. I think there's no more to delete on the file like logs or temp file.

Does someone knows about deleting a safe file (or folder) on FS like /usr, /opt, /platform, /kernel, /sbin?

Thank you for any comment you may add.

Is there something I could delete/zip here?

8864 4600 -rwxr-xr-x 1 root bin 4694260 Aug 8 2001 /usr/j2se/jre/lib/sparc/client/libjvm.so
33541 9032 -rw-r--r-- 1 bin bin 9236099 May 24 2001 /usr/java1.1/lib/classes.zip
33716 4616 -rw-r--r-- 1 root bin 4711081 Aug 8 2001 /usr/j2se/lib/tools.jar
41790 6472 -rwxr-xr-x 1 root bin 6613194 Dec 15 1999 /usr/openwin/lib/sparcv9/llib-lX11.ln
66629 6896 -rwxr-xr-x 1 root bin 7051704 Aug 8 2001 /usr/j2se/jre/lib/sparc/server/libjvm.so
99218 6912 -rwxr-xr-x 1 root other 7063756 Jan 31 2002 /usr/local/sbin/sshd-check-conf
99826 8872 -rwxr-xr-x 1 root other 9070180 Jan 31 2002 /usr/local/sbin/sshd2
182510 6256 -rwxr-xr-x 1 root bin 6396454 Dec 15 1999 /usr/openwin/lib/llib-lX11.ln
207406 4944 -rw-r--r-- 1 root bin 5053848 Aug 8 2001 /usr/j2se/src.jar
223149 8520 -rw-r--r-- 1 root sys 8714999 Jun 7 2006 /usr/sadm/lib/wbem/store
239523 10744 -rw-r--r-- 1 root bin 10992943 Sep 10 2001 /usr/java1.2/jre/lib/rt.jar
248138 13496 -rw-r--r-- 1 root bin 13810951 Aug 8 2001 /usr/j2se/jre/lib/rt.jar
264750 13568 -rw-rw-r-- 1 root other 13883618 Dec 8 2004 /usr/j2re1_3_1_15/lib/rt.jar
289394 7216 -rwxr-xr-x 1 root other 7374364 Jan 31 2002 /usr/local/bin/ssh-add2
289396 6912 -rwxr-xr-x 1 root other 7065144 Jan 31 2002 /usr/local/bin/ssh-agent2
289398 7360 -rwxr-xr-x 1 root other 7527184 Jan 31 2002 /usr/local/bin/ssh-certenroll2
289401 7032 -rwxr-xr-x 1 root other 7191048 Jan 31 2002 /usr/local/bin/ssh-keygen2
289405 6768 -rws--x--x 1 root other 6916912 Jan 31 2002 /usr/local/bin/ssh-signer2
289406 9488 -rwxr-xr-x 1 root other 9703540 Jan 31 2002 /usr/local/bin/ssh2
289463 7248 -rwxrwxr-x 1 root other 7413052 Dec 8 2004 /usr/j2re1_3_1_15/lib/sparc/server/libjvm.so
297354 4760 -rwxr-xr-x 1 root bin 4864308 Sep 10 2001 /usr/java1.2/jre/lib/sparc/libjvm.so
297786 4944 -rwxrwxr-x 1 root other 5046900 Dec 8 2004 /usr/j2re1_3_1_15/lib/sparc/client/libjvm.so

No spare filesystem with room elsewhere (other disks...)?

No room, no additional budget for it.

The j2se, j2re and java file/directories are all for various versions of Java.
Rather than deleting particular files it would be better to remove whole packages, so for instance your list mentions Java, if you are not using Java then the Java packages could be removed. To find out which Java packages you have run:

# pkginfo | grep -i java

Once you have the package names you can see what files those packages install by running:

# grep <javapkgname> /var/sadm/install/contents | grep " f "

I would suggest that you chmod the Java package's files to 100 (or zip up) first and leave it a while make sure nothing breaks!

Another possibility is that if you have Solstice Disksuite installed and only use it in command line then remove the graphical interface package and if you are not Japanese then remove the Japanese localisation, they being:

1 SUNWmdg Solstice DiskSuite Tool
(sparc) 4.2.1,REV=1999.11.04.18.29
2 SUNWmdja Solstice DiskSuite Japanese localization
(sparc) 4.2.1,REV=1999.12.09.15.37

These would be removed by running:
# pkgrm SUNWmdg
# pkgrm SUNWmdja

Core files are obviously worth removing:
# find / -type f -mount -name core -exec rm {} \;

The files you list mentioning ssh are for SSHing from this machine to others and the files called sshd are for SSH'ing to this machine so if you not use SSH these can be purged, from a security point of view you should leave ssh and remove telnet, rlogin, rsh, etc instead! Solaris 8 does not come with Sun supplied SSH so they may not be in a package.

The file /usr/sadm/lib/wbem/store mentioned is part of the Web-Based Enterprise Management software, if you don't use then again remove the packages not particular files.

/usr/openwin/lib/llib-lX11.ln is part of the X11R6.4 Lint Libraries.

Tony Fuller

Find the top ten "heaviest" directory or file under /

#cd /
#du -sk * |sort -rn |head

Check into the very first file or directory and remove whichever is not required. Backup 1st, in case..

remove any cores under /var/crash/<hostname>
Check /var/adm/ directories.. other than the messages file, you may want to remove the older logs like messages.0 , messages.1 and so on..
remove not required files under /tmp and /var/tmp

Good advice although /var is likely to be a separate volume and /tmp certainly will not be part of the root volume.

If / is currently increasing in size, some file in / is growing. I would find it (or them) by asking what files in / have been recently written..
find / -type f -mount -mtime -1 -print | xargs ls -l

after I know the culprit then I can make a plan. And by the way, lots of people put /var in / these days. It could be just a matter of trimming log files.