You are browsing a read-only backup copy of Wikitech. The primary site can be found at wikitech.wikimedia.org

Stuck global renames: Difference between revisions

From Wikitech-static
Jump to navigation Jump to search
imported>Legoktm
 
imported>Gergő Tisza
(Seems accurate to me.)
Line 1: Line 1:
== Recovering a "locked" account ==
== Recovering a "locked" account ==
: ''This section needs review for accuracy.''
Sometimes you'll find that a rename becomes stuck at a project (see for example [[phab:T137973]]). In that case, please follow this instructions:
Sometimes you'll find that a rename becomes stuck at a project (see for example [[phab:T137973]]). In that case, please follow this instructions:


* Wait at least 3 hours since the rename started. The system will automatically retry failed renames a few times.
* Wait at least 3 hours since the rename started. The system will automatically retry failed renames a few times.
* Please [https://phabricator.wikimedia.org/maniphest/task/edit/form/1/?title=Please%20unblock%20stuck%20global%20rename&projects=Wikimedia-Site-requests,GlobalRename open a task in Phabricator] (direct link with title and projects already added). In there please post a link to the Special:GlobalRenameProgress link to the account whose rename has become stuck.
* Please [https://phabricator.wikimedia.org/maniphest/task/edit/form/1/?title=Please%20unblock%20stuck%20global%20rename&projects=Wikimedia-Site-requests,GlobalRename open a task in Phabricator] (direct link with title and projects already added). In there please post a link to the Special:GlobalRenameProgress link to the account whose rename has become stuck.
* Developers should see if there are exceptions or errors in flourine/Logstash before continuing. Searching/grepping for "Rename" should catch most things.
* Developers should see if there are exceptions or errors in [[Logstash]] before continuing. Searching/grepping for "Rename" or looking at the log channels <code>CentralAuthRename</code> and <code>Renameuser</code> should catch most things.
* Any user with access to <code>[[terbium]]</code> can run the <tt>[[phab:/diffusion/ECAU/browse/master/maintenance/fixStuckGlobalRename.php|fixStuckGlobalRename.php]]</tt> maintenance script to requeue the job. Before running the script, verify if the jobs are running. This is important. That can be done using <code>showJobs.php</code>. If jobs aren't running, you can proceed with: <source lang="bash">you@terbium:~$ mwscript extensions/CentralAuth/maintenance/fixStuckGlobalRename.php --wiki= --logwiki=metawiki "OldName" "NewName"</source>
* Any user with access to <code>[[terbium]]</code> can run the <tt>[[phab:/diffusion/ECAU/browse/master/maintenance/fixStuckGlobalRename.php|fixStuckGlobalRename.php]]</tt> maintenance script to requeue the job. Before running the script, verify if the jobs are running. This is important. That can be done using <code>showJobs.php</code>. If jobs aren't running, you can proceed with: <source lang="bash">you@terbium:~$ mwscript extensions/CentralAuth/maintenance/fixStuckGlobalRename.php --wiki= --logwiki=metawiki "OldName" "NewName"</source>
:* <code>wiki</code>: the database name of the wiki where the rename job has become stuck, i.e. ptwiki. If it is stuck on multiple wikis, use the one that comes first alphabetically.
:* <code>wiki</code>: the database name of the wiki where the rename job has become stuck, e.g. <code>ptwiki</code>. If it is stuck on multiple wikis, use the one that comes first alphabetically.
:* <code>logwiki</code>: the database name of the wiki where the global rename was started and will always be metawiki.
:* <code>logwiki</code>: the database name of the wiki where the global rename was started. This will always be <code>metawiki</code>.
:* <code>"OldName"</code>: the old username. Should be in quotations.
:* <code>"OldName"</code>: the old username. Should be in quotations.
:* <code>"NewName"</code>: the new username. Should be in quotations.
:* <code>"NewName"</code>: the new username. Should be in quotations.
:* <code>--ignorestatus</code> is a parameter that can be added to fix a global rename when we want the script to ignore any running jobs; use with caution.
:* <code>--ignorestatus</code> is a parameter that can be added to fix a global rename that's stuck in <code>running</code> state even though the job is not actually running. (This used to happen a lot due to fragile error handling; shouldn't happen anymore.)
* Log in the Production SAL that you've run the script through #wikimedia-operations. Example:
* Log in the [[Server Admin Log|production SAL]] that you've run the script, by issuing an IRC command in <code>#wikimedia-operations</code> such as:
*: <code>!log Ran mwscript extensions/CentralAuth/maintenance/fixStuckGlobalRename.php --wiki=ptwiki --logwiki=metawiki "OldName" "NewName"</code>
*: <code>!log Ran mwscript extensions/CentralAuth/maintenance/fixStuckGlobalRename.php --wiki=ptwiki --logwiki=metawiki "OldName" "NewName"</code>
* Watch for errors at Logstash
* Watch for errors at Logstash

Revision as of 21:32, 22 August 2017

Recovering a "locked" account

Sometimes you'll find that a rename becomes stuck at a project (see for example phab:T137973). In that case, please follow this instructions:

  • Wait at least 3 hours since the rename started. The system will automatically retry failed renames a few times.
  • Please open a task in Phabricator (direct link with title and projects already added). In there please post a link to the Special:GlobalRenameProgress link to the account whose rename has become stuck.
  • Developers should see if there are exceptions or errors in Logstash before continuing. Searching/grepping for "Rename" or looking at the log channels CentralAuthRename and Renameuser should catch most things.
  • Any user with access to terbium can run the fixStuckGlobalRename.php maintenance script to requeue the job. Before running the script, verify if the jobs are running. This is important. That can be done using showJobs.php. If jobs aren't running, you can proceed with:
    you@terbium:~$ mwscript extensions/CentralAuth/maintenance/fixStuckGlobalRename.php --wiki= --logwiki=metawiki "OldName" "NewName"
    
  • wiki: the database name of the wiki where the rename job has become stuck, e.g. ptwiki. If it is stuck on multiple wikis, use the one that comes first alphabetically.
  • logwiki: the database name of the wiki where the global rename was started. This will always be metawiki.
  • "OldName": the old username. Should be in quotations.
  • "NewName": the new username. Should be in quotations.
  • --ignorestatus is a parameter that can be added to fix a global rename that's stuck in running state even though the job is not actually running. (This used to happen a lot due to fragile error handling; shouldn't happen anymore.)
  • Log in the production SAL that you've run the script, by issuing an IRC command in #wikimedia-operations such as:
    !log Ran mwscript extensions/CentralAuth/maintenance/fixStuckGlobalRename.php --wiki=ptwiki --logwiki=metawiki "OldName" "NewName"
  • Watch for errors at Logstash
  • In case of doubt, ask Hoo man or Legoktm.