nixys / nxs-backup

The tool for creating, delivering and rotating backups for GNU/Linux distributions.
https://nxs-backup.io
Apache License 2.0
256 stars 13 forks source link

issue with rotation s3 #79

Closed JoJoBizarrio closed 2 months ago

JoJoBizarrio commented 3 months ago

We have below settings:

  - storage_name: s3 - its yandex.cloud
    backup_path: nxs-backup/path
    retention:
      days: 1
      weeks: 0
      months: 1

, but instead of delete yesteday copy nxs-backup try delete day before yesterday, for example:

today is 11-08-2024, nxs-backup removed 09-08-2024: INFO [2024-08-11 03:44:05.044]jobName-desc-files File 'nxs-backup/path/daily/name_2024-08-09_05-51.tar.gz' going to be deleted

so we have rotation, like:

  - storage_name: s3
    backup_path: nxs-backup/path
    retention:
      days: 2
      weeks: 0
      months: 2

also logs havent notes about removing monthly copies

grep -r nxs-backup/path/monthly | wc -l
0
randreev1321 commented 3 months ago

Hi, @JoJoBizarrio.

today is 11-08-2024, nxs-backup removed 09-08-2024:

Looks strange, will definitely check this case. Can you tell me what timezone is configured on the server?

also logs havent notes about removing monthly copies

Monthly copies are created on the 1st, they are rotated through the creation process, so you won't see these events in the log.

DrDrepin commented 3 months ago

Hi, our server timezone is Europe/Moscow (MSK, +0300).

Do you have any ideas what this problem might be related to?

randreev1321 commented 3 months ago

Yes, it looks like a time zone issue.

randreev1321 commented 2 months ago

Hi @JoJoBizarrio @DrDrepin.

Fixes addressing the described problem were released with the 3.12.0.

If you have any other questions, we will be glad to help you.