Topic on Project:Support desk

Error message after upgrade from 1.25 -> 1.33

3
Summary by .digamma

Database query error from index.php. Update.php ran silently. Non-existent table during update -> update.php couldn't login to database to create necessary tables.

.digamma (talkcontribs)

I worked through the instructions found here: Manual:Upgrading and performed the recommended backup as described. I ran the update.php command (in fact twice) and it completed very quickly with no output in the ssh PuTTY console. I'm using PHP 7.3, but the Wiki runs on 7.0, and MySQL database version 5.7.23-23

When I visit the main page of the wiki, I get this error:

[X14OUEd0TyMB3I8DpNhbgAAAA8] 2019-09-14 23:31:06: Fatal exception of type Wikimedia\Rdbms\DBQueryError

[XX2T2UvxMo5akr5-@9w1WAAAAA8] /w/ Wikimedia\Rdbms\DBQueryError from line 1587 of /home4/w/includes/libs/rdbms/database/Database.php: A database query error has occurred. Did you forget to run your application's database schema updater after upgrading?

Query: SELECT rev_id,rev_page,rev_timestamp,rev_minor_edit,rev_deleted,rev_len,rev_parent_id,rev_sha1,comment_rev_comment.comment_text AS `rev_comment_text`,comment_rev_comment.comment_data AS `rev_comment_data`,comment_rev_comment.comment_id AS `rev_comment_cid`,actor_rev_user.actor_user AS `rev_user`,actor_rev_user.actor_name AS `rev_user_text`,temp_rev_user.revactor_actor AS `rev_actor`,page_namespace,page_title,page_id,page_latest,page_is_redirect,page_len,user_name FROM `wiki_revision` JOIN `wiki_revision_comment_temp` `temp_rev_comment` ON ((temp_rev_comment.revcomment_rev = rev_id)) JOIN `wiki_comment` `comment_rev_comment` ON ((comment_rev_comment.comment_id = temp_rev_comment.revcomment_comment_id)) JOIN `wiki_revision_actor_temp` `temp_rev_user` ON ((temp_rev_user.revactor_rev = rev_id)) JOIN `wiki_actor` `actor_rev_user` ON ((actor_rev_user.actor_id = temp_rev_user.revactor_actor)) JOIN `wiki_page` ON ((page_id = rev_page)) LEFT JOIN `wiki_user` ON ((actor_rev_user.actor_user != 0) AND (user_id = actor_rev_user.actor_user)) WHERE page_is_redirect = '0' AND page_namespace = '8' AND (page_title NOT LIKE '%/%' ESCAPE '`' ) AND (page_len <= 10000) AND (page_latest = rev_id)

Function: MessageCache::loadFromDB(en)-small

Error: 1146 Table 'wikidb.wiki_revision_comment_temp' doesn't exist (localhost)

Backtrace:

#0 /home4/w/includes/libs/rdbms/database/Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)

#1 /home4/w/includes/libs/rdbms/database/Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)

#2 /home4/w/includes/libs/rdbms/database/Database.php(1784): Wikimedia\Rdbms\Database->query(string, string)

#3 /home4/w/includes/cache/MessageCache.php(549): Wikimedia\Rdbms\Database->select(array, array, array, string, array, array)

#4 /home4/w/includes/cache/MessageCache.php(441): MessageCache->loadFromDB(string, NULL)

#5 /home4/w/includes/cache/MessageCache.php(364): MessageCache->loadFromDBWithLock(string, array, NULL)

#6 /home4/w/includes/cache/MessageCache.php(1051): MessageCache->load(string)

#7 /home4/w/includes/cache/MessageCache.php(978): MessageCache->getMsgFromNamespace(string, string)

#8 /home4/w/includes/cache/MessageCache.php(948): MessageCache->getMessageForLang(LanguageEn, string, boolean, array)

#9 /home4/w/includes/cache/MessageCache.php(890): MessageCache->getMessageFromFallbackChain(LanguageEn, string, boolean)

#10 /home4/w/includes/Message.php(1308): MessageCache->get(string, boolean, LanguageEn)

#11 /home4/w/includes/Message.php(863): Message->fetchMessage()

#12 /home4/w/includes/Message.php(955): Message->toString(string)

#13 /home4/w/includes/Title.php(633): Message->text()

#14 /home4/w/includes/MediaWiki.php(120): Title::newMainPage()

#15 /home4/w/includes/MediaWiki.php(140): MediaWiki->parseTitle()

#16 /home4/w/includes/MediaWiki.php(781): MediaWiki->getTitle()

#17 /home4/w/includes/MediaWiki.php(515): MediaWiki->main()

#18 /home4/w/index.php(42): MediaWiki->run()

#19 {main}

Where can I find the log file for the update.php process?


I appreciate any help.

~~~~

AhmadF.Cheema (talkcontribs)

Did you upgrade your extensions too? Faulty extensions can also cause update.php to not work, temporarily disable all extensions and try update.php again.

.digamma (talkcontribs)

Same error. Update.php exits quickly. The wiki_bot_passwords table isn't there either, added in 1.27.

I solved this error. I added display errors to the top of the update.php script and discovered the script was unable to find the login credentials for the database. After fixing this, the script ran.