Hello/Hi/Greetings,
I'm using Versio.nl as a provider. They have this Softaculous Software Suite to manager softwares and upgrades. So I had activated the auto-upgrade option for the piwigo installation on www.toonze.be. This site had 2.10.1. On 29/3 I received a mail telling me that the auto-upgrade to 2.10.2 had failed. And the auto-restore of the auto-backup too. All I had now are the errors you can see on www.toonze.be. Strange enough the pictures are still online, visiible in a few php forums left and right.
I thought I was lucky because Versio keeps backups during 60 days. So I restored files and database from the previous day. Same errors. Did the same with files and databases from 20/3/2020. Same story and same errors.
Next I tried to do a manual upgrade of Piwigo. I followed this procedure: https://piwigo.org/doc/doku.php?id=user … ion_manual
The error is still the same. And www.toonze.be/upgrade.php gives me a very white page.
So I don't get it anymore. I don't understand the warnings and errors.
This table - pauldkj249_piwi1.piwi_sessions - I don't find it anywhere. I suppose it's an old relict from an older version of piwigo?
The fatal error: no idea what's going on.
Versio won't help me (well, they want to if I pay 60 euro per hour) and the guys at Softaculous are not a great help either.
Can you help me please? Any idea what went wrong and why? How can I solve this please? You're my last resort.
Piwigo version: I suppose it's 2.10.2 as I did a manual upgrade.
PHP version: 7.3
MySQL version: 10.2.8-MariaDB
Piwigo URL: http://www.toonze.be
Last edited by Muug (2020-04-07 20:38:37)
Offline
do you have database backups?
Offline
Hi :-)
in database
CREATE TABLE `piwigo_sessions` (
`id` varchar(255) binary NOT NULL default '',
`data` mediumtext NOT NULL,
`expiration` datetime NOT NULL default '1970-01-01 00:00:00',
PRIMARY KEY (`id`)
) ENGINE=MyISAM;
Offline
executive wrote:
do you have database backups?
Yes, I did mention that I restored several database backups. And html backups too.
I could try to restore files and db from 50 days ago, but something tells me it won't solve the problem. If restoring ten day old files don't help, restoring 50 day old files won't help either.
Trying to understand the error is more important I think.
Last edited by Muug (2020-04-07 10:27:50)
Offline
ddtddt wrote:
Hi :-)
in database
CREATE TABLE `piwigo_sessions` (
`id` varchar(255) binary NOT NULL default '',
`data` mediumtext NOT NULL,
`expiration` datetime NOT NULL default '1970-01-01 00:00:00',
PRIMARY KEY (`id`)
) ENGINE=MyISAM;
I'll try this this evening!
Offline
Note that if your table prefix is not piwigo_ but piwi_ instead, as indicated by your original question, then modify the command to use the table name piwi_sessions instead of piwigo_sessions.
Offline
Hi Folks,
I created the piwi_sessions table. Thanks for the code!
Refreshed www.toonze.be.
Now it wanted a piwi_plugins table! Did it, refreshed it.
Now this is the error:
Warning: [mysql error 1054] Unknown column 'state' in 'where clause'
SELECT * FROM piwi_plugins
WHERE state='active' in /home/pauldkj249/domains/toonze.be/public_html/include/dblayer/functions_mysqli.inc.php on line 856
Fatal error: Uncaught Error: Call to a member function fetch_assoc() on bool in /home/pauldkj249/domains/toonze.be/public_html/include/dblayer/functions_mysqli.inc.php:922 Stack trace: #0 /home/pauldkj249/domains/toonze.be/public_html/include/functions_plugins.inc.php(333): query2array('\nSELECT * FROM ...') #1 /home/pauldkj249/domains/toonze.be/public_html/include/functions_plugins.inc.php(427): get_db_plugins('active') #2 /home/pauldkj249/domains/toonze.be/public_html/include/common.inc.php(142): load_plugins() #3 /home/pauldkj249/domains/toonze.be/public_html/index.php(11): include_once('/home/pauldkj24...') #4 {main} thrown in /home/pauldkj249/domains/toonze.be/public_html/include/dblayer/functions_mysqli.inc.php on line 922
But the warnings don't worry me, these are just warnings. It's the fatal error that worries me most. When I google this error I find too much hits, and there's clearly not one big solution. :-(
Is there a good php/sql-specialist around here? I really need someone that's used to investigate such errors, some kind of Sherlock Holmes... because if I can't find the solution, I'll have only one option: delete everything ! But that would screw up several travelogues I've written.
Offline
In the mean time I logged in at mysql and ran
select version();
and got
10.2.8-MariaDB
Offline
I've chosen php 7.1 for the piwigo-installation.
I'm going to reintall version 2.10.1 manually.
So a kind of roll back to the earlier version, I didn't have any problems with that one.
Next I'm going to restore the most recent files and db.
We'll see what it gives.
Offline
same story....
Offline
Hi,
I"ve got no clue why the plugins and sessions table have disappeared, if they ever existed at all.....
So I would like to replace the current faulty piwigo website with a complete new one. But I would like to retain all the picture URL's. Because my users still see them, so for them there's nothing wrong.
Is this possible and is there a procedure for this?
Offline
OK,
the site is up again.
Here's my story, as far as I've been able to reconstruct it.
After the failed auto-upgrade and failed auto-restore, I discovered that SQL had no more then 9 tables. NINE! As I don't know anything about Piwigo I didn't worry. I started this topic, and someone gave me the code to add an empty table. Then I had an error about a missing column in that empty table, then it said it missed another table, and another one, and another one..... I started to realise that 9 tables was totally wrong, it should be many more! This topic confirmed my theory: https://piwigo.org/forum/viewtopic.php?pid=162338
it shows an already incomplete list of 22 tables.
So for the first time in this investigation I just deleted EVERY table in the piwigo-database. (I had already imported this backup mysql db, but for some reason it must have never worked because I always had the same 9 tables, and thus the same error... ) And then I imported this backup (from February) of the mysql, and lo and behold my site is alive again!
It counts 33 tables!
So, in short, never trust auto-updates and auto-backup systems.
Ah, and forget getting support from Softaculous. They just pointed to my provider, while the provider just pointed to them. Yes, the provider wanted to help, at 60€/hour...
So long, and thanks for all the fish.
Offline