Old website backups not deleted
I have noticed that if we change the backup options for a website in ISPConfig, the older backups are not deleted.
Running ISPConfig 22.214.171.124
This is when you change the copies of backups to keep from a larger number to a smaller number.
The effect of this is when we select a smaller number of backup copies to keep, we expect disk space usage to drop, this does not happen, as all backup copies are still kept.
Take this example:
Backup interval: daily
Backup copies: 2
In the /var/backup/webX/ folder we then get 2 backups:
Then we change backup copies = 1
The next day, the /var/backup/webX/ folder still has 2 backups (not 1):
The web.2.zip file is dated from 2 days ago.
So it appears the ispconfig cron_daily.php script does not take into account deleting older copies of backups.
Relevant code in /usr/local/ispconfig/server/cron_daily.php starts on line 430:
From when the user decreases the number of backup_copies to keep.
e.g. something like this maybe:
Your code shpould work. Thanks for the report and bugfix, I will add it to the bugtracker.
This would be "expected behaviour" for me .. i'dnot like it if a system starts messing with my backup files .. if i want to clean them, i'll do it manually, but hey, .. that's me! :)
At least some form of option to let the user decide if the older files should be deleted or not would be in nice. That way you can either keep running the old code, or the new code (which does delete them).
|All times are GMT +2. The time now is 20:36.|
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.