Project:Support desk

About this board

Welcome to MediaWiki.org's Support desk, where you can ask MediaWiki questions!

There are also other places where to ask :

Before you post

Post a new question

  1. To help us answer your questions, please always indicate which versions you are using (reported by your wiki's Special:Version page):
    • MediaWiki
    • PHP
    • Database
  2. Please include the URL of your wiki unless you absolutely can't. It's often a lot easier for us to identify the source of the problem if we can look for ourselves.
  3. To start a new thread, click "Start a new topic".
Previous page history was archived for backup purposes at Project:Support_desk/old on 2015-07-30.
Other languages: English  العربية čeština Esperanto français 日本語 中文
Auri1230 (talkcontribs)

Hello. I am having trouble setting up my own wiki. I have downloaded MediaWiki and when it was fully downloaded, it came with files like Vendors, images, skins, which I can't understand. Can someone at least create the wiki for me, or at least give me clear, basic instructions. I would like to create a wiki called Factpedia- the free encyclopedia. factpedia.org

Malyacko (talkcontribs)

For the start, please provide a link to the installation guide which you are following, and tell us at which exact sentence you are stuck and why. It's hard to help if nobody knows the problem. :)

For "can someone create the wiki for me", see Professional development and consulting.


Auri1230 (talkcontribs)

I downloaded this version: mediawiki-134.0. It just comes in weird files that doesn't tell you to create a wiki.

Reply to "Wiki trouble"

How do I hide IPs from a [view edits] page?

2
Nyawdawdawd (talkcontribs)

Sorry, first time on media wiki so I'm not too sure.

Malyacko (talkcontribs)

If you meant "View History": You don't. :) Which underlying problem would be solved by hiding IPs?

Reply to "How do I hide IPs from a [view edits] page?"
182.239.180.188 (talkcontribs)

(Scarcely a new topic, but I don't seem to be able to add to previous posts)

I am upgrading to 1.32.1 on Fedora 30, having done a fresh install on a new server, but using the (upgraded) database from the previous version, 1.26 of F24. I have the LocalSettings.php file in my wiki folder, in my case /var/www/wiki, alongside index.php etc. After running through all the previous answers to this problem, checking permissions, SELinux, etc, I tracked the call to LocalSettings to includes/WebStart.php, and found it was looking for it in the install dir, /usr/share/mediawiki. I added a soft link there back to the "proper" LocalSettings.php and all was fine.

So I don't really have a question, except "Is this how it should work ?" - I rather gather not - and I thought I should pass on the experience.

John

Ciencia Al Poder (talkcontribs)

That's probably a problem on Fedora package.

MediaWiki is usually placed directly on the web server root and not on a totally unrelated folder.

2601:18A:C401:307C:5EEB:B79F:F84A:B998 (talkcontribs)

John - thank you for your post. I had the same issue, upgrading from Fedora 29/ MediaWiki 1.29 to F30 and MW 1.32.1. Installed at the root - /var/www/html. Your softlink idea fixed the issue for me as well. I have no idea if that is how it is supposed to be, but I read this will cause issues with people that run multiple wiki's on the same server.

KazuyoshiFurutaka (talkcontribs)

It seems that the problem is caused by the change in the following statements in includes/WebStart.php, from

IP = getenv( 'MW_INSTALL_PATH' );

if ( $IP === false ) {

        $IP = realpath( '.' ) ?: dirname( __DIR__ );

}

to

IP = getenv( 'MW_INSTALL_PATH' );

if ( $IP === false ) {

        $IP = dirname( __DIR__ );

}


Without realpath('.'), the files can NOT work with symlinks and can NOT easily shared by multiple wikis on a single site (because $IP is NOT set correctly).

Indeed, I have a few mediawiki wikis on a single machine running Fedora 30, and after updating to 1.32.2 rpm they don't run.

Could you put the realpath('.') statement back ???

Thanks in advance.

Kazuyoshi

Ciencia Al Poder (talkcontribs)

You can set the MW_INSTALL_PATH environment variable in apache so it finds the correct path. See the SetEnv Apache directive.

KazuyoshiFurutaka (talkcontribs)
Ciencia Al Poder (talkcontribs)

I don't know how is your "wiki farm" set up, so it will largely depend on how do you define different settings for each wiki

240F:80:B046:1:69EF:D187:FC64:FDDA (talkcontribs)

Very simple.

There're several wiki directories under /var/www/wiki (e.g. /var/www/wiki/wikiA, /var/www/wiki/wikiB, ...) and there's a LocalSettings.php in each directory; mediawiki files in the common /usr/share/mediawiki directory are shared via simlinks.

(I'm afraid a single httpd configuration (say MW_INSTALL_PATH) is shared by the wikis)

Kazuyoshi

Ciencia Al Poder (talkcontribs)

Set MW_INSTALL_PATH to /usr/share/mediawiki, and WIKI_PATH to wikiA in the first case, or wikiB in the second, and then inside the LocalSettings of /usr/share/mediawiki require_once('/var/www/wiki/' . $_ENV['WIKI_PATH'] . '/LocalSettings.php');

KazuyoshiFurutaka (talkcontribs)

By the way, what are the reasons of the removal?

Kazuyoshi

Ciencia Al Poder (talkcontribs)
98.194.73.219 (talkcontribs)

See bugzilla 1718580, specifically (DaveG 2019-07-14 02:14:09 UTC). I cannot include the link so posting the basics here. This is FC30 specific and addin to what Ciencia already pointed out,

Add a Directory entry for each wiki to /etc/httpd/conf.d/mediawiki.conf like below and restart httpd.

<Directory /some/wiki/dir>

    SetEnv MW_INSTALL_PATH "/some/wiki/dir"

    AllowOverride None

    Require all granted

</Directory>

If you get an error 500 after and are upgrading, check /var/log/php-fpm/www-error.log as it's probably choking loading something not included with the latest build. Remove it from LocalSettings.php and it should work.

165.225.60.127 (talkcontribs)

I too struggled with the FC30 changes in mediawiki. And, thanks to Johns comments am back and running again. This had me stumped for several weeks since I just did not have the time to research it. Now, something that worked for the past 10 years was broken in FC30, with no clear information on how to fix it -- is very sad.

I am also trying to now figure out how to run multiple wikis and that is broken. Ciencia Al Poder -- appreciate your comments, but they are too terse for the normal person. May help those who do not need help and can figure it out with a few hints. Will greatly appreciate the code fragments and in which files.. I just tried to do it in mediawiki.conf found in /etc/httpd/conf/conf.d -- but failed.


ram

Reply to "LocalSettings.php Not Found"

Can i confirm the nature of this error please.

8
AlgorithmGG (talkcontribs)

Am I getting this error because MW is not caching on localhost?


MediaWiki internal error.


Original exception: [Xh6Y0nA5RPxpLTSqRWeA5gAAAA0] /index.php/Special:Random Wikimedia\Rdbms\DBConnectionError from line 1380 of /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php: Cannot access the database: Unknown error (localhost)

Backtrace:

#0 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(931): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()

#1 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(898): Wikimedia\Rdbms\LoadBalancer->getServerConnection(integer, string, integer)

#2 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(1043): Wikimedia\Rdbms\LoadBalancer->getConnection(integer, array, string, integer)

#3 /home/dgo/public_html/includes/GlobalFunctions.php(2576): Wikimedia\Rdbms\LoadBalancer->getMaintenanceConnectionRef(integer, array, string)

#4 /home/dgo/public_html/includes/cache/localisation/LCStoreDB.php(56): wfGetDB(integer)

#5 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(441): LCStoreDB->get(string, string)

#6 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(487): LocalisationCache->isExpired(string)

#7 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(363): LocalisationCache->initLanguage(string)

#8 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(304): LocalisationCache->loadItem(string, string)

#9 /home/dgo/public_html/languages/Language.php(4413): LocalisationCache->getItem(string, string)

#10 /home/dgo/public_html/languages/Language.php(265): Language::getFallbacksFor(string)

#11 /home/dgo/public_html/languages/Language.php(225): Language::newFromCode(string)

#12 /home/dgo/public_html/includes/ServiceWiring.php(163): Language::factory(string)

#13 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(458): Wikimedia\Services\ServiceContainer->{closure}(MediaWiki\MediaWikiServices)

#14 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(427): Wikimedia\Services\ServiceContainer->createService(string)

#15 /home/dgo/public_html/includes/MediaWikiServices.php(540): Wikimedia\Services\ServiceContainer->getService(string)

#16 /home/dgo/public_html/includes/Setup.php(801): MediaWiki\MediaWikiServices->getContentLanguage()

#17 /home/dgo/public_html/includes/WebStart.php(81): require_once(string)

#18 /home/go/public_html/index.php(41): require(string)

#19 {main}


Exception caught inside exception handler: [Xh6Y0nA5RPxpLTSqRWeA5gAAAA0] /index.php/Special:Random Wikimedia\Rdbms\DBConnectionError from line 1380 of /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php: Cannot access the database: Unknown error (localhost)

Backtrace:

#0 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(931): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()

#1 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(898): Wikimedia\Rdbms\LoadBalancer->getServerConnection(integer, string, integer)

#2 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(1043): Wikimedia\Rdbms\LoadBalancer->getConnection(integer, array, string, integer)

#3 /home/dgo/public_html/includes/GlobalFunctions.php(2576): Wikimedia\Rdbms\LoadBalancer->getMaintenanceConnectionRef(integer, array, string)

#4 /home/dgo/public_html/includes/cache/localisation/LCStoreDB.php(56): wfGetDB(integer)

#5 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(386): LCStoreDB->get(string, string)

#6 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(304): LocalisationCache->loadItem(string, string)

#7 /home/dgo/public_html/languages/Language.php(4413): LocalisationCache->getItem(string, string)

#8 /home/dgo/public_html/languages/Language.php(265): Language::getFallbacksFor(string)

#9 /home/dgo/public_html/languages/Language.php(225): Language::newFromCode(string)

#10 /home/dgo/public_html/includes/ServiceWiring.php(163): Language::factory(string)

#11 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(458): Wikimedia\Services\ServiceContainer->{closure}(MediaWiki\MediaWikiServices)

#12 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(427): Wikimedia\Services\ServiceContainer->createService(string)

#13 /home/dgo/public_html/includes/MediaWikiServices.php(540): Wikimedia\Services\ServiceContainer->getService(string)

#14 /home/dgo/public_html/includes/ServiceWiring.php(440): MediaWiki\MediaWikiServices->getContentLanguage()

#15 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(458): Wikimedia\Services\ServiceContainer->{closure}(MediaWiki\MediaWikiServices)

#16 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(427): Wikimedia\Services\ServiceContainer->createService(string)

#17 /home/dgo/public_html/includes/MediaWikiServices.php(738): Wikimedia\Services\ServiceContainer->getService(string)

#18 /home/dgo/public_html/includes/cache/MessageCache.php(115): MediaWiki\MediaWikiServices->getMessageCache()

#19 /home/dgo/public_html/includes/exception/MWExceptionRenderer.php(310): MessageCache::singleton()

#20 /home/dgo/public_html/includes/exception/MWExceptionRenderer.php(51): MWExceptionRenderer::reportOutageHTML(Wikimedia\Rdbms\DBConnectionError)

#21 /home/dgo/public_html/includes/exception/MWExceptionHandler.php(121): MWExceptionRenderer::output(Wikimedia\Rdbms\DBConnectionError, integer)

#22 /home/dgo/public_html/includes/exception/MWExceptionHandler.php(195): MWExceptionHandler::report(Wikimedia\Rdbms\DBConnectionError)

#23 /home/dgo/public_html/includes/exception/MWExceptionHandler.php(167): MWExceptionHandler::handleException(Wikimedia\Rdbms\DBConnectionError)

#24 [internal function]: MWExceptionHandler::handleUncaughtException(Wikimedia\Rdbms\DBConnectionError)

#25 {main}

Malyacko (talkcontribs)

Why would you think that "Cannot access the database: Unknown error (localhost)" could be related to caching, instead of your database? Please clearly elaborate on your path of thoughts.

Ciencia Al Poder (talkcontribs)

The problem is about the database connection. Check the database settings and be sure the database server is operational. One of the first things MediaWiki does is to cache/retrieve from cache some localization stuff, that's stored by default on database. As you may expect, an error connecting to the database will cause this error.

AlgorithmGG (talkcontribs)

These lines here etc:


#17 /home/dgo/public_html/includes/MediaWikiServices.php(738): Wikimedia\Services\ServiceContainer->getService(string)

#18 /home/dgo/public_html/includes/cache/MessageCache.php(115): MediaWiki\MediaWikiServices->getMessageCache()

#19 /home/dgo/public_html/includes/exception/MWExceptionRenderer.php(310): MessageCache::singleton()

#

@Malyacko


Thanks @Ciencia Al Poder


It happens when i am downloading from the server.

AlgorithmGG (talkcontribs)

I am still occasionally getting this error even when I am not downloading from the server.


MediaWiki internal error.


Original exception: [XiTt@Cv9O9bj@vqOrJ5QIgAAAAc] /index.php?search=infobox&title=Special%3ASearch&go=Go Wikimedia\Rdbms\DBConnectionError from line 1380 of /home/dennisgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php: Cannot access the database: Unknown error (localhost)

Backtrace:

#0 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(931): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()

#1 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(898): Wikimedia\Rdbms\LoadBalancer->getServerConnection(integer, string, integer)

#2 /home/dennisgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(1043): Wikimedia\Rdbms\LoadBalancer->getConnection(integer, array, string, integer)

#3 /home/dgo/public_html/includes/GlobalFunctions.php(2576): Wikimedia\Rdbms\LoadBalancer->getMaintenanceConnectionRef(integer, array, string)

#4 /home/dgo/public_html/includes/cache/localisation/LCStoreDB.php(56): wfGetDB(integer)

#5 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(441): LCStoreDB->get(string, string)

#6 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(487): LocalisationCache->isExpired(string)

#7 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(363): LocalisationCache->initLanguage(string)

#8 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(304): LocalisationCache->loadItem(string, string)

#9 /home/dgo/public_html/languages/Language.php(4413): LocalisationCache->getItem(string, string)

#10 /home/dgo/public_html/languages/Language.php(265): Language::getFallbacksFor(string)

#11 /home/dgo/public_html/languages/Language.php(225): Language::newFromCode(string)

#12 /home/dgo/public_html/includes/ServiceWiring.php(163): Language::factory(string)

#13 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(458): Wikimedia\Services\ServiceContainer->{closure}(MediaWiki\MediaWikiServices)

#14 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(427): Wikimedia\Services\ServiceContainer->createService(string)

#15 /home/dgo/public_html/includes/MediaWikiServices.php(540): Wikimedia\Services\ServiceContainer->getService(string)

#16 /home/dgo/public_html/includes/Setup.php(801): MediaWiki\MediaWikiServices->getContentLanguage()

#17 /home/dsgo/public_html/includes/WebStart.php(81): require_once(string)

#18 /home/dsgo/public_html/index.php(41): require(string)

#19 {main}


Exception caught inside exception handler: [XiTt@Cv9O9bj@vqOrJ5QIgAAAAc] /index.php?search=infobox&title=Special%3ASearch&go=Go Wikimedia\Rdbms\DBConnectionError from line 1380 of /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php: Cannot access the database: Unknown error (localhost)

Backtrace:

#0 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(931): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()

#1 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(898): Wikimedia\Rdbms\LoadBalancer->getServerConnection(integer, string, integer)

#2 /home/dgo/public_html/includes/libs/rdbms/loadbalancer/LoadBalancer.php(1043): Wikimedia\Rdbms\LoadBalancer->getConnection(integer, array, string, integer)

#3 /home/dgo/public_html/includes/GlobalFunctions.php(2576): Wikimedia\Rdbms\LoadBalancer->getMaintenanceConnectionRef(integer, array, string)

#4 /home/dgo/public_html/includes/cache/localisation/LCStoreDB.php(56): wfGetDB(integer)

#5 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(386): LCStoreDB->get(string, string)

#6 /home/dgo/public_html/includes/cache/localisation/LocalisationCache.php(304): LocalisationCache->loadItem(string, string)

#7 /home/dgo/public_html/languages/Language.php(4413): LocalisationCache->getItem(string, string)

#8 /home/dgo/public_html/languages/Language.php(265): Language::getFallbacksFor(string)

#9 /home/dgo/public_html/languages/Language.php(225): Language::newFromCode(string)

#10 /home/dgo/public_html/includes/ServiceWiring.php(163): Language::factory(string)

#11 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(458): Wikimedia\Services\ServiceContainer->{closure}(MediaWiki\MediaWikiServices)

#12 /home/dennisgo/public_html/includes/libs/services/ServiceContainer.php(427): Wikimedia\Services\ServiceContainer->createService(string)

#13 /home/dennisgo/public_html/includes/MediaWikiServices.php(540): Wikimedia\Services\ServiceContainer->getService(string)

#14 /home/dennisgo/public_html/includes/ServiceWiring.php(440): MediaWiki\MediaWikiServices->getContentLanguage()

#15 /home/dennisgo/public_html/includes/libs/services/ServiceContainer.php(458): Wikimedia\Services\ServiceContainer->{closure}(MediaWiki\MediaWikiServices)

#16 /home/dgo/public_html/includes/libs/services/ServiceContainer.php(427): Wikimedia\Services\ServiceContainer->createService(string)

#17 /home/dgo/public_html/includes/MediaWikiServices.php(738): Wikimedia\Services\ServiceContainer->getService(string)

#18 /home/dgo/public_html/includes/cache/MessageCache.php(115): MediaWiki\MediaWikiServices->getMessageCache()

#19 /home/dgo/public_html/includes/exception/MWExceptionRenderer.php(310): MessageCache::singleton()

#20 /home/dgo/public_html/includes/exception/MWExceptionRenderer.php(51): MWExceptionRenderer::reportOutageHTML(Wikimedia\Rdbms\DBConnectionError)

#21 /home/dgo/public_html/includes/exception/MWExceptionHandler.php(121): MWExceptionRenderer::output(Wikimedia\Rdbms\DBConnectionError, integer)

#22 /home/dgo/public_html/includes/exception/MWExceptionHandler.php(195): MWExceptionHandler::report(Wikimedia\Rdbms\DBConnectionError)

#23 /home/dgo/public_html/includes/exception/MWExceptionHandler.php(167): MWExceptionHandler::handleException(Wikimedia\Rdbms\DBConnectionError)

#24 [internal function]: MWExceptionHandler::handleUncaughtException(Wikimedia\Rdbms\DBConnectionError)

#25 {main}

AlgorithmGG (talkcontribs)

Also getting this error with Mysql which I am currently troubleshooting has anybody encountered this? are there any reports of a search index bug?


[ERROR] mysqld: Table './mwdatabase/searchindex' is marked as crashed and should be repaired

Ciencia Al Poder (talkcontribs)
AlgorithmGG (talkcontribs)

Ta! for the info, at the moment its repairing its self i need to fix the underlining issue. I never experienced this before the migration.

Reply to "Can i confirm the nature of this error please."
185.183.60.158 (talkcontribs)

Hey everyone,

I want to upgrade my old Mediaiwki (V.1.21) at the newest version (V.1.34). (I use a DebianLinux where I install the new version). I searched on the site of mediawiki for upgrade my wiki (Manual:Upgrading/fr) and i found the patch.

I think it's the best solution for this upgrade ! But.. it will be so long to do every patch manually.

So Is someone know a script for make all install or another solution, please ?

Ciencia Al Poder (talkcontribs)

If for patch do you mean a patch file (differencies between one version and other), don't do that. The patch is only available to upgrade from one minor version to another.

Instead, you should download the new version (full), extract on a new empty directory, copy LocalSettings.php from the old one, download any missing extensions you had from the old install, and then make that directory your current published wiki. If your uploads are on a directory outside the installation files you don't have to worry about them, otherwise move it to the new location.

Don't forget to run the "update.php" script

185.183.60.158 (talkcontribs)

oh... Okay ?

My idea was to create a Debian with the old version and past step by step the patch (until the version 1.34). After, create an other Debian with the last version and make a dump of the old database in the newest... it's really not possible to do it like that ?

I try you're idea !

Thanks !

185.183.60.158 (talkcontribs)

*your

sorry, my bad

Ciencia Al Poder (talkcontribs)

Possible? Yes, but there's no benefit in doing that. The entire contents of the wiki are on the database, and the uploaded files. You don't need a working MediaWiki installation to migrate it to a new server. Just take a backup of the database and restore it on the new server, transfer the uploads, and install/upgrade on the new server. See Manual:Moving a wiki

Reply to "Upgrade from 1.21 at 1.34"
136.49.134.179 (talkcontribs)

I am trying to move my wiki to another server and upgrade to 1.33.1 from version 1.23.6- I downloaded mediawiki version 1.33.1 to my new server, created a new database, and moved the old database back up to the new wiki database using

mysql -u wikidb_user -p wikidb < dump_of_wikidb.sql

I also moved LocalSettings.php from the old wiki to the new wiki and changed the

$wgDBtype       

$wgDBserver     

$wgDBname     

$wgDBuser       

$wgDBpassword 

fields to match the new database.

When I try and run update.php, I get a MediaWiki internal error:

[9ec31f1099e6c45e34cc8d47] [no req]   Wikimedia\Rdbms\DBConnectionError from line 1213 of /tmp/mediawiki-1.33.1/includes/libs/rdbms/loadbalancer/LoadBalancer.php: Cannot access the database: Unknown error (10.34.33.155)

Backtrace:

#0 /tmp/mediawiki-1.33.1/includes/libs/rdbms/loadbalancer/LoadBalancer.php(758): Wikimedia\Rdbms\LoadBalancer->reportConnectionError()

#1 /tmp/mediawiki-1.33.1/includes/GlobalFunctions.php(2637): Wikimedia\Rdbms\LoadBalancer->getConnection(integer, array, boolean)

#2 /tmp/mediawiki-1.33.1/maintenance/Maintenance.php(1375): wfGetDB(integer, array, boolean)

#3 /tmp/mediawiki-1.33.1/maintenance/update.php(147): Maintenance->getDB(integer)

#4 /tmp/mediawiki-1.33.1/maintenance/doMaintenance.php(96): UpdateMediaWiki->execute()

#5 /tmp/mediawiki-1.33.1/maintenance/update.php(275): require_once(string)

#6 {main}


Why is connection not working? I am able to connect through mysql manually with the fields I put in LocalSettings.php

Bawolff (talkcontribs)

you're sure you are using the exact same info when connecting manually? (Mysql can be tricky, access can be per host so connecting from a different server is not the same thing. For that matter, connecting to localhost is considered different than connecting to 127.0.0.1, and so on)

136.49.134.179 (talkcontribs)

yes, using the same info - the info in LocalSettings.php is

$wgDBtype           = "mysql";

$wgDBserver         = "10.34.33.155";

$wgDBname           = "wikidb";

$wgDBuser           = "wikidb_user";


and the command I use to connect with mysql is:

mysql -h 10.34.33.155 -u wikidb_user -p


and I use the password specified in LocalSettings.php. But when I run SELECT DATABASE() after connecting through mysql, it returns null unless I connect with mysql -h 10.34.33.155 -u wikidb_user -p wikidb

170.248.143.23 (talkcontribs)

The issue was in the version of mysql that I am using - version 8.0.4 has a new authentication plugin : caching_sha2_password, which was not present in earlier versions. To connect you can downgrade mysql version or run

ALTER USER 'wikidb_user'@'10.34.33.155' IDENTIFIED WITH mysql_native_password BY 'password';

Reply to "update to 1.33.1"
Michelandre (talkcontribs)

- OS: NethServer-7.6.1810

● MediaWiki 1.31.6 (c168a3f)

● PHP 7.2.26 (fpm-fcgi) (from nethserver-php-scl)

● MariaDB 10.2.22-MariaDB (from nethserver-rh-mariadb102)

● ICU 62.1

● Semantic MediaWiki 3.1.1

● CharInsert - (b5f34be)

● MsUpload 12.0 (d854ddf)

● ParserFunctions 1.6.0 (a28ad04)

- node v6.17.1

- npm 3.10.10

- parsoid 0.11.0 / 2019-12-20

- VisualEditor 0.1.0 (c3c9140)


MediaWiki and Semantic are working correctly, create, edit etc...


- I installed and adjusted VisualEditor according to: https://www.howtoforge.com/tutorial/how-to-install-visualeditor-for-mediawiki-on-centos-7/


● Why VisualEditor can starts correctly when I create a new file but gives  when I want to save it: HTTP 500?


● When I edit a file, VisualEditor does’t start "Error loading data from server: apierror-visualeditor-docserver-http: HTTP 500. Would you like to retry?"?


● Jan 19 01:32:59 server-name node: {"name":"parsoid","hostname":"server-name/domain-name","pid":2621,"level":60,"err":{"message":"","name":"lib/index.js","stack":"AccessDeniedError: Your wiki requires a logged-in account to access the API.\n    at AccessDeniedError (/opt/parsoid/lib/mw/ApiRequest.js:214:3)\n    at ConfigRequest._handleJSON (/opt/parsoid/lib/mw/ApiRequest.js:920:13)\n    at ConfigRequest.ApiRequest._logWarningsAndHandleJSON (/opt/parsoid/lib/mw/ApiRequest.js:447:7)\n    at ConfigRequest.ApiRequest._handleBody (/opt/parsoid/lib/mw/ApiRequest.js:483:7)\n    at ConfigRequest.ApiRequest._requestCB (/opt/parsoid/lib/mw/ApiRequest.js:420:8)\n    at Request.request [as _callback] (/opt/parsoid/lib/mw/ApiRequest.js:332:35)\n    at Request.self.callback (/opt/parsoid/node_modules/request/request.js:185:22)\n    at emitTwo (events.js:106:13)\n    at Request.emit (events.js:191:7)\n    at Request.<anonymous> (/opt/parsoid/node_modules/request/request.js:1157:10)\n    at emitOne (events.js:96:13)\n    at Request.emit (events.js:188:7)\n    at IncomingMessage.<anonymous> (/opt/parsoid/node_modules/request/request.js:1079:12)\n    at IncomingMessage.g (events.js:292:16)\n    at emitNone (events.js:91:20)\n    at IncomingMessage.emit (events.js:185:7)\n    at endReadableNT (_stream_readable.js:978:12)\n    at _combinedTickCallback (internal/process/next_tick.js:80:11)\n    at process._tickCallback (internal/process/next_tick.js:104:9)","httpStatus":401,"levelPath":"fatal/request"},"msg":"Your wiki requires a logged-in account to access the API.","time":"2020-01-19T06:32:59.867Z","v":0}


● What user should I create? // "Your wiki requires a logged-in account to access the API."


Michel-André

Reply to "VirsualEditor & error 500"
River5000 (talkcontribs)

Are the parts of text that appear on a wiki page as a result of Transclusion considered for that page's on-page SEO? Or for purposes of on-page SEO would it only appear as {{:Example_article}}. Thank you.

Ciencia Al Poder (talkcontribs)

Transclusion displays the contents of another page or template where they're used. That has nothing to do with SEO (if by SEO do you mean Search Engine Optimization, of course)

River5000 (talkcontribs)

So when search engine crawlers are checking a page for keywords they will not see the keywords in transcluded text, and will instead see "{{:Example_article}}"?

Ciencia Al Poder (talkcontribs)

Search engines see rendered text, not wikitext, just like your visitors.

River5000 (talkcontribs)

Perfect. Thank you! :)

Reply to "On-page SEO and Transclusions"
Summary by NH35

Problem solved.

NH35 (talkcontribs)

After restoring the backup, when I trying to send the photo a message appears: The path at which the stashed file should have been found was invalid. How to fix it?

Malyacko (talkcontribs)

@NH35 What does "send the photo" mean exactly? Which MediaWiki version? Do you use UploadWizard or the classic upload page?

NH35 (talkcontribs)

MW 1.28, upload photo via UploadWizard in article editing (VE) classic upload working fine.

Bawolff (talkcontribs)

Do you have permissions in the image directory set appropriately? Are you overriding $wgUploadDirectory, $wgUploadStashScalerBaseUrl, or $wgUploadPath in LocalSettings.php, if so is it something reasonable?

NH35 (talkcontribs)

The problem appeared after restoring the backup. I think the problem is in chmod.

Tunglinwu (talkcontribs)

as title

My mediawiki version is 1.33.1

MarkAHershberger (talkcontribs)

Which page does not update? Do you have the job queue running?

Tunglinwu (talkcontribs)

Special:WantedPages

It's not update when page create or not need.

I have no job queue

I meet this error after edit templete, I change link in it.


AhmadF.Cheema (talkcontribs)
Tunglinwu (talkcontribs)

I ruu it, it says Job queue is empty.

And show notice:

PHP Notice:  Undefined index: SERVER_NAME in ./includes/GlobalFunctions.php on line 1376

PHP Notice:  Undefined index: SERVER_NAME in ./includes/GlobalFunctions.php on line 1376


MarkAHershberger (talkcontribs)

It still isn't clear to me what you mean when you say that the page does not update.

What, exactly, does the page display? What do you think it should display?

Tunglinwu (talkcontribs)

I think it not exist on Special:WantedPages .

e.g. I edit page and remove link to page A. (A had not be create and only this page need.)

But Special:WantedPages still show it for a long time.


Ciencia Al Poder (talkcontribs)

Does Special:WhatLinksHere/A (where A is the page that doesn't exist) display any page?

Tunglinwu (talkcontribs)
Ciencia Al Poder (talkcontribs)

The wanted pages special page is generated from the information on Special:WhatLinksHere.

If Special:WhatLinksHere is wrong, then you have a problem with the Manual:Job queue. See Manual:How to debug and enable a debug log, then null-edit the page that contains (or doesn't contain) that link and see if the log displays any error.