Jump to content

Topic on Project:Support desk

Upgrade from MW 10.0 running on XP

5
Peter Andersson A (talkcontribs)

Hi!

I was asked to move/upgrade an old MediaWiki 10.0 from 2007 running on Windows XP to a supported system by the company i work for. (This is my first time working with MW.)

So the plan is getting it running on Windows Server 2022. But after trying to export the DB and the files (as i read somewhere to do) to the new server, it recognized there was an old site, but, well it failed.. (surprise)

Any idea how to do this in so short steps as possible?

Bawolff (talkcontribs)

Try doing the upgrade in steps - mw 1.27 first, then the latest version.


Beyond that, could you describe how it failed? Any error messages?

Peter Andersson A (talkcontribs)

Ok to 1.27 first then..


This is the errors i got: After detection of the old site i clicked upgrade and then it runs for a couple of seconds until it finds it't missig a table or column, i added the missing table or column to the DB (based of the info i found here) then it runs for a couple of second untill another table or column is missing and so on. after all is done, is said the upgrade was successful but when i reload the site i get: "Sorry! This site is experiencing technical difficulties." i added some rows to the localsettings.php to get some more info and that's provided below.


Deprecated: Return type of MediaWiki\Session\PHPSessionHandler::open($save_path, $session_name) should either be compatible with SessionHandlerInterface::open(string $path, string $name): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\PHPSessionHandler.php on line 181

