Warning... ...Photos.sqlite.lock' because it is being used by another process

Hi,

I am running Duplicati (2.3.0.3 - 2.3.0.3_stable_2026-06-10) on Mac , Tahoe 26.5.1. I run two jobs every day. Both jobs backup same files to different destinations with 15 min difference.

Every day i see this warning for both jobs:

Warning while running ALL Files >>> OMV

2026-06-24 01:18:01 -05 - [Warning-Duplicati.Library.Main.Operation.Backup.FileBlockProcessor.FileEntry-FileProcessingFailed]: Failed to process path: /Users/USERNAME/Pictures/Photos Library.photoslibrary/database/Photos.sqlite.lock IOException: The process cannot access the file ‘/Users/USERNAME/Pictures/Photos Library.photoslibrary/database/Photos.sqlite.lock’ because it is being used by another process.

Photos is not running or open.

So, questions:

  1. Its a warning. Can I/ should i just ignore it?

  2. Are photos backed up? From what i read, Photos.sqlite contains no photos and does not need to be backed up

  3. A forum post from 2024 suggests:

If I set these flags, i could miss things that ARE important… right?

Thoughts? Suggestions apreciated.

Tks in advance,

P

Hi @Phamiltonsmith, welcome to the forum :waving_hand:

You can ignore it. The Photos.sqlite database is internal to Apple Photos and will be recreated if you delete it anyway.

You can add an exclude filter to exclude the Photos library, like this:

-*/Photos Library.photoslibrary/

Yes, in 2.3 Photos are backed up directly (see below).
Photos.sqlite does not include any photos, just some metadata for the Photos app.

You can set --ignore-advisory-locking to work around the warning. The downside to this is that Duplicati will read files while they are in use. If you are unlucky and read the file while it is being written, it may be in a non-usable state when you attempt to restore it.

With 2.3.0.3 you can also choose how to handle the MacOS Photos. Use the option --photos-handling and set it to one of:

  • LibraryOnly: Don’t attempt to communicate with MacOS Photos and treat the folder as a regular folder (how it was in 2.2 and earlier)
  • PhotosOnly: Don’t read the local Photos.sqlite and other files in there. Instead ask MacOS to list all Photos, and then make backups of the actual Photos.
  • PhotosAndLibrary: Default; Get both the photos and the local files.

If you do not want to back up Photos, use the exclude filter I showed earlier.
If you do want to back up Photos, set --photos-handling=PhotosOnly.

The default is a bit useless, but since this is a new feature and some may have relied on the old behavior, we opted for the safest default.

The reason for this special handling is that MacOS does not store all photos locally, it stores some thumbnails etc, and then when you view a photo, it will fetch it from iCloud. To actually back up Photos, Duplicati needs to ask MacOS to list the photos found in iCloud and then read them; this is what the option --photos-handling controls.

Thanks for a FASSST reply! :slight_smile: and for the detailed explanation!

I have gone with your suggestion thus:

image

Also, thanks to those involved for an amazing tool…

Been using Duplicati for about a month… I used to be a time machine user :hot_face: … I got sick and tired of my backup disks being filled many times over and worse, the constant fails.

P