You are browsing a read-only backup copy of Wikitech. The live site can be found at

Portal:Data Services/Admin/Wiki Replica DNS

From Wikitech-static
< Portal:Data Services‎ | Admin
Revision as of 16:44, 30 September 2017 by imported>BryanDavis (Reverted edits by Tarawa1943 (talk) to last revision by BryanDavis)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

The Wiki Replica servers use service names managed by the Cloud VPS Designate API to expose databases to Cloud Services users. The /usr/local/sbin/wikireplica_dns script is used to create and update these service names. These operations are performed from the currently active labcontrol server (typically

Changing the backend server for a shard

The /etc/wikireplica_dns.yaml config file tells wikireplica_dns which IPs to map to which service names. This file is managed by Puppet using the source file found at modules/openstack2/files/util/wikireplica_dns.yaml. Management is done at the granularity of a shard.

To change the backend server for one or more shards, edit the yaml config file and then run:

$ ssh
$ source <(sudo cat ~root/
$ /usr/local/sbin/wikireplica_dns

Adding a new wikidb alias

Aliases for each wikidb in each zone are made based on the wikidb mappings found in the s[1-7].dblist files managed in operations/mediawiki-config.git. The current values are read from at runtime.

When a new wikidb is added or moved between shards, update the related <wikidb>.{analytics,web}.svc.eqiad.wmflabs CNAME records. Limiting the run to a single shard will be significantly faster unless the shard is s3 which has most of the aliases.

$ ssh
$ source <(sudo cat ~root/
$ /usr/local/sbin/wikireplica_dns --aliases [--shard <sN>]