Page MenuHomePhabricator

Database error while running update.php
Closed, DeclinedPublic

Description

[2fa4a2b8925f0a50001b624b] [no req] InvalidArgumentException from line 455 of /volume1/web/mediawiki/includes/libs/rdbms/database/Database.php: Wikimedia\Rdbms\Database::getClass no viable database extension found for type 'mysql'
Backtrace:
#0 /volume1/web/mediawiki/includes/libs/rdbms/database/Database.php(351): Wikimedia\Rdbms\Database::getClass(string, NULL)
#1 /volume1/web/mediawiki/includes/libs/rdbms/loadbalancer/LoadBalancer.php(1079): Wikimedia\Rdbms\Database::factory(string, array)
#2 /volume1/web/mediawiki/includes/libs/rdbms/loadbalancer/LoadBalancer.php(875): Wikimedia\Rdbms\LoadBalancer->reallyOpenConnection(array, Wikimedia\Rdbms\DatabaseDomain)
#3 /volume1/web/mediawiki/includes/libs/rdbms/loadbalancer/LoadBalancer.php(736): Wikimedia\Rdbms\LoadBalancer->openConnection(integer, boolean, integer)
#4 /volume1/web/mediawiki/includes/GlobalFunctions.php(2863): Wikimedia\Rdbms\LoadBalancer->getConnection(integer, array, boolean)
#5 /volume1/web/mediawiki/maintenance/Maintenance.php(1303): wfGetDB(integer, array, boolean)
#6 /volume1/web/mediawiki/maintenance/update.php(144): Maintenance->getDB(integer)
#7 /volume1/web/mediawiki/maintenance/doMaintenance.php(94): UpdateMediaWiki->execute()
#8 /volume1/web/mediawiki/maintenance/update.php(245): require_once(string)
#9 {main}

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptApr 2 2018, 1:39 PM

That's a very strange error. What versions of MediaWiki and Cargo are you running? And do you have MySQL installed on that server, and if so what version?

Product Version
MediaWiki https://www.mediawiki.org/ 1.31.0-alpha
PHP https://php.net/ 7.0.24 (fpm-fcgi)
MariaDB https://mariadb.org/ 10.0.32-MariaDB
ICU http://site.icu-project.org/ 56.1

Cargo = 1.7

I am running my server on a synology NAS. I tried using the default databases which is

$wgDBtype = "mysql";
$wgDBserver = "localhost:/run/mysqld/mysqld10.sock";
$wgDBname = "hurdwiki";
$wgDBuser = “XXX";
$wgDBpassword = “XXX";

I also tried with the following added to “LocalSettings.php"

$wgCargoDBtype = "mysql";
$wgCargoDBserver = "localhost";
$wgCargoDBname = "cargo";
$wgCargoDBuser = “XXX";
$wgCargoDBpassword = “XXX";

Very odd. If you uninstall Cargo, do you no longer see any errors when updating?

Looks like I’m getting the error when I remove Cargo as well.

Perhaps its another extension then.

Alright. Sounds like it might be core MediaWiki also...

Nikhil-nk added a subscriber: Nikhil-nk.EditedApr 2 2018, 3:36 PM

most probably, mysql driver is not enabled.

Aklapper changed the task status from Open to Stalled.Apr 2 2018, 6:02 PM

Which distribution / operating system is this about? Which MySQL/MariaDB driver / package is installed?

See similar support topics like https://www.mediawiki.org/wiki/Topic:Rxtlx4jy5ipjt87r or https://www.mediawiki.org/wiki/Topic:Rj2fdepa4s7nsk5l .
Which makes me think that there is no software bug here.

@Mmiller0712: Could you answer my last question please? Thanks! :)

Aklapper closed this task as Declined.Apr 12 2018, 12:30 PM

Which distribution / operating system is this about? Which MySQL/MariaDB driver / package is installed?

Unfortunately closing this report as no further information has been provided.

@Mmiller0712: After you have provided the information asked for and if this still happens, please set the status of this report back to "Open" via the Add Action...Change Status dropdown. Thanks!