nextcloud / photos

📸 Your memories under your control
GNU Affero General Public License v3.0
586 stars 62 forks source link

Albums lose all content. Only Empty Albums remain. #2677

Open ebildebil opened 1 month ago

ebildebil commented 1 month ago

Describe the bug All albums lose all their entries/contents. The album itself shows, however, it's empty when clicked.

To Reproduce Not sure How to, since it has happened twice in the last 6-9 months. However, the effect it has is very significant since lot of time spent in making albums is lost.

Expected behavior Photo Albums should be reliable and not go empty.

Screenshots See below

Desktop (please complete the following information):

Smartphone (please complete the following information):

I have a dedicated server, on which I run Nextcloud AIO and, photos, recognize, imagianry, preview genarator and memories. In general all used to works well. We create a lot of albums in Photos/Memories. All our media is stored on a 2 different NAS, and the folder(s) is mounted into Nextcloud via the External Folders Feature. I mount the folders via /etc/fstab entry and use SMB/CIFS. The files paths, Never change. This is the second time it happens, that we have accessed memories, and while I see all the albums, they have ZERO pictures in it. ![Image](https://github.com/user-attachments/assets/9e1a56e9-5213-41fe-8e26-c82c064e7de9) Since files get added externally, I have a periodic cron jobs running Nextcloud files scan, and also memories Index. `*/10 * * * * docker ps --format "{{.Names}}" | grep -q "^nextcloud-aio-nextcloud$" && docker exec --user www-data nextcloud-aio-nextcloud php occ files:scan --all` `*/15 * * * * docker ps --format "{{.Names}}" | grep -q "^nextcloud-aio-nextcloud$" && docker exec --user www-data nextcloud-aio-nextcloud php occ memories:index` Everything is connected via lan and 10G switches, however I am guessing, it could be that if there is an intermittent network disconnection (unlikley, but possible) memories loses all info, but I can see all photos and videos in the Timeline. I initially thought that may be if the `nextcloud files:scan -all` runs when the network is down, then it removes files, and when they get readded the `fileid` changes and therefore I lose all media in Albums? However, when I SSH into the server and cd/ls the mount point folder, it did not give me erros like **- stale file handles**, which happen when a share goes down. In a discussion with maintainer of Memories, his view was that `-all` should not cause entries to disappear. Do you think this is normal? I don't experience this issue on, as eg: Photoprism instance, using the same media repository. (Unused for a while since I moved to Nextcloud/Photos/Memories) **adding newly seen error** Did not show when accessing empty album in Memories, but shows when accessing in Photos. *Also, noticed that all face recognition data is gone as well.* ``` Error | index | ExceptionOCA\Photos\Album\AlbumFile::__construct(): Argument #2 ($name) must be of type string, null given, called in /var/www/html/apps/photos/lib/Album/AlbumMapper.php on line 250 in file '/var/www/html/apps/photos/lib/Album/AlbumFile.php' line 32 -- | -- | -- ``` **Additional context** I have already reached out to below with no solution: Memories Maintainer: https://github.com/pulsejet/memories/issues/1287 Nextxloud AIO: https://github.com/nextcloud/all-in-one/discussions/5242 Nextcloud Help: https://help.nextcloud.com/t/photos-and-memories-lose-all-albums-content/204056