1

I logged into my server this morning and received a disk is full error. How do I fix this or find wherever all of this data is hiding?

4
  • You fix it by either deleting necessary files or making the partitions larger. Start by looking at large files you might have in your home directory.
    – Panther
    Dec 30, 2013 at 21:12
  • I already posted the answer Bodhi. =] And sometimes you can't make the partitions larger, and sometimes the home folders are empty.
    – Kaz Wolfe
    Dec 30, 2013 at 21:14
  • check this out: askubuntu.com/questions/5980/how-do-i-free-up-disk-space/…
    – jet
    Dec 30, 2013 at 22:50
  • @jet the sort command needs free disk space. If you don't have that, it won't work.
    – Kaz Wolfe
    Dec 31, 2013 at 2:52

1 Answer 1

1

Well, the first thing you want to do is try to login as root (recovery mode).

EDIT: If you are in recovery mode, you'll need to remount as RW. To do this, mount -o remount,rw /.

Run cd /. This allows you to enter the root and begin to trace the problem.

When you are in /, run du -sh *. This'll give you a list of all of the files in your hard drive. Let's say you see

2.6T var

You know that the problem is in /var. You then cd /var and run the du -sh * command again. Scroll and look for something like

2.6T zpanel

You then know the problem is in the ZPanel folder. (I am using ZPanel for this example, as I just recovered from this exact problem). By now you know the drill. You cd zpanel/ and du -sh *. Look for something like

2.6T backups

Same old, same old. cd backups/, du -sh *. But this time, you get

(size) zpanel_date_etc

The backups folder contains no more subdirectories, so you expunge the unnecessary files. In my case, I used rm -rf zpanel_* and went from 100% capacity to 25% capacity.

Then, you fix wherever the problem is. (For me, it's in ZPanel's backup settings, so I should change those).

This works with any situation, all you need to do is trace the problem.

N.B. I know you could have probably used a sort to do this, but if you have no temp space, you can't sort. This is the best option.

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .