Page MenuHomePhabricator

Convert unique keys into primary keys for some wiki tables on s1
Closed, ResolvedPublic

Description

Pending hosts:

codfw - entire DC
eqiad: all hosts except db1052 (master) and db1089

To be run for db2016:

./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=categorylinks "add primary key (cl_from,cl_to)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=categorylinks "drop key cl_from" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=templatelinks "add primary key (tl_from,tl_namespace,tl_title)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=pagelinks "add primary key (pl_from,pl_namespace,pl_title)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=text "drop key old_id, add primary key (old_id)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=imagelinks "drop key il_from, add primary key (il_from,il_to)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=iwlinks "drop key iwl_from, add primary key (iwl_from,iwl_prefix,iwl_title)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=langlinks "drop key ll_from, add primary key (ll_from,ll_lang)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=log_search "drop key ls_field_val, add primary key (ls_field,ls_value,ls_log_id)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=math "drop key math_inputhash, add primary key (math_inputhash)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=module_deps "drop key md_module_skin, add primary key (md_module,md_skin)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=objectcache "drop key keyname, add primary key (keyname)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=querycache_info "drop key  qci_type, add primary key (qci_type)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=site_stats "drop key ss_row_id, add primary key (ss_row_id)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=transcache "drop key tc_url_idx, add primary key (tc_url)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=user_former_groups "drop key ufg_user_group, add primary key (ufg_user,ufg_group)" --method=ddl --replicate
./software/dbtools/osc_host.sh --host=db2016.codfw.wmnet --dblist=/home/marostegui/git/mediawiki-config/dblists/s1.dblist --table=user_properties "drop key user_properties_user_property, add primary key (up_user,up_property)" --method=ddl --replicate

To be run for each individual host

./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=categorylinks "add primary key (cl_from,cl_to)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=categorylinks "drop key cl_from" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=templatelinks "add primary key (tl_from,tl_namespace,tl_title)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=pagelinks "add primary key (pl_from,pl_namespace,pl_title)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=text "drop key old_id, add primary key (old_id)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=imagelinks "drop key il_from, add primary key (il_from,il_to)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=iwlinks "drop key iwl_from, add primary key (iwl_from,iwl_prefix,iwl_title)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=langlinks "drop key ll_from, add primary key (ll_from,ll_lang)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=log_search "drop key ls_field_val, add primary key (ls_field,ls_value,ls_log_id)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=math "drop key math_inputhash, add primary key (math_inputhash)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=module_deps "drop key md_module_skin, add primary key (md_module,md_skin)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=objectcache "drop key keyname, add primary key (keyname)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=querycache_info "drop key  qci_type, add primary key (qci_type)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=site_stats "drop key ss_row_id, add primary key (ss_row_id)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=transcache "drop key tc_url_idx, add primary key (tc_url)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=user_former_groups "drop key ufg_user_group, add primary key (ufg_user,ufg_group)" --method=ddl --no-replicate
./software/dbtools/osc_host.sh --host=$host.eqiad.wmnet --dblist=$shard.dblist --table=user_properties "drop key user_properties_user_property, add primary key (up_user,up_property)" --method=ddl --no-replicate
  • labsdb1003.eqiad.wmnet
  • labsdb1001.eqiad.wmnet
  • db1069.eqiad.wmnet (Will not be done as it is going to be decommissioned soon)
  • labsdb1009.eqiad.wmnet
  • labsdb1010.eqiad.wmnet
  • labsdb1011.eqiad.wmnet
  • db1095.eqiad.wmnet
  • dbstore1001.eqiad.wmnet
  • dbstore1002.eqiad.wmnet
  • db1080.eqiad.wmnet
  • db1083.eqiad.wmnet
  • db1089.eqiad.wmnet
  • db1073.eqiad.wmnet
  • db1072.eqiad.wmnet
  • db1066.eqiad.wmnet
  • db1065.eqiad.wmnet
  • db1055.eqiad.wmnet
  • db1051.eqiad.wmnet
  • db1047.eqiad.wmnet
  • db1067.eqiad.wmnet
  • db1052.eqiad.wmnet

Related Objects

