You are browsing a read-only backup copy of Wikitech. The primary site can be found at wikitech.wikimedia.org

Incident documentation/2021-09-13 cirrussearch restart

From Wikitech-static
< Incident documentation
Revision as of 19:45, 13 September 2021 by imported>Legoktm (+higher api latency)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

document status: draft

Summary

Applying a change to our cirrus elasticsearch systemd unit triggered puppet to automatically restart the associated elasticsearch services. Sufficient number of hosts (6) were having puppet-agent ran simultaneously to drop the cluster into yellow and then red status; the large bandwidth/resources required to reschedule and assign shards when the respective elasticsearch services came back up on each host likely contributed to general cluster instability leading to a cascading failure scenario.

Elasticsearch itself did its job in coming back and immediately recovering shards, but given the volume of hosts restarted, it took about 40 minutes for the impact to users to become largely invisible, and TODO minutes for a full recovery of the backend (i.e. green cluster status).

16:18 Puppet change touching cirrus elasticsearch systemd units merged: https://gerrit.wikimedia.org/r/c/operations/puppet/+/720667

16:23 operator runs puppet manually on elastic2052, confirmed elasticsearch service came back up properly

16:25 operator runs puppet on rest of fleet, 6 hosts at a time: sudo cumin -b 6 'P{elastic*}' 'sudo run-puppet-agent'

16:29 PROBLEM - PyBal backends health check on lvs1015 is CRITICAL: PYBAL CRITICAL - CRITICAL - search-psi-https_9643: Servers elastic1059.eqiad.wmnet, elastic1049.eqiad.wmnet, elastic1044.eqiad.wmnet, elastic1048.eqiad.wmnet, elastic1052.eqiad.wmnet, elastic1047.eqiad.wmnet, elastic1067.eqiad.wmnet, elastic1035.eqiad.wmnet, elastic1045.eqiad.wmnet are marked down but pooled https://wikitech.wikimedia.org/wiki/PyBal

16:31 ElasticSearch health check for shards on 9243 on search.svc.codfw.wmnet is CRITICAL. At the same time, production-search-codfw has dropped into red cluster status

17:09 enwiki searches are working again (presumably due to recovery of the associated enwiki shards). This resolves the most critical user-facing impact.

17:?? codfw enters green cluster status (full recovery)

17:?? eqiad enters green cluster status (full recovery)

18:30 MediaWiki api_appserver latency returns to normal levels

Impact: Search requests on en.wikipedia.org (and likely other wikis as well) failed with "An error has occurred while searching: Search is currently too busy. Please try again later."; this outage persisted for about 40 minutes, from 16:29 until 17:09. Until the cluster recovered 100%, the MediaWiki api_appserver cluster saw higher latency because of slower search requests.

Documentation:

Actionables

  • task T290902 Iron out procedure to roll out cirrus/elasticsearch changes involving [implicitly via puppet or explicitly] service restarts)