Only 25 backups?

Hello all.

I just noticed that there are only 25 backups in the backup directory despite setting backups to 99.

Any ideas? If not, I will just setup a nightly cron to move the files to a different directory to preserve them. Maybe even put them into some date order directory and push them to google.


If you are going to go through all the trouble to setup a cron job to manage the standard backups, then why not just take over the backup process yourself and then you can have complete control over how many, their naming, their frequency, and just about anything else you can think of managing.

I wrote a post some time abgo for how to do this and it would take you about the same amount of time to setup as it would to start writing your own cron jobs to manage this stuff. My post also uses a single cron entry to do the same thing but with more options.

Read here:


Thank you for the reply.

I have read your excellent post… which I don’t quite need yet.

In terms of backup, the crob job is set to hourly which is fine. The job I am referring to would simply move the backup files to another directory outside erpnext.

I have already created a simply “restore” script which simply requires the timestamp of the backup to restore and will restore both the DB (bench --site x --force restore sqlfile) and untar the files to the private files directory.