# Backup frequency not understood

**URL:** https://meta.discourse.org/t/backup-frequency-not-understood/349501
**Category:** Support
**Tags:** backups
**Created:** [January 29, 2025, 5:25am UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501 "2025-01-29T05:25:33Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![Wurzelseppi](https://avatars.discourse-cdn.com/v4/letter/w/eada6e/32.png) [@Wurzelseppi](https://meta.discourse.org/u/Wurzelseppi)
#### Post date: [January 29, 2025, 5:25am UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/1 "2025-01-29T05:25:33Z")

</div>

Hey guys,

these are my settings for backup at the moment:

 ![The image displays settings for automatic backups, including options to set maximum backups and days to keep, as well as enabling backups and specifying a backup frequency, with a focus on the "Remove older backups" setting with a value of 14 days. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/7/a/f/7afff35cd5c82f893a2ea8586f3c17a7bc940cb2.png)

Here you see that actual backups made (It´s a new board, thus the small backups 🙂 )

 ![The image displays a table of file names, sizes, and download buttons, all shown in a dark interface format. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/b/c/7/bc756cf196dcecfe756d06d360b873ba79403400.png)

I configured, as you can see, backup frequency “1”, but the backups are made every second day.  
Is it just, that I´m too dumb to understand it, or is it something else ?

I want daily backups! :- 😂

Thanks and Cheers,

Julian

---

<div class="post-metadata">

### Author: ![Arkshine](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/arkshine/32/298682_2.png) [@Arkshine](https://meta.discourse.org/u/Arkshine)
#### Post date: [January 29, 2025, 5:07pm UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/2 "2025-01-29T17:07:53Z")

</div>

Hey, what is your `backup_time_of_day` value? Also is it local or S3 storage?

---

<div class="post-metadata">

### Author: ![Wurzelseppi](https://avatars.discourse-cdn.com/v4/letter/w/eada6e/32.png) [@Wurzelseppi](https://meta.discourse.org/u/Wurzelseppi)
#### Post date: [January 30, 2025, 8:29am UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/3 "2025-01-30T08:29:45Z")

</div>

it´s 3:30 and it´s local because of this

> [@AWS S3 upload - unable to sign request without credentials set](https://meta.discourse.org/t/aws-s3-upload-unable-to-sign-request-without-credentials-set/342266/4):
>
> Tried now, to set up IAM User with credentials and give it s3:\* permissions, and now the upload works, but discourse can´t display it afterwards: As I´m working in a company, and there are SCP (Service control policies) active for our accounts, it seems that public access is generally blocked

Thanks 🙂

---

<div class="post-metadata">

### Author: ![Arkshine](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/arkshine/32/298682_2.png) [@Arkshine](https://meta.discourse.org/u/Arkshine)
#### Post date: [January 31, 2025, 5:02am UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/4 "2025-01-31T05:02:13Z")

</div>

I see, thanks! I was maybe thinking of some timing issue, but it doesn’t look this way.  
I will try to reproduce it. Let’s hope someone else has a better idea of what’s happening.

---

<div class="post-metadata">

### Author: ![Wurzelseppi](https://avatars.discourse-cdn.com/v4/letter/w/eada6e/32.png) [@Wurzelseppi](https://meta.discourse.org/u/Wurzelseppi)
#### Post date: [February 27, 2025, 6:36am UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/5 "2025-02-27T06:36:33Z")

</div>

It´s still the same here.

Backup Frequenceny is at “1”  
But backups are occuring only every second day ☹

---

<div class="post-metadata">

### Author: ![gerhard](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gerhard/32/119479_2.png) [@gerhard](https://meta.discourse.org/u/gerhard)
#### Post date: [March 3, 2025, 9:23pm UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/6 "2025-03-03T21:23:12Z")

</div>

Could you enter your Docker container, start the rails console, …

```plaintext
./launcher enter app
rails c

```

… run the following two lines of code …

```ruby
BackupRestore::BackupStore.create.latest_file

```

```ruby
Time.now.utc

```

… and post the output, please?

---

<div class="post-metadata">

### Author: ![Wurzelseppi](https://avatars.discourse-cdn.com/v4/letter/w/eada6e/32.png) [@Wurzelseppi](https://meta.discourse.org/u/Wurzelseppi)
#### Post date: [March 4, 2025, 8:09am UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/7 "2025-03-04T08:09:11Z")

</div>

Hey @gerhard,

here you are 🙂

```plaintext
rails c
[1] pry(main)> BackupRestore::BackupStore.create.latest_file
=> #<BackupFile:0x00007ff6c5ed79e8 @filename="community-2025-03-04-033214-v20250220090521.tar.gz", @last_modified=2025-03-04 02:32:19.790859841 UTC, @size=43521649, @source=nil>
[2] pry(main)> Time.now.utc
=> 2025-03-04 08:07:17.128857559 UTC

```

Last Backups:

 ![The image displays a list of five tar.gz files with download buttons next to them, each ranging in size from 38.3 MB to 41.5 MB. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/4/d/e/4de1fb7ff052a3fc72ce42f06b43d774afe94ab7.png)

The setting is still:

![The image shows a settings window displaying a field labeled "Backup frequency" with the input "1" and an accompanying tooltip explaining the setting. (Captioned by AI)](https://global.discourse-cdn.com/meta/optimized/4X/5/2/c/52c3522910f791f26083a4e97e37bec1336223f3_2_690x41.png)

Cheers WS

---

<div class="post-metadata">

### Author: ![gerhard](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gerhard/32/119479_2.png) [@gerhard](https://meta.discourse.org/u/gerhard)
#### Post date: [March 6, 2025, 1:58pm UTC](https://meta.discourse.org/t/backup-frequency-not-understood/349501/8 "2025-03-06T13:58:09Z")

</div>

Thanks, okay, I see the issues.

There’s a daily background job that runs [at 00:00](https://github.com/discourse/discourse/blob/3837657449cc56cf932fa069b6654e6d25edcc26/app/jobs/scheduled/schedule_backup.rb#L5) and enqueues a backup job for a later time. But [this condition](https://github.com/discourse/discourse/blob/3837657449cc56cf932fa069b6654e6d25edcc26/app/jobs/scheduled/schedule_backup.rb#L15) most likely isn’t true for daily backups, so it’s skipped.

And the fact that we are adding some [jitter](https://github.com/discourse/discourse/blob/3837657449cc56cf932fa069b6654e6d25edcc26/app/jobs/scheduled/schedule_backup.rb#L21) to the actual start of the backup doesn’t help either.

I consider this a bug that we should fix.
