Bug 926899 - mw-updateallinstances is broken
Summary: mw-updateallinstances is broken
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: mediawiki
Version: 17
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
Assignee: Michael Cronenworth
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 949621 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-03-24 00:09 UTC by Scott Schmit
Modified: 2013-04-21 03:25 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-04-20 20:10:33 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Patch to mediawiki git repo (854 bytes, patch)
2013-04-12 01:39 UTC, Scott Schmit
no flags Details | Diff
Fixes to mw-createinstance and mw-updateallinstances (1.18 KB, patch)
2013-04-12 01:45 UTC, Scott Schmit
no flags Details | Diff

Description Scott Schmit 2013-03-24 00:09:19 UTC
Description of problem:
I updated my machine last night and my wiki page is blank.
Running mw-updateallinstances reports the following:
# mw-updateallinstances 
cp: cannot stat `/usr/share/mediawiki/config': No such file or directory
A copy of your installation's LocalSettings.php
must exist and be readable in the source directory.
Use --conf to specify it.

Indeed, if I ls /usr/share/mediawiki, the config directory does not exist. There is, however, a /usr/share/mediawiki/mw-config. Modifying mw-createinstance to point at that instead eliminates the cp error.

However, I still get the error from the php command.

If I manually run this from my mediawiki instance, I get this:
MediaWiki 1.19.4 Updater

Going to run database updates for wikidb-wiki_
Depending on the size of your database this may take a while!
...have ipb_id field in ipblocks table.
...have ipb_expiry field in ipblocks table.
...already have interwiki table
...indexes seem up to 20031107 standards.
...hitcounter table already exists.
...have rc_type field in recentchanges table.
...have user_real_name field in user table.
...querycache table already exists.
...objectcache table already exists.
...categorylinks table already exists.
...have pagelinks; skipping old links table updates
...il_from OK
...have rc_ip field in recentchanges table.
...index PRIMARY already set on image table.
...have rc_id field in recentchanges table.
...have rc_patrolled field in recentchanges table.
...logging table already exists.
...have user_token field in user table.
...have wl_notificationtimestamp field in watchlist table.
...watchlist talk page rows already present.
...user table does not contain user_emailauthenticationtimestamp field.
...page table already exists.
...have log_params field in logging table.
...logging table has correct log_title encoding.
...have ar_rev_id field in archive table.
...have page_len field in page table.
...revision table does not contain inverse_timestamp field.
...have rev_text_id field in revision table.
...have rev_deleted field in revision table.
...have img_width field in image table.
...have img_metadata field in image table.
...have user_email_token field in user table.
...have ar_text_id field in archive table.
A database query syntax error has occurred.
The last attempted database query was:
"SHOW COLUMNS FROM `wiki_page` LIKE 'page_namespace'"
from within function "MysqlUpdater::doNamespaceSize".
Database returned error "1: Can't create/write to file '/tmp/#sql_4b83_0.MYI' (Errcode: 2) (localhost)"

If I try to manually do a mysqldump I get the same error as at the end.

Version-Release number of selected component (if applicable):
mediawiki-1.19.4-2.fc17.noarch

How reproducible:
100%

Steps to Reproduce:
See above
 
Actual results:
Wiki doesn't work.

Expected results:
Working wiki.

Additional info:

Comment 1 Scott Schmit 2013-03-24 00:19:45 UTC
Also, I noticed this:
$ rpm -q --scripts mediawiki
postinstall scriptlet (using /bin/sh):
/usr/sbin/mw-updateallinstances >> /var/log/mediawiki-updates.log 2>&1 || :

/var/log/mediawiki-updates.log exists, but is empty. It last changed on November 26, 2011, so something tells me this isn't actually getting run on upgrades.

Comment 2 Scott Schmit 2013-04-12 01:20:34 UTC
It's been three weeks since I filed this bug, and I've seen no response. It's obviously not a common bug, since there's only one other bug filed about this (Bug 949621), but I really would like to see this fixed, as my wiki has been nothing but a blank page for three weeks now.

Any thoughts?

Comment 3 Scott Schmit 2013-04-12 01:37:32 UTC
Ok, so manually running "php /usr/share/mediawiki/maintenance/update.php --quick --conf LocalSettings.php" from my wiki directory now works. Maybe the selinux policy got fixed in the meantime.

Comment 4 Scott Schmit 2013-04-12 01:39:12 UTC
Created attachment 734506 [details]
Patch to mediawiki git repo

This patch should fix mw-createinstance & mw-updateallinstances so that they work.

Comment 5 Scott Schmit 2013-04-12 01:45:45 UTC
Created attachment 734507 [details]
Fixes to mw-createinstance and mw-updateallinstances

Correction to earlier patch: we also need a symlink to includes now.

Comment 6 Michael Cronenworth 2013-04-12 02:22:14 UTC
*** Bug 949621 has been marked as a duplicate of this bug. ***

Comment 7 Michael Cronenworth 2013-04-12 02:48:34 UTC
I hadn't encountered problems upgrading my installs and I didn't find time to look at this yet. Thanks for the patch. An update will be pushed out soon.

Comment 8 Fedora Update System 2013-04-12 03:06:10 UTC
mediawiki-1.20.3-3.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/mediawiki-1.20.3-3.fc19

Comment 9 Fedora Update System 2013-04-12 03:14:42 UTC
mediawiki-1.19.4-3.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/mediawiki-1.19.4-3.fc18

Comment 10 Fedora Update System 2013-04-12 03:22:14 UTC
mediawiki-1.19.4-3.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/mediawiki-1.19.4-3.fc17

Comment 11 Fedora Update System 2013-04-12 15:15:48 UTC
Package mediawiki-1.20.3-3.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing mediawiki-1.20.3-3.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-5494/mediawiki-1.20.3-3.fc19
then log in and leave karma (feedback).

Comment 12 Fedora Update System 2013-04-20 20:10:35 UTC
mediawiki-1.20.3-3.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 13 Fedora Update System 2013-04-21 03:24:46 UTC
mediawiki-1.19.4-3.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 14 Fedora Update System 2013-04-21 03:25:15 UTC
mediawiki-1.19.4-3.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.


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