Deprecated: Return type of MediaWiki\Session\PHPSessionHandler::close() should either be compatible with SessionHandlerInterface::close(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\PHPSessionHandler.php on line 196

Deprecated: Return type of MediaWiki\Session\PHPSessionHandler::read($id) should either be compatible with SessionHandlerInterface::read(string $id): string|false, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\PHPSessionHandler.php on line 210

Deprecated: Return type of MediaWiki\Session\PHPSessionHandler::write($id, $dataStr) should either be compatible with SessionHandlerInterface::write(string $id, string $data): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\PHPSessionHandler.php on line 238

Deprecated: Return type of MediaWiki\Session\PHPSessionHandler::destroy($id) should either be compatible with SessionHandlerInterface::destroy(string $id): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\PHPSessionHandler.php on line 344

Deprecated: Return type of MediaWiki\Session\PHPSessionHandler::gc($maxlifetime) should either be compatible with SessionHandlerInterface::gc(int $max_lifetime): int|false, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\PHPSessionHandler.php on line 365

Deprecated: Message implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in D:\inetpub\wwwroot\mediawiki_new\includes\language\Message.php on line 138

Deprecated: MapCacheLRU implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in D:\inetpub\wwwroot\mediawiki_new\includes\libs\MapCacheLRU.php on line 36

Deprecated: strcasecmp(): Passing null to parameter #1 ($string1) of type string is deprecated in D:\inetpub\wwwroot\mediawiki_new\includes\session\CookieSessionProvider.php on line 99

Deprecated: Return type of MediaWiki\Session\Session::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 603

Deprecated: Return type of MediaWiki\Session\Session::current() should either be compatible with Iterator::current(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 609

Deprecated: Return type of MediaWiki\Session\Session::next() should either be compatible with Iterator::next(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 621

Deprecated: Return type of MediaWiki\Session\Session::key() should either be compatible with Iterator::key(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 615

Deprecated: Return type of MediaWiki\Session\Session::valid() should either be compatible with Iterator::valid(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 633

Deprecated: Return type of MediaWiki\Session\Session::rewind() should either be compatible with Iterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 627

Deprecated: Return type of MediaWiki\Session\Session::offsetExists($offset) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 643

Deprecated: Return type of & MediaWiki\Session\Session::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 656

Deprecated: Return type of MediaWiki\Session\Session::offsetSet($offset, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 666

Deprecated: Return type of MediaWiki\Session\Session::offsetUnset($offset) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in D:\inetpub\wwwroot\mediawiki_new\includes\session\Session.php on line 671

Sorry! This site is experiencing technical difficulties.

Try waiting a few minutes and reloading.

(Cannot access the database)

Backtrace:

#0 D:\inetpub\wwwroot\mediawiki_new\includes\libs\rdbms\loadbalancer\LoadBalancer.php(991): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()

#1 D:\inetpub\wwwroot\mediawiki_new\includes\libs\rdbms\loadbalancer\LoadBalancer.php(963): Wikimedia\Rdbms\LoadBalancer->getServerConnection()

#2 D:\inetpub\wwwroot\mediawiki_new\includes\libs\rdbms\loadbalancer\LoadBalancer.php(1128): Wikimedia\Rdbms\LoadBalancer->getConnection()

#3 D:\inetpub\wwwroot\mediawiki_new\includes\GlobalFunctions.php(2229): Wikimedia\Rdbms\LoadBalancer->getMaintenanceConnectionRef()

#4 D:\inetpub\wwwroot\mediawiki_new\includes\cache\localisation\LCStoreDB.php(57): wfGetDB()

#5 D:\inetpub\wwwroot\mediawiki_new\includes\cache\localisation\LocalisationCache.php(448): LCStoreDB->get()

#6 D:\inetpub\wwwroot\mediawiki_new\includes\cache\localisation\LocalisationCache.php(494): LocalisationCache->isExpired()

#7 D:\inetpub\wwwroot\mediawiki_new\includes\cache\localisation\LocalisationCache.php(413): LocalisationCache->initLanguage()

#8 D:\inetpub\wwwroot\mediawiki_new\includes\cache\localisation\LocalisationCache.php(332): LocalisationCache->loadSubitem()

#9 D:\inetpub\wwwroot\mediawiki_new\includes\language\Language.php(2611): LocalisationCache->getSubitem()

#10 D:\inetpub\wwwroot\mediawiki_new\includes\cache\MessageCache.php(1056): Language->getMessage()

#11 D:\inetpub\wwwroot\mediawiki_new\includes\cache\MessageCache.php(1014): MessageCache->getMessageForLang()

#12 D:\inetpub\wwwroot\mediawiki_new\includes\cache\MessageCache.php(956): MessageCache->getMessageFromFallbackChain()

#13 D:\inetpub\wwwroot\mediawiki_new\includes\language\Message.php(1379): MessageCache->get()

#14 D:\inetpub\wwwroot\mediawiki_new\includes\language\Message.php(903): Message->fetchMessage()

#15 D:\inetpub\wwwroot\mediawiki_new\includes\language\Message.php(993): Message->format()

#16 D:\inetpub\wwwroot\mediawiki_new\includes\title\MalformedTitleException.php(55): Message->text()

#17 D:\inetpub\wwwroot\mediawiki_new\includes\title\MediaWikiTitleCodec.php(92): MalformedTitleException->__construct()

#18 D:\inetpub\wwwroot\mediawiki_new\includes\title\MediaWikiTitleCodec.php(399): MediaWikiTitleCodec::{closure}()

#19 D:\inetpub\wwwroot\mediawiki_new\includes\Title.php(3093): MediaWikiTitleCodec->splitTitleString()

#20 D:\inetpub\wwwroot\mediawiki_new\includes\Title.php(493): Title->secureAndSplit()

#21 D:\inetpub\wwwroot\mediawiki_new\includes\MediaWiki.php(88): Title::newFromURL()

#22 D:\inetpub\wwwroot\mediawiki_new\includes\MediaWiki.php(161): MediaWiki->parseTitle()

#23 D:\inetpub\wwwroot\mediawiki_new\includes\MediaWiki.php(891): MediaWiki->getTitle()

#24 D:\inetpub\wwwroot\mediawiki_new\includes\MediaWiki.php(564): MediaWiki->main()

#25 D:\inetpub\wwwroot\mediawiki_new\index.php(53): MediaWiki->run()

#26 D:\inetpub\wwwroot\mediawiki_new\index.php(46): wfIndexMain()

#27 {main}

Bawolff (talkcontribs)

Some of the warnings make me think that your version of php is too new for mediawiki 1.27. Which version of php are you using?


For the actual error, in LocalSettings.php, do you have any custom config related to Localisation Cache?


Generally you shouldn't add tables/columns yourself unless something is going wrong. Is the updater not adding them itself?

Peter Andersson A (talkcontribs)

Hi!

The PHP version is 8.1.2 and the MW is 1.37.1, this is a little bit why i'm thinking of starting all over, i't maybe to new and a bit to large jump from 1.10.0..

I found this: Manual:Upgrading#Adapt your LocalSettings.php that says it's needed to be done in steps. 1.10 -> 1.27 -> 1.37 (or do i need 1.35 in between?)

Another thought, this wiki is only saved for archive purposes and viewing, do i really need to upgrade it for it to run on Windows Server 2022?


Thanks,

Peter

Reply to "Upgrade from MW 10.0 running on XP"