LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   The / directory is full (https://www.linuxquestions.org/questions/linux-general-1/the-directory-is-full-541829/)

sunhui 03-30-2007 02:31 AM

The / directory is full
 
The / directory is 100% used now , but I am sure what I have done that made it full , can advise how can I know what large file is in / directory ? how can I know the size of each directory ?

p.s. I try to check with "top" but nothing found .

Unknown_User 03-30-2007 02:39 AM

Use the find command;

# find / -type f -size +20000k

(Change the +20000k to whatever size you want to look for.)

acid_kewpie 03-30-2007 02:43 AM

top is for processes and cpu usage. it's about as much use as a shrew in a tuxedo here. you want to look at the du command to see how much disk space is being used by what directories. run a command like "du -xh --max depth=1 /" and that will show you the usage of all directories in the first level of the / filesystem that shoudl get you going. if you need to narrow it down further, just change / to /tmp etc...

ajaz_javeed 03-30-2007 05:42 AM

Hello Sunhui,
Please use the following command to check the size of each directory :

# du -sh <dir-name> (/tmp,/var,etc)

Thanks and Regards
AJAZ

acid_kewpie 03-30-2007 05:55 AM

Quote:

Originally Posted by ajaz_javeed
Hello Sunhui,
Please use the following command to check the size of each directory :

# du -sh <dir-name> (/tmp,/var,etc)

Thanks and Regards
AJAZ

i said virtually the same thing 3 hours ago... :confused:

jiml8 03-30-2007 12:11 PM

Quote:

Originally Posted by Unknown_User
Use the find command;

# find / -type f -size +20000k

(Change the +20000k to whatever size you want to look for.)

OP didn't specify distro.

I have in the past seen postfix malfunction and send emails to root reporting the malfunction (which were kept in the queue because postfix was malfunctioning). One of these came out every 60 seconds and over a period of time filled the HD with a couple of million messages which remained queued.

The point of this? Use find to establish the status of not merely files but directories too:

find / -type d -size +20k

will pick these up and could identify the problem.


All times are GMT -5. The time now is 05:06 AM.