HELP! - disk usage on partition is running low

Thank you so much for your help! The information you have given me is invaluable. Thank you so so much.
 
Forget your backup directories. Backup is probably crashing before it finishes. You can't trust anything in the backup directories.

Post the output of these commands:
Code:
# cd /home
# du -sh /home | grep G

Then for each output line, do the du -sh command for that directory.

Jeff
 
Jeff,

I took a look at her server. She had a nightly cron set up to back up using the system backup. I removed the extra system backups.
 
simple nifty script to clean up old backup files

simple nifty script to clean up old backup files and keep your disk clean. Create a new file 'del-old-data.sh' and put it in your /home/backup directory with the following content:

Code:
#!/bin/bash
# Keep the 21 newest entries in the directory where this script is located, and delete everything else older.
i=1;
max=21;
DIR=`dirname $0`
THIS=`basename $0`
cd $DIR
for file in `ls -1Bt --color=no $DIR | grep -v $THIS` ; do
  if (let "$i>$max"); then
    rm -rf $file;
  fi;
  let i++;
done

give it execute rights:
chmod 700 /home/backup/del-old-data.sh

and create some cronjob to run this script every day:
crontab -e
add:
5 5 * * * /home/backup/del-old-data.sh
 
Back
Top