Page MenuHomePhabricator

Error: 2013 Lost connection to MySQL server during query on IndexPager::buildQueryInfo (LogPager)
Closed, ResolvedPublicPRODUCTION ERROR

Description

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

  • Function: IndexPager::buildQueryInfo (LogPager)
  • Error: 2013 Lost connection to MySQL server during query (10.64.16.8)

Event Timeline

Josve05a raised the priority of this task from to Needs Triage.
Josve05a updated the task description. (Show Details)
Josve05a subscribed.
Josve05a renamed this task from IndexPager::buildQueryInfo (LogPager) to Error: 2013 Lost connection to MySQL server during query on IndexPager::buildQueryInfo (LogPager).Dec 12 2015, 10:40 AM
Josve05a set Security to None.

I cannot reproduce it, but it is worth having a look.

There is a handful of errors: https://logstash.wikimedia.org/#dashboard/temp/AVGV0hrlptxhN1Xa1ntO but I would say not high priority because it is not reproducible and its impact is lower than other errors.

Probably related, if not a duplicate of T60157 or T108782.

Glaisher subscribed.

I can reproduce it now.

Probably related, if not a duplicate of T60157 or T108782.

Special:Contributions generates different queries so it's not related.

This is the query which the above params in the URL generates.

SELECT log_id,
       log_type,
       log_action,
       log_timestamp,
       log_user,
       log_user_text,
       log_namespace,
       log_title,
       log_comment,
       log_params,
       log_deleted,
       user_id,
       user_name,
       user_editcount,
       (SELECT Group_CONCAT(ct_tag SEPARATOR ',')
        FROM   `change_tag`
        WHERE  ct_log_id = log_id) AS ts_tags
FROM   `logging`
       LEFT JOIN `user`
              ON (( log_user = user_id ))
       INNER JOIN `change_tag`
               ON (( ct_log_id = log_id ))
WHERE  ( log_type != 'suppress' )
       AND log_type = 'upload'
       AND ct_tag = 'mobile edit'
       AND ( log_timestamp < '201408200000' )
ORDER  BY log_timestamp DESC
LIMIT  51

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

Function: RevDelRevisionList::doQuery
Error: 2013 Lost connection to MySQL server during query (10.64.16.29)

while trying to perform an oversight action (suppression) on Commons.

This comment was removed by tomasz.

Could this be related to the suppression flag condition? Was there something changed lately related to that?

I see the error on Commons on the logs:

{
  "_index": "logstash-2015.12.13",
  "_type": "mediawiki",
  "_id": "AVGbiky2lAIL90ZzNsy2",
  "_score": null,
  "_source": {
    "message": "RevDelRevisionList::doQuery\t10.64.16.29\t2013\tLost connection to MySQL server during query (10.64.16.29)\tSELECT  rev_id,rev_page,rev_text_id,rev_timestamp,rev_comment,rev_user_text,rev_user,rev_minor_edit,rev_deleted,rev_len,rev_parent_id,rev_sha1,rev_content_format,rev_content_model,user_name  FROM `revision` INNER JOIN `page` ON ((page_id = rev_page)) LEFT JOIN `user` ON ((rev_user != 0) AND (user_id = rev_user))  WHERE rev_page = '<SANITIZED>' AND rev_id IN (<SANITIZED>,,,)   ORDER BY rev_id DESC ",
    "@version": 1,
    "@timestamp": "2015-12-13T13:31:50.000Z",
    "type": "mediawiki",
    "host": "mw1252",
    "level": "ERROR",
    "tags": [
      "syslog",
      "es",
      "es",
      "normalized_message_trimmed"
    ],
    "channel": "wfLogDBError",
    "url": "/w/index.php?title=Special:RevisionDelete&amp;action=submit",
    "ip": "10.64.0.105",
    "http_method": "POST",
    "server": "commons.wikimedia.org",
    "referrer": "https://commons.wikimedia.org/w/index.php?title=Commons%3A<SANITIZED>&amp;action=revisiondelete&amp;type=revision&<SANITIZED>",
    "uid": "b19382d",
    "process_id": 10318,
    "wiki": "commonswiki",
    "db_server": "10.64.16.29",
    "db_name": "commonswiki",
    "db_user": "wikiuser",
    "method": "DatabaseBase::reportQueryError",
    "errno": 2013,
    "error": "Lost connection to MySQL server during query (10.64.16.29)",
    "sql1line": "SELECT  rev_id,rev_page,rev_text_id,rev_timestamp,rev_comment,rev_user_text,rev_user,rev_minor_edit,rev_deleted,rev_len,rev_parent_id,rev_sha1,rev_content_format,rev_content_model,user_name  FROM `revision` INNER JOIN `page` ON ((page_id = rev_page)) LEFT JOIN `user` ON ((rev_user != 0) AND (user_id = rev_user))  WHERE rev_page = '<SANITIZED>' AND rev_id IN (<SANITIZED>,,,)   ORDER BY rev_id DESC ",
    "fname": "RevDelRevisionList::doQuery",
    "normalized_message": "RevDelRevisionList::doQuery\t10.64.16.29\t2013\tLost connection to MySQL server during query (10.64.16.29)\tSELECT  rev_id,rev_page,rev_text_id,rev_timestamp,rev_comment,rev_user_text,rev_user,rev_minor_edit,rev_deleted,rev_len,rev_parent_id,rev_sha1,rev_cont"
  },
  "sort": [
    1450013510000
  ]
}

@tomasz Could you try several times, so we can know if it happens every time or just randomly (maybe depending on the database)?

I think it is not related to the previous error, as it is a different query, so maybe it should be investigated/filed separately, so it is triaged adequately (this ticket has low priority and your issue could get lost otherwise).

I managed to perform that suppression at the second try, so it does look like a random problem.

Please do feel free to split this issue to a separate report if it helps with troubleshooting it.

@tomasz, thank you. Also do not doubt to reply/report again if it happens again.

Same error?
https://commons.wikimedia.org/wiki/Special:NewFiles?hidepatrolled=1&limit=50&offset=

A database query error has occurred. This may indicate a bug in the software.
Function: IndexPager::buildQueryInfo (NewFilesPager)
Error: 2013 Lost connection to MySQL server during query (10.64.32.26)

@Josve05a
It is a different query: IndexPager::buildQueryInfo (NewFilesPager). I could only reproduce it once, and it only happened 8 times in the last week. It should be reported separately, though, as it is a query on recentchanges / image / usergroups, not on log.

Oh, true. I just saw that it has the same function-code as this.

Marostegui added subscribers: tomasz, Marostegui.

I managed to perform that suppression at the second try, so it does look like a random problem.

Please do feel free to split this issue to a separate report if it helps with troubleshooting it.

going to close this as per this comment, and given that the last comment is almost 2 years old.
Feel free to re-open if needed

mmodell changed the subtype of this task from "Task" to "Production Error".Aug 28 2019, 11:11 PM