ZenphotoCMS Forum
Refresh database in latest nighty build - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: General support (https://forum.zenphoto.org/forum-4.html)
+--- Thread: Refresh database in latest nighty build (/thread-11483.html)

Pages: 1 2


Refresh database in latest nighty build - sphoto - 16-11-2013

"Refresh the Database" does not work as I would expect. Because it reset all records in the images table, e.g. the title becomes image name, the sorting is gone, the link to the tags does not work anymore and... This is not a garbage collection, it's a kind of a reset function! If this behaviour is correct, please rename the button!




Refresh database in latest nighty build - sbillard - 16-11-2013

The button does just what it's title says.

It examines the database, removes orphaned records (ones where the file no longer exists). It also cleans up invalid records such as those where the file name starts with a slash or has double slashes, etc.

If some of those invalid records did contain your titles, etc. then they may well have been discarded. But they were not valid records to start with.

You can, of course, restore your database from a backup and manually fix those records.




Refresh database in latest nighty build - sphoto - 16-11-2013

The previous release (1.4.5.5) did what you said. But now, zp deletes every record (independed if it's valid or not) and writes a new one. All the manually entered text is gone (like image titles etc). Since the old image id's does not exist anymore, all links to the 'obj_to_tag' table become invalid! That's really bad.




Refresh database in latest nighty build - sbillard - 17-11-2013

Does not do that for me. Have to assume then that your database entries were corrupt and that cleaning up the corruption resulted in this.

Again--reload from your backup (you did make one, didn't you?) and manually correct the database entries.




Refresh database in latest nighty build - acrylian - 17-11-2013

I just tried and I also cannot reproduce this behaviour.




Refresh database in latest nighty build - EricBD - 17-11-2013

I have exactly the same problem, using dynamic albums.
I use tu re-enter after each refresh the title of each image and also the album title.

If i have "Musées du Monde" as dynamic album, i rename it as "musees" for example, then after i meet the problem.




Refresh database in latest nighty build - acrylian - 17-11-2013

Are you sure you use the "database refresh" and not the "meta data refresh". The 2nd might do this as it re-reads the EXIF etc metadata again.




Refresh database in latest nighty build - EricBD - 17-11-2013

Yes, "Actualiser la Base de données" in french. The Metadata refresh never worked for me. Each time he "scan" my more than 1000 images todo nothing.




Refresh database in latest nighty build - acrylian - 17-11-2013

Well, if your images don't have meta data or stored them off the standard (which some programs do) that would be correct.




Refresh database in latest nighty build - EricBD - 17-11-2013

Oh, no... My images have metadata, i just told that i have the same problem. Then since i stop use the dynamic albums.

Can you specify "good" metadata for you ?




Refresh database in latest nighty build - acrylian - 17-11-2013

I cannot specify "good metadata" as there is no such. Some programs use EXIF/IPTC fields not as defined in the official standards. But we follow those standards naturally.

Anway, this is for sure not your issue and I can only repeat what sbillard already said above. I cannot reproduce any issues.




Refresh database in latest nighty build - sbillard - 17-11-2013

Let us be perfectly clear.

Refresh database (garbage collect) does not cause any metadata refresh directly. But certainly if the garbage collect detects flawed database records and removes and then Zenphoto re-discovers the album the database record will be recreated correctly.

Quote:If i have "Musées du Monde" as dynamic album, i rename it as "musees" for example, then after i meet the problem.
There are two possibilities here since you were far from clear as to what you did. If you renamed the folder on your file system then Zenphoto would consider it a new album of course.

It is also possible that your file system has difficulties with files with diacritical marked characters. This is often the case when the file system is UTF-8 and you have not told Zenphoto.




Refresh database in latest nighty build - sphoto - 18-11-2013

I probably found the reason for this behaviour. Following situations:

ZP 1.4.5.5
Press "Set as thumbnail for" in edit images in the backend-> ZP generates wrong records in album/images table (leading/trailing slashes in names) -> remove them manually in the DB -> ZP generates new invalid records, when I view the gallery again

Update from 1.4.5.5 to 1.4.5.7 (last build from github)

First try:
Starting setup process to update to new version (no errors) -> Album/images table looks ok -> View gallery -> Album/images table completely rewritten (new id’s, all manual text gone, link to tags table become invalid, etc)

Second try:
Starting setup process to update to new version (no errors) -> Album/images table looks ok -> remove just the invalid album records with leading or trailing slashes in DB manually and leave images table untouched -> View gallery -> Album/images tables are untouched by ZP, everything looks good -> Press "Refresh the Database": ZP found the wrong image records and removed them -> DB ok (no invalid records), Gallery look ok

It seems that ZP has problems with DB records containing leading/trailing slashes in albums. In this case it rewrites the entire album/images table, at least on my system...




Refresh database in latest nighty build - acrylian - 18-11-2013

there was an serious issue with diacritical marks in 1.4.5.6 which is why we release 1.4.5.7 one day after it. There was also an issue with trailing slashes that should not be there in certain places.

Please create a ticket so sbillard more easily sees it later.




Refresh database in latest nighty build - sbillard - 18-11-2013

Quote:It seems that ZP has problems with DB records containing leading/trailing slashes in albums. In this case it rewrites the entire album/images table, at least on my system...
Perhaps you missed it the first time I told you that this was the problem. And maybe you missed it again the second time. And maybe again the third time....

Also you seem to miss the normal suggestion that if you are having a problem you should at least try to see if the support build corrects it. You can do this either by installing it or by perusing the changes to the release to see if anything fits.




Refresh database in latest nighty build - flu - 21-11-2013

Hi guys,
I've got the same problem with some albums name in my DB, Zenphoto adds a slash before some of them.
As suggested, I remove them manually because they only appear in the search results.
I've noticed that they are created at the same time than the regular named albums.

Zenphoto 1.4.5.7
MySQLi : 5.1.67
PHP : 5.3.22
encoding : fr_FR.UTF8

This is weird. I'd like to prevent it to happen again.




Refresh database in latest nighty build - acrylian - 21-11-2013

As noted on this topic this was an issue in 1.4.5.6 that has been corrected in 1.4.5.7.




Refresh database in latest nighty build - sbillard - 21-11-2013

We would like this not to happen as well. We think the problem is fixed, but if that is not case we need sufficient information to know where the error ins occurring.




Refresh database in latest nighty build - flu - 21-11-2013

Well, guys,
as mentioned above, my ZP version is a 1.4.5.7 one (updated step by step from a 1.4.5.2 fresh installation).
Stephen, as mentioned above, I gave some informations about my settings,
here they are again :
Zenphoto 1.4.5.7 [59c22b2fba]
MySQLi : 5.1.67
PHP : 5.3.22
encoding : fr_FR.UTF8
theme : lightly modified ZPskeleton

would you mind saying to me what do you need to go further ?




Refresh database in latest nighty build - sbillard - 21-11-2013

Need to know under what circumstances these bad entries are created.

So, after you have cleaned your database manually, what was it that causes a new wrong item to appear?