FDB creates 2 backup folders

While a daily backup process, FDB 5.1.7 creates 2 backup folders - a new with current date and a new with date a few days ago. Same was yesterday and today:

  • backup-2022-04-19-15-44-17.331837 (a full cluster backup, Restorable: true)
  • backup-2022-04-17-17-46-07.921570 (some logs folders)
tree backup-2022-04-17-17-46-07.921570/
backup-2022-04-17-17-46-07.921570/
├── logs
│   └── 0000
│       └── 0421
│           ├── log,42164609195664,42164629195664,b7fd280e9105031eacbdcb35fcb0018c,1048576
│           ├── log,42164629195664,42164650000000,cb82cdd432210e870606eb47ab47f1fb,1048576
│           ├── log,42164650000000,42164671000000,3c8fb2a5b08da943cefc37e2a5c8ee0c,1048576
│           ├── log,42164671000000,42164692000000,40f5aa1875b208f4bd1ba23b61139523,1048576
│           ├── log,42164692000000,42164708348333,3fd955836ec27fe0f66d00eeff2f3cb3,1048576
│           ├── log,42164708348333,42164729000000,6fea747079263b882ea2a3cba75dcc52,1048576
│           ├── log,42164729000000,42164750000000,937a81081312ce213b3e16ac31e46945,1048576
│           ├── log,42164750000000,42164750532279,8d74ed8ea5471f12efa20e53472fc1a7,1048576
│           ├── log,42164750532279,42164770532279,49a61a3ab24614830087e7c5bd9f4166,1048576
│           ├── log,42164770532279,42164790532279,f30d961795a0e8aa532e4fd023a4a24c,1048576
│           ├── log,42164790532279,42164810532279,ffa89424d294c8358545b6aa15a3f0dc,1048576
│           ├── log,42164810532279,42164830532279,bea0ef21a893cfb20e067d1864140472,1048576
│           └── log,42164830532279,42164850532279,f31a065625a73b4e708d19c329b90a27,1048576
└── properties
    ├── log_begin_version
    └── log_end_version

4 directories, 15 files

From log file

<Event Severity="10" Time="1650405284.567897" Type="FSyncParentDir" Machine="10.183.81.197:19004" ID="0000000000000000" Folder="/opt/foundationdb/backups/files/backup-2022-04-17-17-46-07.921570/logs/0000/0421" File="/opt/foundationdb/backups/files/backup-2022-04-17-17-46-07.921570/logs/0000/0421/log,42164609195664,42164629195664,b7fd280e9105031eacbdcb35fcb0018c,1048576.de4f4d819fdc404cbc2f0a0cd57f5b9f.temp" logGroup="default"/>	
<Event Severity="10" Time="1650405284.548259" Type="AFCUnderlyingSize" Machine="10.183.81.197:19004" ID="0000000000000000" filename="/opt/foundationdb/backups/files/backup-2022-04-17-17-46-07.921570/logs/0000/0421/log,42164609195664,42164629195664,b7fd280e9105031eacbdcb35fcb0018c,1048576.de4f4d819fdc404cbc2f0a0cd57f5b9f.temp" size="0" logGroup="default"/>
<Event Severity="10" Time="1650405284.548259" Type="AFCUnderlyingOpenEnd" Machine="10.183.81.197:19004" ID="0000000000000000" filename="/opt/foundationdb/backups/files/backup-2022-04-17-17-46-07.921570/logs/0000/0421/log,42164609195664,42164629195664,b7fd280e9105031eacbdcb35fcb0018c,1048576.de4f4d819fdc404cbc2f0a0cd57f5b9f.temp" logGroup="default"/>
<Event Severity="10" Time="1650405284.547900" Type="AFCUnderlyingOpenBegin" Machine="10.183.81.197:19004" ID="0000000000000000" filename="/opt/foundationdb/backups/files/backup-2022-04-17-17-46-07.921570/logs/0000/0421/log,42164609195664,42164629195664,b7fd280e9105031eacbdcb35fcb0018c,1048576.de4f4d819fdc404cbc2f0a0cd57f5b9f.temp" logGroup="default"/>

I didn’t get how to fix it

Are you running continuous backups, i.e., with -z option? If so, the backup will continuously create new backups and you can choose to delete old backup files by expire command.

No, it isn’t continuous backup

fdbbackup start -d file://{{ fdb_backup_files }} -t {{ backup_time }}

Every backup contains not only the kv pairs but also the mutations occured while the backup was running.

The difference is that an ordinal backup stops just after it has made the backup set restorable, but -z backup continues running.

This should only create one timestamp-named backup directory and write ranges and logs into it until the range set is complete and the log set covers the entire version range of the range file set.

I’m not sure why a second timestamped backup directory is being created in your situation. The timestamp used is chosen when the backup is submitted, so I don’t see how a second timestamp would be chosen later.

25th April but FDB still creates /backup-2022-04-17-17-46-07.921570 folder :frowning: