Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarification of Backup Strategy #248

Closed
jimmybrancaccio opened this issue Mar 16, 2021 · 16 comments
Closed

Clarification of Backup Strategy #248

jimmybrancaccio opened this issue Mar 16, 2021 · 16 comments
Labels
Bug Something isn't working

Comments

@jimmybrancaccio
Copy link

Describe the bug

This may or may not be a bug. Looking at config/backup.php I see there appears to be a default backup strategy at the bottom of file, however this configuration does not seem to be obeyed as I currently have 23 backups.

To Reproduce

  1. Setup LinkAce, I am currently using the "advanced" Docker deployment.
  2. Configure backups w/ S3.
  3. Let the backup process take place, and see it continue to occur.
  4. Does it ever remove older backups?

Expected behavior

At this point I am not sure what to expect since nothing appears to be documented, except for looking at the backup.php file.

Screenshots

N/A

LinkAce setup (please complete the following information):

  • Version: v1.2.2 (though I see there is a new version - not sure if anything in regards to backups was touched in that version)
  • Installed via: Docker
  • OS: Ubuntu 20.04.x

Desktop (please complete the following information if applicable):

N/A

Smartphone (please complete the following information if applicable):

N/A

Additional context

N/A

@jimmybrancaccio jimmybrancaccio added the Bug Something isn't working label Mar 16, 2021
@Kovah
Copy link
Owner

Kovah commented Mar 16, 2021

You can find more details about application backups in the Laravel-Backup Package by spatie, which provides the feature: https://spatie.be/docs/laravel-backup/v6/introduction

@jimmybrancaccio
Copy link
Author

Ok, so it's just a matter of running php artisan to clean things up.

@Kovah
Copy link
Owner

Kovah commented Mar 16, 2021

If you have set up the cron as explained in the documentation, this command should already be run every night. Could you check that?

@jimmybrancaccio
Copy link
Author

@Kovah Yes, the cron is already configured.

@Kovah
Copy link
Owner

Kovah commented Mar 16, 2021

As LinkAce ships with the default configuration of the package, daily backups of the last 7 days are kept. Are older ones deleted or do you have one on storage?

@jimmybrancaccio
Copy link
Author

@Kovah It appears no backups are deleted. S3 bucket listing:

Screen Shot 2021-03-16 at 17 58 31

I get 2 emails daily, subjects and contents:

backup::notifications.cleanup_successful_subject

Screen Shot 2021-03-16 at 17 59 41

backup::notifications.backup_successful_subject

Screen Shot 2021-03-16 at 18 00 20

@Kovah
Copy link
Owner

Kovah commented Mar 17, 2021

Okay thanks. Will take a look.

@Kovah
Copy link
Owner

Kovah commented Mar 18, 2021

@jimmybrancaccio BTW Did running the clean command manually help?

@jimmybrancaccio
Copy link
Author

@Kovah I've just run php artisan backup:clean now, but it doesn't seem to have done anything:

root@0feb3d037594:/app# php artisan backup:clean
Starting cleanup...
Cleaning backups of LinkAce on disk s3...
Used storage after cleanup: 29.64 MB.
Cleanup completed!

@Kovah
Copy link
Owner

Kovah commented Mar 18, 2021

That's super weird. Have to investigate this.

@Kovah
Copy link
Owner

Kovah commented Apr 14, 2021

I have set up backups on my personal LinkAce, but currently not even the backups are created despite having the backups enabled. no idea what's wrong with that.

@jimmybrancaccio
Copy link
Author

Oddly enough mine seem to be rotating now and it seems to keep 27 backups. 🤷🏼

@Kovah
Copy link
Owner

Kovah commented Apr 15, 2021

I found that I had broken my cron job, backups are running now.
Did you upgrade in the last days?

@jimmybrancaccio
Copy link
Author

I believe I did an upgrade last week. I am on 1.5.0 and the UI notes there's no other upgrades.

@Kovah
Copy link
Owner

Kovah commented Apr 15, 2021

Maybe it was a bug in the used package and it was resolved with version 1.5. Well... At least it's working. 🥳
Will monitor this on my personal setup.

@Kovah Kovah closed this as completed Apr 15, 2021
@jimmybrancaccio
Copy link
Author

Yeah definitely possible. That said, this should probably be documented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants