Preventing ZenPhoto from Removing Metadata from Database

Let's say some hypothetical user, lets's call him "Cygon," carefully builds a huge curated and tagged gallery of all the photos, textures, comic pages and whatnot on his NAS with ZenPhoto.

This user then accidentally changes the ownership of his 'albums' folder to a group ZenPhoto can't access and opens ZenPhoto.

Now ZenPhoto "synchronises" the database with the 'albums' folder. And by synchronise I mean it cleans out each and every tag, album description and metadata ever created without asking or even telling the user.

How could this user prevent ZenPhoto from doing that in the future?
Can it be configured to only add image metadata but never delete it on its own?


  • acrylian Administrator, Developer

    The gallery part of Zenphoto is entirely file system based and syncing the database with what is actually on the file system (not vice versa) is the core feature. This allows the simple upload via FTP to folders. This feature cannot be disabled.

    The actutal image metadata (EXIF/IPTC) is by nature included in the image itself if Zenphoto reads it so it will re-read it as soon it can access the albums and images again.

    Of course all data added manually (we don't call that meta data actually) and not embedded will be lost or overwritten by the meta data import (like titles or descriptions if set for example)

    So the first "that user" (;)) should do is perform frequent backups. There is an included plugin. If all albums and images are still thereafter repairing/resetting the messed up permissions all data could be restored.

    I hope this helps a bit.

  • I see.

    For those of us who do use ZenPhoto more like a traditional gallery (at least in terms of tagging images and adding descriptions), it would certainly be nice if ZenPhoto could avoid outright destroying the data of images that have disappeared.

    For example, a missing image could just be flagged as 'gone'. If it reappears, the 'gone' flag is cleared again. And if the user does a garbage collection, only then all images flagged as 'gone' get wiped from the database.

    Oh well, backups it is then.

  • acrylian Administrator, Developer

    I do understand. But how often do these permission changes occur in "real life"? ;-)

    This automatic syncing is the core special behaviour of Zenphoto allowing uploading loads of images/albums directly on the file system.The manual garbage collection is an extra that you normally should not have to use since all is done automatically.

    However if you don't visit the site, neither front or backend, the automatic syncing will not occur. So if you can avoid that…

    Another way is to have all the necessary data embedded right into your images. There is also way to export meta data to a XMP meta data sidecar file that can be read via the XMPmetadata plugin. But for images only and not albums.

Sign In or Register to comment.