News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

How to practive moving a 1.1.21 forum

Started by von Corax, April 24, 2022, 07:21:16 PM

Previous topic - Next topic

von Corax

I've recently inherited a SMF forum running 1.1.21. I intend to upgrade, but I would like to practice the process first. Is there any possible way to install 1.1.21 on my dev box, either by cloning my prod installation or by downloading from an undocumented online repository?

Kindred

Split, since it was unrelated to the original thread.

Sure.   Follow the instructions for "moving a forum", except don't delete the old one.

As long as you can somehow find an old version of php to use
Слова
Украина

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."

Arantor

You will need an old version of PHP on your dev box if you're going to have the 1.1 running in place first - no more recent than PHP 5.4.x, and you'll ideally want something like MySQL 5.1 though I have been able to run the installer on MySQL 5.7 without it completely falling over.

von Corax

Quote from: Kindred on April 24, 2022, 07:24:02 PMSplit, since it was unrelated to the original thread.

Thank you. I had thought afterward that I should have started a new thread, but hadn't had the chance to act on it.

Quote from: Kindred on April 24, 2022, 07:24:02 PMSure.   Follow the instructions for "moving a forum", except don't delete the old one.

As long as you can somehow find an old version of php to use
Would that be the instructions here?

Kindred

Слова
Украина

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."

von Corax

Okay, I've got a copy of my forum running on Ubuntu 16.04 LTS, PHP 5.5.9 (which matches the production server) and MySQL 5.7.

When I try to post or "repair boards" I get a message "Note: It appears that your database may require an upgrade. Your forum's files are currently at version SMF 1.1.21, while your database is at version 1.1.16. The above error might possibly go away if you execute the latest version of upgrade.php."

I don't appear to have a file called upgrade.php either on the test box or the production box. Where should I look for it, and is this something I should run on production as well?

Sesquipedalian

It is worth noting that you don't actually need to get the clone of your SMF 1.x forum running on your dev machine before you can test the upgrade process. You just need a copy of the database available on a working MySQL instance on your server. Then you simply unpack the Large Upgrade package into the directory on your server where you want the forum to exist and run the upgrader by navigating to upgrade.php in your browser.

Because upgrading to a new version of SMF involves replacing all the PHP files, it doesn't matter whether the server's installed version of PHP supports the old SMF version's PHP files. It only matters whether the server's version of PHP supports the new SMF version's PHP files.

Of course, if you want to have a running clone of your SMF 1.x forum on your local server, then yes, you need to have a compatible version of PHP installed on the server. But the SMF 1.x forum doesn't need to be running in order to be upgraded; it just needs to have an intact database.
Slava Ukraini!
Heroiam slava!

I promise you nothing.

Sesqu... Sesqui... what?
Sesquipedalian, the best word in the English language.

von Corax

Quote from: Sesquipedalian on May 11, 2022, 11:53:28 AMIt is worth noting that you don't actually need to get the clone of your SMF 1.x forum running on your dev machine before you can test the upgrade process. You just need a copy of the database available on a working MySQL instance on your server. Then you simply unpack the Large Upgrade package into the directory on your server where you want the forum to exist and run the upgrader by navigating to upgrade.php in your browser.

Because upgrading to a new version of SMF involves replacing all the PHP files, it doesn't matter whether the server's installed version of PHP supports the old SMF version's PHP files. It only matters whether the server's version of PHP supports the new SMF version's PHP files.

Of course, if you want to have a running clone of your SMF 1.x forum on your local server, then yes, you need to have a compatible version of PHP installed on the server. But the SMF 1.x forum doesn't need to be running in order to be upgraded; it just needs to have an intact database.

I have it mostly running on test, as I mentioned above. I'm more concerned with the apparent version mismatch between the forum and the database, and whether this means (since it's a straight dump of the production database) that I have a similar version mismatch on my production system.

Arantor

It's unlikely to really be a mismatch. What happens is that SMF would install, imprint the install version number in the database and then assume any database error was the result of an unapplied upgrade if 'current version' is not the same as 'database version'.

But I don't believe any patch since 1.1.9 changed the database version, and more likely the error is in fact a query that no longer works properly on MySQL. It would be worth turning on the option to log database errors (so you get the query) and seeing what the actual issue is; it's almost certainly a MySQL compatibility problem if it's in the repair queries.

von Corax

After turning on error logging, I found (buried in 18 pages of deprecation warnings) the following:
Database Error: Expression #7 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'brassg_smf.ln.sent' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
File: /home/www/forum/Sources/Subs-Post.php
Line: 1410
I think I know how to fix this; I also think it lies beyond the horizon of diminishing returns, so I don't think I'll bother.

Arantor

Yeah, that's a "SMF 1.1 was written years before MySQL introduced any concept of strictness in 5.5" bug.

von Corax

The move was successful, but I'm hung up on the upgrade now. That's a separate topic, though, so I'll mark this one "Solved."

Advertisement: