Support

Akeeba Backup for Joomla!

#13314 Cron job profuile configuration not removing old archives

Posted in ‘Akeeba Backup for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Akeeba Backup version
n/a

Latest post by on Saturday, 22 September 2012 18:00 CDT

user34725
Mandatory information about my setup:

Have I read the related troubleshooter articles above before posting (which pages?)? Yes
Have I searched the tickets before posting? Yes
Have I read the documentation before posting (which pages?)? Yes
Joomla! version: (unknown) 2.5.6
PHP version: (unknown)5.2.17
MySQL version: (unknown)5.523-55
Host: (optional, but it helps us help you)
Akeeba Backup version: (unknown)3.6.1

EXTREMELY IMPORTANT: Please attach a ZIP file containing your Akeeba Backup log file in order for us to help you with any backup or restoration issue. If the file is over 2Mb, please upload it on your server and post a link to it.

Description of my issue:

Hi
I have 2 profiles, one normal backup of site the other uploads to DropBox. No matter what quota management I use when the cron job (via cPanel) runs it is ignored, eg. enable count quota = 1, archives continue to build. If I run the backup from the site itslef through the Akeeba control panel, the quota is enforced. The same applies when 'maximun backup age' quota is used.

The DropBox profile does not upload files to DropBox when run as a Cronjob via cPanel, it does from Akeeba Control Panel.
Log files attached.

Many thanks

nicholas
Akeeba Staff
Manager
Both backups are using profile #1 which has no quota settings and does not upload to Dropbox. I assume that you just have to set --profile=2 (or whatever the ID of your Dropbox profile is) in your CRON command line in order for the second profile to be used.

Please note that the post-processing (e.g. upload to Dropbox) and quota management settings are applied per profile.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user34725
The logs evidently shows no quotas set, so I must have a setting wrong somewhere as they are set in the backend for this profile. The logs will only show history for profile#1, apologies please ignore the Dropbox issue I'll raise separately. Profile#1 has quotas set and works fine when run from the backend but does not when run from Cron. The cron job: /usr/local/bin/php /home/mysite/www/cli/akeeba-backup.php -profile=1.

I'm aware that enabling the backup age quota overwrites all others, I have tried using that and count quota. They only work when run from the backend

nicholas
Akeeba Staff
Manager
First, you need to type --profile=1 (two dashes in front) instead of -profile=1 (one dash). There was a typo in our documentation back in May, I've fixed it since then.

Now, regarding the quotas. As it is right now, the maximum backup age quotas are enabled which means that anything else is ignored. The way it's set up means that today's backups (backup age = 0) and the day before today's backups (backup age = 1) are kept. Backups which are from two days or more ago will be deleted. This should work equally from the back-end and CRON as long as you are using the same profile.

A more convenient test is disabling the maximum backup age quotas and running 2-3 backups from CRON. Only one backup should end up with an OK status, the rest should be Obsolete. FWIW, I don't see anything in the log which could indicate a problem with quotas in the CRON backup.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user34725
Thanks Nicholas, I'll run your test but I am not convinced as I have tried various combinations, all of which fail to remove obsolete archives.

nicholas
Akeeba Staff
Manager
Let's give it a run and then you can share your results. Maybe we're missing something easy. Running a few tests will let us figure out what's going on.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user34725
Hi Nicholas,
I ran 2 tests with both your quota recoomendation settings (quotas.jpg and quotass2.jpg) I set the cron job to run every 5 mins neither of the tests removed obsolete archives. The last job I ran was from the backend through Akeeba control panel and quotas were enforced. I also added to extra dash to --profile=1 prior to starting.

ZIP
cron email.txt = email notification after job
cronbackupsafter_backend,png = final test job shows removed older archives
cronbackups.png= shows accumulating archives with quotas set
quotas.png = 1st test quota setting
quotas2.png = 2nd setting
Akeeba.backend.log
akeeba.cli.log

nicholas
Akeeba Staff
Manager
I can't reproduce this behaviour on any of my servers. Strange! Can you try the latest dev release? I am 100% sure that quotas work with it because I did VERY extensive testing last night.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user34725
Hi Nicholas, that fixed the problem; quotas are now working as they should. Interestingly so is the DropBox profile!

nicholas
Akeeba Staff
Manager
Great! Thank you for the feedback, Alan!

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

System Task
system
This ticket has been automatically closed. All tickets which have been inactive for a long time are automatically closed. If you believe that this ticket was closed in error, please contact us.

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!