The backup schedule should delete the oldest backups #278

Closed
opened 2026-02-05 17:22:24 +03:00 by OVERLORD · 15 comments
Owner

Originally created by @SirEndii on GitHub (Mar 17, 2025).

Creating Backups using a schedule does not work if the server is on its backup limit.
Like in pterodactyl(iirc) the oldest backups should be deleted when a new backup is created using a schedule.

Currently, it just stops creating backups, which I just noticed. I deleted some backups to make some free space for more.

I have a daily midnight schedule to create backups - you can see that there are only week old backups there since the backup space is full.

Image

Not sure if it is relevant, but I am using S3 for backups.

Originally created by @SirEndii on GitHub (Mar 17, 2025). Creating Backups using a schedule does not work if the server is on its backup limit. Like in pterodactyl(iirc) the oldest backups should be deleted when a new backup is created using a schedule. Currently, it just stops creating backups, which I just noticed. I deleted some backups to make some free space for more. I have a daily midnight schedule to create backups - you can see that there are only week old backups there since the backup space is full. ![Image](https://github.com/user-attachments/assets/e6c9f172-ca0a-4b5b-807a-05e175a4b2f0) Not sure if it is relevant, but I am using S3 for backups.
Author
Owner

@rmartinoscar commented on GitHub (Mar 17, 2025):

Pterodactyl didn't remove backup either, you have to make a schedule task that removes a backup before taking a new one

But yeah a retention system would be neat

@rmartinoscar commented on GitHub (Mar 17, 2025): Pterodactyl didn't remove backup either, you have to make a schedule task that removes a backup before taking a new one > But yeah a retention system would be neat
Author
Owner

@mristau commented on GitHub (Mar 17, 2025):

can you delete a backup using the delete action, else an action like "delete backup" would be nice

@mristau commented on GitHub (Mar 17, 2025): can you delete a backup using the delete action, else an action like "delete backup" would be nice
Author
Owner

@Boy132 commented on GitHub (Mar 17, 2025):

Pterodactyl didn't remove backup either, you have to make a schedule task that removes a backup before taking a new one

That's wrong, on Pterodactyl the oldest (non-locked) backup will be deleted once it reaches the backup limit.
If this doesn't happen in Pelican it's a bug.

f2f3ee548f/app/Services/Backups/InitiateBackupService.php (L92-L110)

@Boy132 commented on GitHub (Mar 17, 2025): > Pterodactyl didn't remove backup either, you have to make a schedule task that removes a backup before taking a new one That's wrong, on Pterodactyl the oldest (non-locked) backup will be deleted once it reaches the backup limit. If this doesn't happen in Pelican it's a bug. https://github.com/pelican-dev/panel/blob/f2f3ee548fa216c0f10ec49a3f024f1d8465a935/app/Services/Backups/InitiateBackupService.php#L92-L110
Author
Owner

@rmartinoscar commented on GitHub (Mar 18, 2025):

I can't see anywhere the $override is set to true even on our repo

@rmartinoscar commented on GitHub (Mar 18, 2025): I can't see anywhere the `$override` is set to `true` even on our repo
Author
Owner

@GameAreaCZ commented on GitHub (Mar 20, 2025):

I do not know, but for me according the timestamps and backups names it looks like it is working?

Image

@GameAreaCZ commented on GitHub (Mar 20, 2025): I do not know, but for me according the timestamps and backups names it looks like it is working? ![Image](https://github.com/user-attachments/assets/1b2914e7-95d9-4749-a681-5590d0bcc242)
Author
Owner

@SirEndii commented on GitHub (Mar 20, 2025):

Interesting
It at least does not for me - after I deleted some backups it created new ones

Maybe because I use S3?

@SirEndii commented on GitHub (Mar 20, 2025): Interesting It at least does not for me - after I deleted some backups it created new ones Maybe because I use S3?
Author
Owner

@GameAreaCZ commented on GitHub (Mar 20, 2025):

That is possible I'm not using the S3.

@GameAreaCZ commented on GitHub (Mar 20, 2025): That is possible I'm not using the S3.
Author
Owner

@TigerGamer134 commented on GitHub (Apr 8, 2025):

Works as it should with S3 for me

@TigerGamer134 commented on GitHub (Apr 8, 2025): Works as it should with S3 for me
Author
Owner

@SirEndii commented on GitHub (Apr 8, 2025):

Due to the mixed feedback, I will deep test that in the next few days again

@SirEndii commented on GitHub (Apr 8, 2025): Due to the mixed feedback, I will deep test that in the next few days again
Author
Owner

@EL-JAYY commented on GitHub (Apr 9, 2025):

Same issue here with local Backups

@EL-JAYY commented on GitHub (Apr 9, 2025): Same issue here with local Backups
Author
Owner

@EL-JAYY commented on GitHub (Apr 12, 2025):

i get this once the Backup Limit is reached

Image

after that the shedule won't work anymore, and i need to delete and re create it

@EL-JAYY commented on GitHub (Apr 12, 2025): i get this once the Backup Limit is reached ![Image](https://github.com/user-attachments/assets/3cc63703-0803-4757-95d4-53a4c0efb141) after that the shedule won't work anymore, and i need to delete and re create it
Author
Owner

@SirEndii commented on GitHub (Apr 22, 2025):

I am unable to reproduce this anymore on my canary installation

Image

@SirEndii commented on GitHub (Apr 22, 2025): I am unable to reproduce this anymore on my canary installation ![Image](https://github.com/user-attachments/assets/9113c245-aa29-4a8a-8cd3-65142db11e44)
Author
Owner

@Boy132 commented on GitHub (May 13, 2025):

I can't reproduce it either so I'm closing this for now.

@Boy132 commented on GitHub (May 13, 2025): I can't reproduce it either so I'm closing this for now.
Author
Owner

@TheTwoBoom commented on GitHub (Sep 13, 2025):

Hey, I also got this exact same issue
1.0.0-beta24 on Debian 12
Maybe the bug only occurs if you uploaded the schedule via the import function? (Because that's what I did)

@TheTwoBoom commented on GitHub (Sep 13, 2025): Hey, I also got this exact same issue 1.0.0-beta24 on Debian 12 Maybe the bug only occurs if you uploaded the schedule via the import function? (Because that's what I did)
Author
Owner

@TheTwoBoom commented on GitHub (Sep 13, 2025):

I'm using S3 (Cloudflare R2 to be exact)

@TheTwoBoom commented on GitHub (Sep 13, 2025): I'm using S3 (Cloudflare R2 to be exact)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/panel-pelican-dev#278