News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Database version upgrade question

Started by Jailer, November 26, 2024, 04:26:07 PM

Previous topic - Next topic

Jailer

I've run into a brick wall here of my own doing. I haven't kept my database up to date and now I'm in a situation where I seem to have no upgrade path.

I'm currently running my forum with mysql 5.6 in a FreeBSD jail. I need to upgrade my database but a direct upgrade to either mysql 8.0 or Mariadb 10.5 is not supported. Those are the only options I have as older versions of mysql and mariadb are no longer available to install. I've tried both anyway and of course the upgrade fails and the forum is unable to connect to the database. I've even tried a fresh jail and loading a database dump in a fresh install for both and it still fails.

Is there any way forward for this or am I just out of luck?

Doug Heffernan

Quote from: Jailer on November 26, 2024, 04:26:07 PMI've run into a brick wall here of my own doing. I haven't kept my database up to date and now I'm in a situation where I seem to have no upgrade path.

I'm currently running my forum with mysql 5.6 in a FreeBSD jail. I need to upgrade my database but a direct upgrade to either mysql 8.0 or Mariadb 10.5 is not supported. Those are the only options I have as older versions of mysql and mariadb are no longer available to install. I've tried both anyway and of course the upgrade fails and the forum is unable to connect to the database. I've even tried a fresh jail and loading a database dump in a fresh install for both and it still fails.

Is there any way forward for this or am I just out of luck?

Hello,

Are you seeking to either hire someone or find some to help you for free, or are you simply asking for support about this? I am asking because it's a bit unclear to me. If the former you are in the right board, if the letter this will have to be moved to the support board.

Illori

when you do the upgrade of your database engine, are you checking that the port etc for connecting are correct?

What is repair_settings.php?

this should help you make sure they are correct.

Jailer

Quote from: Doug Heffernan on November 26, 2024, 04:45:02 PM
Quote from: Jailer on November 26, 2024, 04:26:07 PMI've run into a brick wall here of my own doing. I haven't kept my database up to date and now I'm in a situation where I seem to have no upgrade path.

I'm currently running my forum with mysql 5.6 in a FreeBSD jail. I need to upgrade my database but a direct upgrade to either mysql 8.0 or Mariadb 10.5 is not supported. Those are the only options I have as older versions of mysql and mariadb are no longer available to install. I've tried both anyway and of course the upgrade fails and the forum is unable to connect to the database. I've even tried a fresh jail and loading a database dump in a fresh install for both and it still fails.

Is there any way forward for this or am I just out of luck?

Hello,

Are you seeking to either hire someone or find some to help you for free, or are you simply asking for support about this? I am asking because it's a bit unclear to me. If the former you are in the right board, if the letter this will have to be moved to the support board.

Looking to see if someone has any insight they can share. It's not a SMF problem at all but I figured there are sure to be plenty of knowledgeable people here. That's why I posted where I did. If I can't get any help I'll probably have to hire someone to help or let the board die.

Quote from: Illori on November 26, 2024, 04:58:10 PMwhen you do the upgrade of your database engine, are you checking that the port etc for connecting are correct?

What is repair_settings.php?

this should help you make sure they are correct.

The database connection settings are correct, both in the settings.php file and what is displayed by repair_settings.php. The only thing with it that looks amiss is the section where it displays Paths & URLs For Themes is blank so something obviously doesn't migrate over properly.


Kindred

That indicates a failure to connect to the database,  since the theme info is pulled from the db
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Jailer

Well the database log doesn't show any errors but there is this tidbit in the nginx error log.

2024/11/26 15:22:01 [error] 25659#101611: *1 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught TypeError: mysqli_error(): Argument #1 ($mysql) must be of type mysqli, null given in /usr/local/www/nginx/Sources/Errors.php:456
Stack trace:
#0 /usr/local/www/nginx/Sources/Errors.php(456): mysqli_error(NULL)
#1 /usr/local/www/nginx/Sources/Subs-Db-mysql.php(101): display_db_error()
#2 /usr/local/www/nginx/Sources/Load.php(3697): smf_db_initiate('redacted DB user and password info, Array)
#3 /usr/local/www/nginx/index.php(94): loadDatabase()
#4 {main}
  thrown in /usr/local/www/nginx/Sources/Errors.php on line 456" while reading response header from upstream, client: 192.168.0.210, server: test.mlcnfriends.com, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm.sock:", host: "192.168.0.4"


Jailer

Quote from: Doug Heffernan on November 27, 2024, 04:09:56 PMWhat version of Smf are you using?

2.1.4

I'm beginning to think this is a larger problem, likely with FreeBSD. I tried upgrading a wordpress instance that is in a separate jail from mariadb 10.3 to 10.5 and it failed as well. Even restoring from a database dump failed too. That should have been a direct upgrade path and it didn't work.

I may have to go over to the FreeBSD forums and try to post for help there. I am reluctant to do so as they are not very receptive to helping people that are at a lower knowledge level than they are which unfortunately I am.

Jailer

Quick update. I managed to get it figured out but I still don't know why it worked before the database upgrade but not after.

So I managed to navigate the database upgrade process. What ended up working in the end was changing 'localhost' to '127.0.0.1' in Settings.php. Once that change was made everything is back up and working and the database upgrade worked.

Still stumped as to why but just glad that it's working now.

Advertisement: