Update both wikis to latest version (1.43.3 right now).
Add link to the subpage in README.md
| Sebastian_Berlin-WMSE | |
| Jul 2 2025, 7:54 AM |
Update both wikis to latest version (1.43.3 right now).
Add link to the subpage in README.md
| Status | Subtype | Assigned | Task | ||
|---|---|---|---|---|---|
| Resolved | Viktoria_Hillerud_WMSE | T398400 Update MW on producer and demo servers | |||
| Resolved | Viktoria_Hillerud_WMSE | T401989 Create subpage that explains steps of updating MW on servers |
When updating the producer wiki, I had two problems:
The logs generated from the error was:
/wiki/Special:PluggableAuthLogin PHP Fatal Error from line 68 of /var/www/mediawiki-1.43.1/extensions/WSOAuth/src/AuthenticationProvider/MediaWikiAuth.php: Declaration of WSOAuth\AuthenticationProvider\MediaWikiAuth::setLogger(Psr\Log\LoggerInterface $logger) must be compatible with WSOAuth\AuthenticationProvider\AuthProvider::setLogger(Psr\Log\LoggerInterface $logger): void #0 [internal function]: MWExceptionHandler::handleFatalError()
We then create a symlink pointing to the currently active version, for example: /var/www/mediawiki → /var/www/mediawiki-1.43.3
This can be created like so, e.g:
# Step 1: Remove the old symlink sudo rm /var/www/mediawiki # Step 2: Create a new symlink pointing to the upgraded version sudo ln -s mediawiki-1.43.3 /var/www/mediawiki
I realise that some of the steps I just had in my head and it would be good to write them down. I think we could put it on Underhåll av tekniska system. Maybe as a subpage if it gets big and/or we want to have it in English. There should probably also be a file on the server itself called UPGRADE-WIKI or something that just links there.
@Viktoria_Hillerud_WMSE, could you create that and add the steps you went through? Including how you solved issues that occurred.
Add link to the subpage in README.md
I'm not sure what README.md this refers to. The important thing is that it's somewhere it's easily noticeable for the person who does the update. That could be in the MW-directory (you may not look there too closely since it's the old one), the parent directory of the MW-directory or in the message of the day (a new file in /etc/update-motd.d/).
I am leaning on putting a README.md in /var/www/html on both servers. Because there is the usual place I have user to download and unpack new versions of MW. But I am also into putting it in update-motd.d/ but that requires I write a script right? I have never used this kind "Message of the day"
I think a readme in /var/www/html sound good.
You can add it to MOTD too, but I'd say that's secondary. I.e. if it turns out to be too much work you can skip it.
Now I added both a README.md and a MOTD in both servers. It was fun to make a MOTD script even if this one was pretty easy :)
I'd make the files readable by everyone. They don't contain any secrets and you save having to sudo.
I think it makes more sense to put the file on the producer wiki in /var/www/ since you shouldn't need to do anything in html/ there. Also, the second line looks like this in that file:
This file exists as a complement to the official UPGRADE file included in MediaWiki, because our environment includes custom setups and exceptions th>
Looks like it was copied from somewhere where the whole line wasn't shown.
I didn't see the MOTD when I logged in to either server. As I said, this isn't a big deal so I think we can skip it.
Ok! I think and hope it is fixed now. Wierd that the MOTD didn't show, because it was shown when I tried it when implementing, but when I logged in now it indeed did not show..