All,
I have an issue with the pagelinks table in a MW 1.44.2 install. When
performing an upgrade to MW 1.46 (or indeed just to 1.44.3!) and running the
update maintenance script, it bombs out:
Table pagelinks contains pl_title field.
Dropping...Wikimedia\Rdbms\DBQueryError from line 1230 of
/opt/mediawiki/includes/libs/Rdbms/Database/Database.php: Error 1062: Duplicate
entry '1-32' for key 'PRIMARY'
Function: Wikimedia\Rdbms\Database::sourceFile(
/opt/mediawiki/sql/mysql/patch-pagelinks-drop-pl_title.sql )
Query: ALTER TABLE `pagelinks`
ADD PRIMARY KEY (pl_from, pl_target_id)
Prior to running the 'update' maintenance script using 'run.php', there is only
one row with pl_from=1 and pl_target_id=32, so the migration scripts are
creating duplicate entries.
Although running the 'update' script a second time causes it to succeed, I
don't want to do this in a production environment and risk problems later down
the line.
According to https://www.mediawiki.org/wiki/Manual:Pagelinks_table,
'Regenerating the pagelinks table is always possible using the rebuildall.php
maintenance script', but if I run this on the database prior to migration, it
doesn't appear to delete anything from the pagelinks table.
I am at a loss. Can anyone help me work out what's going on?
Best wishes,
Peter
_______________________________________________
MediaWiki-l mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://lists.wikimedia.org/postorius/lists/mediawiki-l.lists.wikimedia.org/