Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Paste
P5138
(An Untitled Masterwork)
Active
Public
Actions
Authored by
jcrespo
on Mar 27 2017, 2:41 PM.
Edit Paste
Archive Paste
View Raw File
Subscribe
Mute Notifications
Award Token
Flag For Later
Tags
None
Referenced Files
F7037981:
Mar 27 2017, 2:41 PM
2017-03-27 14:41:07 (UTC+0)
Subscribers
None
# this is a constant for now
tendril_db_host=db1011.eqiad.wmnet
# for each shard, new master and shard name
new_shard_master_fqdn=db1052.eqiad.wmnet
shard=s1
# actual command to run, needs to have rights (saltmaster)
mysql -h $tendril_db_host tendril -e "UPDATE shards SET master_id = (SELECT id FROM servers WHERE host = '$new_shard_master_fqdn') WHERE name = '$shard'"
Event Timeline
jcrespo
created this paste.
Mar 27 2017, 2:41 PM
2017-03-27 14:41:07 (UTC+0)
Log In to Comment