2

I am trying to sync my Mac (macOS 11.2.3) "Pictures" folder with my NAS using Synology Drive. I receive an error message stating that photos.sqlite-shm cannot be synced due to missing access rights or because the file is in use.

However, I cannot even find this file. What is it and where is it? It sounds like it has something to do with iOS. Thank you!

2
  • Synology Drive is a syncing tool - is that correct? Great for files, not so good for complex objects like the Photos Library. If you need to synchronise your Photos library with other apple devices, better to use iCloud. If it is backup, use Time Machine to your NAS.
    – Gilby
    Commented Apr 5, 2021 at 22:45
  • Now I understand, that the culprit was part of "Photos Library.photoslibrary" which I did not want to sync anyways. Luckily, simply moving this package to another path resolved the issue! (other files within the package started causing problems, too)
    – Cerd
    Commented Apr 6, 2021 at 10:28

2 Answers 2

0

This is a legitimate database that backs Photos content on macOS (and probably tvOS, iOS, iPadOS).

It's inside the "Package" that is your Photos Library and you can have more than one Library with Photos, so the name can vary.

If you look inside your Pictures folder (~/Pictures) you can use the Finder Go menu to go to this location once you know what your library is named. For me it's "Photos Library.photoslibrary"

photos library in Finder

The real question comes next. Why does this sync process not work and why would it not tell you to quit the Photos app or grant permissions. By default, macOS will not let any program access photos, contacts and more and the program has to "ask" to get permission.

unix permissions on the folder

Above you can see the "unix" permissions for the files in question.

The where is this is easy - the what's really broken? is harder to guess. Also - we might need you to ask a follow on question that explains where your research led if the idea of a home folder / permissions granted or unix permissions isn't relevant or helpful - I would rather not assume you're an expert or a beginner without a little more context.

In summary - you may not even want to sync the Photos library since not all the photos in there might be stored in a way the sync tool expects. Can you just store your photos in a folder / export them or do you intend this to be a two way process that makes both databases stay in sync no matter how a photo arrives in the Photos app?

2

If the Photos app is open on your Mac it opens photos.sqlite-shm. You can see what files Photos has open using Activity monitor. For me it is ~/Pictures/Photos Library.photoslibrary/database/Photos.sqlite-shm

Thus your sync process is correctly saying that the file is in use

Your process thus has to make sure that Photos.app is not running.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .