1847431 Members
2429 Online
110264 Solutions
New Discussion

/ filessystem FULL

 
SOLVED
Go to solution
Henry Chua
Super Advisor

/ filessystem FULL

My /root filesystem seems to be full, but is there anything I can do to free some of its spaces. there seems to be very little files I can clear to free spaces....

Thank you all for your kind advises..
8 REPLIES 8
Michael Tully
Honored Contributor
Solution

Re: / filessystem FULL

There are a few places you can look.

core files (find / -xdev -name core -print)
du /dev (could have a bad /dev/rmt file)
du /etc (excessive logging in EMS- /etc/opt/resmon/persistance)
Anyone for a Mutiny ?
Sridhar Bhaskarla
Honored Contributor

Re: / filessystem FULL

Hi Henry,

the command that can come in handy would be

#du -kx / |sort -n

It will list all the directories sorted by their sizes with the bigger ones at the end. Look in those directory. Often application directories created with non-root owners can fill up / filesystem inadvertantly. Sometimes special files like /dev/null, /dev/rmt/0m, /dev/vgxx/* files will become regular files thus filling up /. Above 'du -kx' should show them.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Steven E. Protter
Exalted Contributor

Re: / filessystem FULL

There is a nasty little way space can be occupied but invisible.

lets say we got a folder called /var
There is usually a filesystem mounted there.

Lets say we figure out how to umount it or it fails to mount at boot.

Then 100 MB of data get copied in.

We realize the system is screwed and reboot. This time it mounts.

Is that 100 MB sitting in the unmounted /var folder visible? No. Is it taking up space? Yes.

When all else fails, you may need to take the system into single user mode when no filesystems are mounted and look around.

To do that, boot, intervene at the 10 second prompt(at console)

bo

Y Interact

hpux -is

Single user mode.

Check out those folders.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Sยภเl Kย๓คг
Respected Contributor

Re: / filessystem FULL


Have a look at /var and /etc directory.
Check for /tmp too

Use #du -kx /|sort -n
and checkout which directory covers more space.checkout that directory using
#du -kx |sort -n

cleanup some space this way.
U can even move some lager files to some other filesystem and and create symbolic link to it.This should be done if the file cannot be deleted.
regards
SK
Your imagination is the preview of your life's coming attractions
MarkSyder
Honored Contributor

Re: / filessystem FULL

I agree with the suggestions about using du -k piped to sort, but I always use the option sort -nr so that the largest entries are at the top - I find this more useful.

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

Re: / filessystem FULL

hi,

check on the root file system with the following command to find large files.

find / -size +1000000c -exec ll {} \;

or

find / -xdev -size +1000000c -exec ll {} \;

one common error is that when doing tar backup if you are giving backup device incorrect ,it will create a tar file in /dev/rmt.check for that.

regds,
Dan Maschmeier_1
Occasional Advisor

Re: / filessystem FULL

While in a directory with a lot of entries, this will give a list of the largest files. Often they can be trimmed, moved, or deleted.

ll $1 | sort -n -r -k 5,5 | more

twang
Honored Contributor

Re: / filessystem FULL

to find recenty created large files:
# find $DIR_TO_SEARCH -type f -size +$FILE_SIZE -mtime -$DAYS_SINCE_CREATED -exec ls -ls {} \; | sort -n -r | tee output.log