Bug 982789 - mediawiki site fails after update to Fedora 19
mediawiki site fails after update to Fedora 19
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: mediawiki (Show other bugs)
19
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Michael Cronenworth
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-09 17:57 EDT by Domingo Becker
Modified: 2013-11-28 15:07 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-11-28 12:01:26 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Wikimedia 49254 None None None Never

  None (edit)
Description Domingo Becker 2013-07-09 17:57:18 EDT
Description of problem:
After updating to Fedora 19, from Fedora 18, I get the following error when trying to access a wiki page in the F19 box:

Unexpected non-MediaWiki exception encountered, of type "PDOException"
exception 'PDOException' with message 'There is no active transaction' in /usr/share/mediawiki/includes/db/DatabaseSqlite.php:664
Stack trace:
#0 /usr/share/mediawiki/includes/db/DatabaseSqlite.php(664): PDO->commit()
#1 /usr/share/mediawiki/includes/db/Database.php(3080): DatabaseSqlite->doCommit('LoadBalancer::c...')
#2 /usr/share/mediawiki/includes/db/LoadBalancer.php(909): DatabaseBase->commit('LoadBalancer::c...', 'flush')
#3 [internal function]: LoadBalancer->commitMasterChanges()
#4 /usr/share/mediawiki/includes/db/LBFactory.php(155): call_user_func_array(Array, Array)
#5 [internal function]: LBFactory->callMethod(Object(LoadBalancer), 'commitMasterCha...', Array)
#6 /usr/share/mediawiki/includes/db/LBFactory.php(272): call_user_func_array(Array, Array)
#7 /usr/share/mediawiki/includes/db/LBFactory.php(145): LBFactory_Simple->forEachLB(Array, Array)
#8 /usr/share/mediawiki/includes/db/LBFactory.php(162): LBFactory->forEachLBCallMethod('commitMasterCha...')
#9 /usr/share/mediawiki/includes/Wiki.php(569): LBFactory->commitMasterChanges()
#10 /usr/share/mediawiki/includes/Wiki.php(458): MediaWiki->main()
#11 /usr/share/mediawiki/index.php(59): MediaWiki->run()
#12 {main}

# rpm -qa mediawiki
mediawiki-1.21.1-1.fc19.noarch

The problem has been reported upstream in bug 49254
https://bugzilla.wikimedia.org/show_bug.cgi?id=49254

I solved the problem as specified in comment #3 in that bug, by commenting out
$this->query( 'PRAGMA case_sensitive_like = 1' );

Here's the patch:

--- /usr/share/mediawiki/includes/db/DatabaseSqlite.php.b	2013-07-09 18:23:36.406803060 -0300
+++ /usr/share/mediawiki/includes/db/DatabaseSqlite.php	2013-07-09 18:25:50.923274655 -0300
@@ -128,7 +128,7 @@
 		if ( $this->mOpened ) {
 			$this->mConn->setAttribute( PDO::ATTR_ERRMODE, PDO::ERRMODE_SILENT );
 			# Enforce LIKE to be case sensitive, just like MySQL
-			$this->query( 'PRAGMA case_sensitive_like = 1' );
+			#$this->query( 'PRAGMA case_sensitive_like = 1' );
 			return true;
 		}
 	}

Of course, users should not forget to run 

  php /usr/share/mediawiki/maintenance/update.php

after the upgrade to Fedora 19, otherwise, some different errors will also appear.
Comment 1 Michael Cronenworth 2013-07-09 19:32:07 EDT
Thanks for the patch. Do you know if upstream is planning on committing this change? I'd like to see an upstream commit before I apply it.
Comment 2 Domingo Becker 2013-07-10 08:44:04 EDT
I don't know. Perhaps they'll propose a different patch.

As I hit this problem, I just wanted to share how to solve it under Fedora.
Comment 3 Michael Cronenworth 2013-07-10 09:10:46 EDT
Could you at least propose your patch to upstream and point me to where that is? I'd rather them pass it off and check it. I don't run any SQLite installs and I would like to keep the mediawiki package as close to upstream as possible.
Comment 4 Michael Cronenworth 2013-11-07 23:45:18 EST
Is this still an issue with mediawiki-1.21.2-2.fc19?

If it is have you proposed the patch to WikiMedia?
Comment 5 Joshua Werner 2013-11-28 11:57:11 EST
I do not believe this is an issue as of mediawiki-1.21.1.fc19. Running php /usr/share/mediawiki/maintenance/update.php was able to update the sql database and access updated wiki without issue.
Comment 6 Domingo Becker 2013-11-28 15:07:14 EST
(In reply to Michael Cronenworth from comment #4)
> Is this still an issue with mediawiki-1.21.2-2.fc19?
> 
> If it is have you proposed the patch to WikiMedia?

Sorry for the late reply.

It's not an issue anymore. I'm using mediawiki-1.21.2-2.fc19.

Thank you.

Note You need to log in before you can comment on or make changes to this bug.