ISPConfig 2 Backup Issue

Discussion in 'Installation/Configuration' started by nfomaniak, Dec 21, 2010.

  1. nfomaniak

    nfomaniak New Member

    Hey guys.

    I just enabled the backup feature in ISPConfig but it does not seem to be backing everything up.

    The backup zip files only have two files in them, backup.dat and a db file, such as web3db1.sql.

    I am running ISPConfig 2.2.35.

    The other strange thing is that it is replacing the previous nights backups.

    Here is my crontab -l output for root

    30 00 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/logs.php &> /dev/null
    59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/ftp_logs.php &> /dev/null
    59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/mail_logs.php &> /dev/null
    59 23 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/cleanup.php &> /dev/null
    0 4 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/webalizer.php &> /dev/null
    0 4 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/awstats.php &> /dev/null
    0,30 * * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/check_services.php &> /dev/null
    15 3,15 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/quota_msg.php &> /dev/null
    40 00 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/traffic.php &> /dev/null
    05 02 * * * /root/ispconfig/php/php /root/ispconfig/scripts/shell/backup.php &> /dev/null
    45 * * * * wget -O - -q -t 1 http://www.example.com/cron.php

    If I run the command manually as root
    /root/ispconfig/php/php /root/ispconfig/scripts/shell/backup.php

    It works and the backups are created correctly, however, they are overwritten the next evening at 2:05am with the incomplete backups.

    Any help would be greatly appreciated.
     
  2. nfomaniak

    nfomaniak New Member

    I was just looking more closely at the Logwatch from last night and noticed a lot of entries in the Sudo (secure-log).

    I also noticed the backup script says sudo must be enabled.

    Do i need to enable sudo for each user?
     
  3. nfomaniak

    nfomaniak New Member

    OK. I figured it out

    My sudoers file had requiretty enabled and i was getting an error in /var/log secure

    root : sorry, you must have a tty to run sudo

    After commenting out Default requiretty it is working now.
     
  4. nfomaniak

    nfomaniak New Member

    Just in case it might be useful to someone else

    to prevent the backups from being overwritten each time the script is run

    remove this from backup.php

    else {
    exec("rm -rf $backup_dir/*");
    }
     
  5. nfomaniak

    nfomaniak New Member

    I have been noticing that the backup script is eating a whole lot of memory, about 700~800 MB out of the 2GB total RAM on my system.

    Is this normal?
     

Share This Page