Jump to content

Manual talk:CleanupUsersWithNoId.php

About this board

I am a bit fuzzy about how this is supposed to work...

4
Kghbln (talkcontribs)

During the php update.php run (direct upgrade from MW 1.31.x to MW 1.35.x) I get something like this:

Beginning migration of revision.rev_user and revision.rev_user_text to revision_actor_temp.revactor_actor
...
... rev_id=10860
User name "JohnDoe" is usable, cannot create an anonymous actor for it. Run maintenance/cleanupUsersWithNoId.php to fix this situation.

Now I run php cleanupUsersWithNoId.php --prefix=mywiki and I get this:

Skipping revision, fields rev_user and/or rev_user_text do not exist
Skipping archive, fields ar_user and/or ar_user_text do not exist
Skipping logging, fields log_user and/or log_user_text do not exist
Skipping image, fields img_user and/or img_user_text do not exist
Skipping oldimage, fields oi_user and/or oi_user_text do not exist
Skipping filearchive, fields fa_user and/or fa_user_text do not exist
Beginning cleanup of ipblocks
Completed cleanup, assigned 0 and prefixed 0 row(s)
Skipping recentchanges, fields rc_user and/or rc_user_text do not exist

What worries me is this output from the report above:

Skipping revision, fields rev_user and/or rev_user_text do not exist

To me it looks like this script did nothing. Do you think that this is an issue?

Bawolff (talkcontribs)

I dont like how the updates around this were structured. I think you have to basically upgrade to the first version where this script is introduced (in a multistep way), otherwise by the end of the update script, the fields this script operates on are deleted so it cant do anything.

Kghbln (talkcontribs)

This is even more dramatic since everybody? knows that quite a lot of people skip from LTS to LTS directly. This is imho expected and even advertised as a possible upgrade path. Anyhow now this is how it is.

Do you think that I basically have a corrupted database now that I was not able to cleanup users?

> basically upgrade to the first version where this script is introduced

This was 1.30 prior to the 1.31 branch point. Hmm ...

Rebastion2 (talkcontribs)

the more I google around the more it seems like a lot of wikis break/broke because of this and nobody was really aware of the ramifications. What is needed is some comprehensive maintenance script that really fixes any sort of legacy mediawiki/DB setup

Reply to "I am a bit fuzzy about how this is supposed to work..."

How to chose interwiki prefix for local wiki?

3
Kghbln (talkcontribs)

The prefix flag is required. How do I best choose a prefix for a local wiki instance that is not connected to or know by other wikis?

Doing an educated guess here I'd just pick a prefix that should be best used for my local wiki instance, e.g. by other wikis.

GregRundlett (talkcontribs)

I ran into an error upgrading a wiki today (1.31.7 to 1.34) which told me to run this maintenance script. Since the prefix flag is required, there should be more documentation to guide a user on what the value should be or could be. I have no idea where all the invalid users came from; and I'm even more in the dark about what the interwiki prefix is supposed to do. I just chose 'mw' which is for 'mediawiki.org' from my large list of interwiki prefixes.

Prod (talkcontribs)

The original commit for the script seems to have better documentation of what it does.- https://gerrit.wikimedia.org/r/c/mediawiki/core/+/386625


The prefix is essentially the interwiki prefix you want to associate all the users with, assuming that they're due to some kind of transwiki.


I'm not sure what impact using '*' has, the way it's stated on the page.

Reply to "How to chose interwiki prefix for local wiki?"
There are no older topics