Page MenuHomePhabricator

"Lock wait timeout exceeded"
Closed, ResolvedPublic

Description

In the past two days, I have encountered the error:

A database query error has occurred. This may indicate a bug in the software.
Function: User::incEditCountImmediate
Error: 1205 Lock wait timeout exceeded; try restarting transaction (208.80.154.136)

several times. In some cases, a similar error:

A database error has occurred. Did you forget to run maintenance/update.php after upgrading? See: https://www.mediawiki.org/wiki/Manual:Upgrading#Run_the_update_script Query: UPDATE user SET user_editcount=user_editcount+1 WHERE user_id = '289' Function: User::incEditCountImmediate Error: 1205 Lock wait timeout exceeded; try restarting transaction (208.80.154.136)

was displayed.

Event Timeline

scfc created this task.May 27 2015, 11:18 PM
scfc raised the priority of this task from to Needs Triage.
scfc updated the task description. (Show Details)
scfc added a project: wikitech.wikimedia.org.
scfc added a subscriber: scfc.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMay 27 2015, 11:18 PM
scfc updated the task description. (Show Details)May 27 2015, 11:18 PM
scfc set Security to None.
Reedy added a subscriber: Reedy.May 27 2015, 11:20 PM

Doing anything specifically?

scfc updated the task description. (Show Details)May 27 2015, 11:21 PM
scfc removed a subscriber: Reedy.
scfc added a comment.May 27 2015, 11:24 PM

IIRC mostly editing shell request forms and user talk pages (cf. https://wikitech.wikimedia.org/wiki/Special:Contributions/Tim_Landscheidt).

(It may have also occured when editing user groups (Special:UserRights), but I can't remember for sure. Do those changes count as edits?)

Aklapper triaged this task as High priority.May 28 2015, 1:23 PM
hashar added a subscriber: hashar.

Hits production as well, probably related to load. A first chunk started on May 27 at 11:00 till 20:00 UTC. A second one going on started at 11:00 with roughly 250 messages per hour.

https://logstash.wikimedia.org/#dashboard/temp/iYs7oEMqT-6PWthN73EhlA

The spam for today is on commonswiki

scfc added a comment.May 29 2015, 10:07 PM

Just now at https://wikitech.wikimedia.org/wiki/Shell_Request/Vieira?action=formedit:

A database error has occurred. Did you forget to run maintenance/update.php after upgrading? See: https://www.mediawiki.org/wiki/Manual:Upgrading#Run_the_update_script Query: UPDATE user SET user_editcount=user_editcount+1 WHERE user_id = '289' Function: User::incEditCountImmediate Error: 1205 Lock wait timeout exceeded; try restarting transaction (208.80.154.136)

And adding a user to the Tools project at https://wikitech.wikimedia.org/wiki/Special:NovaProject:

Database error
A database query error has occurred. This may indicate a bug in the software.

  • Function: User::incEditCountImmediate
  • Error: 1205 Lock wait timeout exceeded; try restarting transaction (208.80.154.136)
Legoktm added subscribers: aaron, Springle.
TTO added a subscriber: TTO.Jun 1 2015, 12:34 AM
aude added a subscriber: aude.Jun 2 2015, 3:03 PM

I seem to be getting issue on my local wiki install. (my wikibase "client" instance, so like wikipedia and even when I disable Wikibase)

I am using hhvm. It happens just when loading a page (e.g. try Special:Random 2-3 times to view a pge or when editing a page)

aude added a comment.Jun 2 2015, 3:41 PM
enwiki: [7aef69ab] /w/index.php?title=Mexico&action=submit   DBQueryError from line 1276 of /var/www/wiki/w/includes/db/Database.php: A database error has occurred. Did you forget to run maintenance/update.php after upgrading?  See: https://www.mediawiki.org/wiki/Manual:Upgrading#Run_the_update_script
Query: UPDATE  `user` SET user_editcount=user_editcount+1 WHERE user_id = '2'                       
Function: User::incEditCountImmediate                                                               
Error: 1205 Lock wait timeout exceeded; try restarting transaction (localhost)                      
                                                                                                    
#0 /var/www/wiki/w/includes/db/Database.php(1231): DatabaseBase->reportQueryError()                 
#1 /var/www/wiki/w/includes/db/Database.php(2183): DatabaseBase->query()                            
#2 /var/www/wiki/w/includes/User.php(4829): DatabaseBase->update()                                  
#3 /var/www/wiki/w/includes/User.php(4808): User->incEditCountImmediate()                           
#4 /var/www/wiki/w/includes/db/Database.php(3515): Closure$User::incEditCount()                     
#5 /var/www/wiki/w/includes/db/Database.php(3724): DatabaseBase->runOnTransactionPreCommitCallbacks()
#6 /var/www/wiki/w/includes/page/WikiPage.php(1849): DatabaseBase->commit()                         
#7 /var/www/wiki/w/includes/page/Article.php(2015): WikiPage->doEditContent()                       
#8 /var/www/wiki/w/includes/EditPage.php(1933): Article->__call()                                   
#9 /var/www/wiki/w/includes/EditPage.php(1317): EditPage->internalAttemptSave()                     
#10 /var/www/wiki/w/includes/EditPage.php(551): EditPage->attemptSave()                             
#11 /var/www/wiki/w/includes/actions/EditAction.php(56): EditPage->edit()                           
#12 /var/www/wiki/w/includes/actions/SubmitAction.php(40): EditAction->show()                       
#13 /var/www/wiki/w/includes/MediaWiki.php(413): SubmitAction->show()                               
#14 /var/www/wiki/w/includes/MediaWiki.php(291): MediaWiki->performAction()                         
#15 /var/www/wiki/w/includes/MediaWiki.php(603): MediaWiki->performRequest()                        
#16 /var/www/wiki/w/includes/MediaWiki.php(431): MediaWiki->main()                                  
#17 /var/www/wiki/w/index.php(41): MediaWiki->run()                                                 
#18 {main}

Change 215379 had a related patch set uploaded (by Aaron Schulz):
Fixed $flags bit operation precedence fail in User::loadFromDatabase()

https://gerrit.wikimedia.org/r/215379

Change 215379 merged by jenkins-bot:
Fixed $flags bit operation precedence fail in User::loadFromDatabase()

https://gerrit.wikimedia.org/r/215379

Change 215388 had a related patch set uploaded (by Aaron Schulz):
Fixed $flags bit operation precedence fail in User::loadFromDatabase()

https://gerrit.wikimedia.org/r/215388

Change 215388 merged by jenkins-bot:
Fixed $flags bit operation precedence fail in User::loadFromDatabase()

https://gerrit.wikimedia.org/r/215388

TTO added a comment.Jun 6 2015, 1:15 PM

Fixed? Haven't had any more reports at WT:TW.

Jdforrester-WMF closed this task as Resolved.Jun 10 2015, 2:10 AM
Jdforrester-WMF assigned this task to aaron.
mmodell changed the subtype of this task from "Task" to "Production Error".Aug 28 2019, 11:11 PM