Page 1 of 1

Upgrade from 2.8.1 to 3.0.2 - database error

Posted: Thu May 07, 2020 8:50 am
by ppasch
i try to upgrade my faq from 2.8.1 to 3.0.2 following intructions given in the documentation :
I delete all files except:
- database.php in the directory config/
- all files in the directory assets/template/
- the directory attachments/
- the directory data/
- the directory images/
Copy the 3.0.2 source files in my existing faq dir.

When I run the setup/update.php, I've got the folling database error :
The connection to the database server could not be established.
The error message of the database server:

I use a postgresql 9.6 database.
I've checked the logs (postgresql/apache), nothing appear.

Could you please help me ?
Thanks a lot.

Re: Upgrade from 2.8.1 to 3.0.2 - database error

Posted: Fri May 08, 2020 5:08 am
by Thorsten

please try to enable the debug log in src/Bootstrap.php and check if there are more errors.


Re: Upgrade from 2.8.1 to 3.0.2 - database error

Posted: Tue May 12, 2020 2:29 pm
by ppasch
Hi Thorsten,
thanks for the tip, it pointed me out that the $DB['port'] variable was missing in my database.php file.
Now i can launch my update process but in step 3, I've got the foollowing error:

Fatal error: Uncaught TypeError: Return value of phpMyFAQ\Configuration::delete() must be of the type bool, resource returned in /var/www/phpmyfaq/src/phpMyFAQ/Configuration.php:444 Stack trace: #0 /var/www/phpmyfaq/setup/update.php(358): phpMyFAQ\Configuration->delete('cache.varnishEn...') #1 {main} thrown in /var/www/phpmyfaq/src/phpMyFAQ/Configuration.php on line 444

I can't delete row in faqconfig table, my database user has the rights to delete on that table.

Thanks for help.