View Standalone Graph
This task is connected to more than 200 other tasks. Only direct parents and subtasks are shown here. Use View Standalone Graph to show more of the graph.

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes

db1083 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1083 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Mentioned in SAL (#wikimedia-operations) [2017-07-07T07:42:51Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1083 - T166204 (duration: 00m 42s)

Change 364145 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Depool db1067 and db1080

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

Change 364145 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Depool db1067 and db1080

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

Mentioned in SAL (#wikimedia-operations) [2017-07-10T06:00:34Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Depool db1080, depool db1067 - T166204 (duration: 00m 42s)

Mentioned in SAL (#wikimedia-operations) [2017-07-10T06:11:49Z] <marostegui> Deploy alter table on s1 - db1080 and db1067 - T166204

Change 364240 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Repool db1080

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

Change 364240 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Repool db1080

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

db1080 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1080 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Mentioned in SAL (#wikimedia-operations) [2017-07-10T17:00:46Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1080 - T166204 (duration: 00m 42s)

Change 364365 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Depool db1066

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

Mentioned in SAL (#wikimedia-operations) [2017-07-11T05:08:35Z] <marostegui> Deploy alter table on enwiki - labsdb1011 - T166204

Change 364365 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Depool db1066

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

Mentioned in SAL (#wikimedia-operations) [2017-07-11T05:11:12Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Depool db1066 - T166204 (duration: 00m 43s)

Mentioned in SAL (#wikimedia-operations) [2017-07-11T05:14:11Z] <marostegui> Deploy alter table on db1066 - T166204

Mentioned in SAL (#wikimedia-operations) [2017-07-11T06:58:38Z] <marostegui> Deploy alter table on s1 - dbstore1002 - T166204

db1067 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1067 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Change 364409 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Repool db1067

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

Change 364409 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Repool db1067

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

Mentioned in SAL (#wikimedia-operations) [2017-07-11T10:56:14Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1067 with 0 weight - T166204 (duration: 00m 41s)

labsdb1011 is done for the table that exist there:

categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
ERROR 1146 (42S02) at line 1: Table 'enwiki.text' doesn't exist
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
ERROR 1146 (42S02) at line 1: Table 'enwiki.log_search' doesn't exist
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.objectcache' doesn't exist
querycache_info
ERROR 1146 (42S02) at line 1: Table 'enwiki.querycache_info' doesn't exist
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.transcache' doesn't exist
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

dbstore1002 crashed yesterday (T170308 ) while altering templatelinks table (119G). I have altered all the small pending tables and I am now doing text table (61G).
That will be the last one to alter, so pending will be templatelinks (119G) and pagelinks (202G). I don't think it is worth the risk of getting this server crashed again and corrupted, so I will leave those with the UNIQUE keys instead of the PKs.
Will report once text table is finished.

db1066 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1066 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

So dbstore1002 is "done", as I mentioned in: T166204#3429346 templatelinks and pagelinks tables will be skipped and will remain with their UNIQUE keys:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdbstore1002 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
pagelinks
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Mentioned in SAL (#wikimedia-operations) [2017-07-12T12:53:58Z] <marostegui> Deploy alter table s1 - db1095 - T166204

Mentioned in SAL (#wikimedia-operations) [2017-07-12T13:01:39Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1066 - T166204 (duration: 00m 46s)

Change 364716 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Depool db1072

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

Change 364716 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Depool db1072

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

Mentioned in SAL (#wikimedia-operations) [2017-07-12T13:21:26Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Depool db1072 - T166204 (duration: 00m 46s)

Mentioned in SAL (#wikimedia-operations) [2017-07-12T13:23:19Z] <marostegui> Deploy alter table s1 - db1072 - T166204

Mentioned in SAL (#wikimedia-operations) [2017-07-13T06:51:06Z] <marostegui> Manually deploy some alter tables on dbstore1001 for enwiki - T166204

db1095 (sanitarium2) is done for the table that exist:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1095 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
ERROR 1146 (42S02) at line 1: Table 'enwiki.text' doesn't exist
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
ERROR 1146 (42S02) at line 1: Table 'enwiki.log_search' doesn't exist
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.objectcache' doesn't exist
querycache_info
ERROR 1146 (42S02) at line 1: Table 'enwiki.querycache_info' doesn't exist
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.transcache' doesn't exist
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

I think for db1047, I will alter the same tables than in dbstore1002 to:

  1. have both analytic hosts consistent
  2. I doubt we can alter the big tables on db1047 (given what happened with the revision table there when we tried to alter it)

dbstore1001 is done (in the same way as dbstore1002), all tables but the two big ones that crashed dbstore1002:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdbstore1001 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
pagelinks
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Mentioned in SAL (#wikimedia-operations) [2017-07-13T15:33:49Z] <marostegui> Deploy alter table on s1 - labsdb1009 - T166204

Mentioned in SAL (#wikimedia-operations) [2017-07-14T05:54:14Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1072 - T166204 (duration: 00m 46s)

labsdb1009 finished correctly for the existing labs tables

categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
ERROR 1146 (42S02) at line 1: Table 'enwiki.text' doesn't exist
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
ERROR 1146 (42S02) at line 1: Table 'enwiki.log_search' doesn't exist
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.objectcache' doesn't exist
querycache_info
ERROR 1146 (42S02) at line 1: Table 'enwiki.querycache_info' doesn't exist
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.transcache' doesn't exist
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

db1072 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdbstore1001 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
pagelinks
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Change 365551 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Depool db1073

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

Change 365551 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Depool db1073

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

Mentioned in SAL (#wikimedia-operations) [2017-07-17T06:47:09Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Depool db1073 - T166204 (duration: 01m 04s)

Mentioned in SAL (#wikimedia-operations) [2017-07-17T06:48:56Z] <marostegui> Deploy alter table on s1 - db1073 - T166204

Mentioned in SAL (#wikimedia-operations) [2017-07-17T08:20:30Z] <marostegui> Increase expire_logs_days on db1069:3311 from 7 to 14 temporarily - T166204

cloud-services-team I am going to alter the tables on labsdb1001, I think this will take 3-4 days to complete most likely, so labsdb1001 will be delayed for that amount of time on the s1 shard.

Mentioned in SAL (#wikimedia-operations) [2017-07-17T08:23:19Z] <marostegui> Deploy alter table s1 - labsdb1001 - T166204

Mentioned in SAL (#wikimedia-operations) [2017-07-17T14:56:24Z] <marostegui> Deploy, manually, alter tables on enwiki on db1047 - T166204

db1073 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1073 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Mentioned in SAL (#wikimedia-operations) [2017-07-18T05:41:44Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1073 - T166204 (duration: 00m 44s)

Change 365898 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Depool db1065

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

Change 365898 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Depool db1065

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

Mentioned in SAL (#wikimedia-operations) [2017-07-18T05:59:01Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Depool db1065 - T166204 (duration: 00m 43s)

Mentioned in SAL (#wikimedia-operations) [2017-07-18T05:59:14Z] <marostegui> Deploy alter table on s1 - db1065 - T166204

labsdb1001 is almost done, just pending categorylinks table, which is suffering table metadata lock

labsdb1001 is done:

# for i in `cat s1_tables`;do echo $i; mysql --skip-ssl -e "show create table $i\G" enwiki | grep PRI;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
ERROR 1146 (42S02) at line 1: Table 'enwiki.text' doesn't exist
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
ERROR 1146 (42S02) at line 1: Table 'enwiki.log_search' doesn't exist
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.objectcache' doesn't exist
querycache_info
ERROR 1146 (42S02) at line 1: Table 'enwiki.querycache_info' doesn't exist
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.transcache' doesn't exist
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

I am going to start the same alter table on labsdb1003 cloud-services-team
labsdb1001 took a lot less than I expected (only around 30h), so hopefully labsdb1003 will be somewhat similar.

Mentioned in SAL (#wikimedia-operations) [2017-07-18T16:00:22Z] <marostegui> Deploy alter table on s1 - labsdb1003 - T166204

db1065 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1065 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Mentioned in SAL (#wikimedia-operations) [2017-07-19T09:58:14Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1065 - T166204 (duration: 00m 47s)

Change 366223 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Depool db1051

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

Change 366223 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Depool db1051

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

Mentioned in SAL (#wikimedia-operations) [2017-07-19T10:04:07Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Depool db1051 - T166204 (duration: 00m 47s)

Mentioned in SAL (#wikimedia-operations) [2017-07-19T10:06:26Z] <marostegui> Deploy alter table on s1 - db1051 - T166204

db1047 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1047 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

db1051 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1051 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Change 366791 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Repool db1051

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

labsdb1003 is done:

[root@labsdb1003 06:53 /home/marostegui]
# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
ERROR 1146 (42S02) at line 1: Table 'enwiki.text' doesn't exist
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
ERROR 1146 (42S02) at line 1: Table 'enwiki.log_search' doesn't exist
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.objectcache' doesn't exist
querycache_info
ERROR 1146 (42S02) at line 1: Table 'enwiki.querycache_info' doesn't exist
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.transcache' doesn't exist
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Change 366791 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Repool db1051

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

Mentioned in SAL (#wikimedia-operations) [2017-07-21T07:25:20Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1051 - T166204 (duration: 00m 44s)

Change 368607 had a related patch set uploaded (by Marostegui; owner: Marostegui):
[operations/mediawiki-config@master] db-eqiad.php: Depool db1055

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

Change 368607 merged by jenkins-bot:
[operations/mediawiki-config@master] db-eqiad.php: Depool db1055

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

Mentioned in SAL (#wikimedia-operations) [2017-07-31T07:07:23Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Depool db1055 - T166204 (duration: 00m 52s)

Mentioned in SAL (#wikimedia-operations) [2017-07-31T07:12:51Z] <marostegui> Deploy alter table on db1055 - T166204

db1055 is done:

root@neodymium:/home/marostegui# for i in `cat s1_tables`; do echo $i; mysql --skip-ssl -hdb1055 enwiki -e "show create table $i\G" | grep PRIMAR;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
  PRIMARY KEY (`old_id`)
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
  PRIMARY KEY (`ls_field`,`ls_value`,`ls_log_id`),
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
  PRIMARY KEY (`keyname`),
querycache_info
  PRIMARY KEY (`qci_type`)
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
  PRIMARY KEY (`tc_url`)
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),

Mentioned in SAL (#wikimedia-operations) [2017-08-02T06:50:58Z] <marostegui@tin> Synchronized wmf-config/db-eqiad.php: Repool db1055 - T166204 (duration: 00m 45s)

Mentioned in SAL (#wikimedia-operations) [2017-08-03T05:27:42Z] <marostegui> Deploy alter table on enwiki - labsdb1010 - T166204

Marostegui updated the task description. (Show Details)

The last host, labsdb1010 is done:

root@labsdb1010:/home/marostegui# for i in `cat s1_tables`;do echo $i; mysql --skip-ssl -e "show create table $i\G" enwiki | grep PRI;done
categorylinks
  PRIMARY KEY (`cl_from`,`cl_to`),
templatelinks
  PRIMARY KEY (`tl_from`,`tl_namespace`,`tl_title`),
pagelinks
  PRIMARY KEY (`pl_from`,`pl_namespace`,`pl_title`),
text
ERROR 1146 (42S02) at line 1: Table 'enwiki.text' doesn't exist
imagelinks
  PRIMARY KEY (`il_from`,`il_to`),
iwlinks
  PRIMARY KEY (`iwl_from`,`iwl_prefix`,`iwl_title`),
langlinks
  PRIMARY KEY (`ll_from`,`ll_lang`),
log_search
ERROR 1146 (42S02) at line 1: Table 'enwiki.log_search' doesn't exist
math
  PRIMARY KEY (`math_inputhash`)
module_deps
  PRIMARY KEY (`md_module`,`md_skin`)
objectcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.objectcache' doesn't exist
querycache_info
ERROR 1146 (42S02) at line 1: Table 'enwiki.querycache_info' doesn't exist
site_stats
  PRIMARY KEY (`ss_row_id`)
transcache
ERROR 1146 (42S02) at line 1: Table 'enwiki.transcache' doesn't exist
user_former_groups
  PRIMARY KEY (`ufg_user`,`ufg_group`)
user_properties
  PRIMARY KEY (`up_user`,`up_property`),