<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
    <title>Passing Curiosity: Posts tagged elasticsearch</title>
    <link href="https://passingcuriosity.com/tags/elasticsearch/elasticsearch.xml" rel="self" />
    <link href="https://passingcuriosity.com" />
    <id>https://passingcuriosity.com/tags/elasticsearch/elasticsearch.xml</id>
    <author>
        <name>Thomas Sutton</name>
        
        <email>me@thomas-sutton.id.au</email>
        
    </author>
    <updated>2013-11-18T00:00:00Z</updated>
    <entry>
    <title>Inaugural Sydney Elasticsearch Meetup</title>
    <link href="https://passingcuriosity.com/2013/sydney-elasticsearch-meetup/" />
    <id>https://passingcuriosity.com/2013/sydney-elasticsearch-meetup/</id>
    <published>2013-11-18T00:00:00Z</published>
    <updated>2013-11-18T00:00:00Z</updated>
    <summary type="html"><![CDATA[<p>The inaugural <a href="http://www.meetup.com/Elasticsearch-Sydney-Meetup/events/149068632/">Sydney Elasticsearch meetup</a> at Atlassian (who provided the
space, beer, and pizza) featured two talks:</p>
<ul>
<li><p><a href="http://tesser.org">Sharif Olorin</a> from Anchor systems spoke about monitoring Elasticsearch
clusters; and</p></li>
<li><p><a href="https://twitter.com/clintongormley">Clinton Gormley</a>, a core developer, gave an overview of the changes in
the impending 1.0 release.</p></li>
</ul>
<h2 id="sharif-olorin-on-monitoring-elasticsearch">Sharif Olorin on Monitoring Elasticsearch</h2>
<p>Sharif is a developer and system administrator at Anchor Systems and has been
working with Elasticsearch for about a year.</p>
<p>He highlighted a number of key points to be considered by anyone who is
monitoring an Elasticsearch cluster (in no particular order):</p>
<p>You should <strong>monitor every metric</strong> that you can get your hands on and keep as
much data for as long as you can, just in case. Sharif described several cases
where having data available made debugging problems observed in production much
easier.</p>
<p>While you should <em>monitor</em> everything, you should <strong>only alter on metrics
people care about</strong>. Being woken up at 3AM is pretty bad, but it’s worse when
the cause is not really a problem! Loss of redundancy, for example, probably
isn’t worth getting out of bed for; provisioning a new node can wait until
morning.</p>
<p>You should monitor and <strong>alert from your entire cluster</strong>, not just from some
node’s individual opinion about the whole cluster. There are a number of
problem conditions that can be difficult to accurately detect without having a
“whole cluster” view. Whole-cluster monitoring, though, doesn’t play nicely
with most host-based monitoring tools; you’ll probably need to define your own
custom checks which know how to interrogate the whole cluster.</p>
<p>Given that they’ll be checking every node in a cluster, these checks will need
to be highly concurrent and very fast. Sharif showed us a split brain check he
wrote in Golang.</p>
<p>You should <strong>automate recovery</strong> from as many alert conditions as you can.
Where it’s not possible to automatically <em>recover</em> from an error condition, you
should aim to <em>respond</em> sensibly. Sharif described an example, in which an
alert trigger by a split-brain in the cluster might automatically switch all
nodes into read-only mode to prevent divergence.</p>
<p><strong>Use the statistics API</strong> as a source of many useful metrics about your nodes
and their opinions about the cluster. It also exposes a bunch of generic stuff
about the JVM and things.</p>
<p>Finally, Sharif gave a few tips about <em>tuning</em> Elasticsearch clusters. The core
of his advice boiled down to taking a principled approach: tuning individual
parameters, reproducing each test as closely as possible (same time of day,
etc.), consider <em>actual numbers</em> (not just graphs), etc. Essentially: use
science!</p>
<p><a href="https://speakerdeck.com/fractalcat/monitoring-elasticsearch-for-fun-profit-and-not-getting-woken-up-at-3am">Sharif’s slides</a> are available on Speaker Deck; I’ve probably got a bunch
of stuff wrong here, so you should probably go and review them for yourself!</p>
<h2 id="clinton-gormley-on-elasticsearch-1.0">Clinton Gormley on Elasticsearch 1.0</h2>
<p>Clinton works for Elasticsearch where he develops the Perl client libraries,
does training and evangelising, “keeps Elasticsearch honest” and some other
stuff. He gave us a run down on the new features and other improvements in the
forthcoming Elasticsearch 1.0 release.</p>
<p>Amongst the many things mentioned, these few stuck out to me:</p>
<p>You cannot currently use different versions of Elasticsearch in the same
cluster; upgrades involve tearing down your entire cluster and bringing up a
new one (possibly not in that order). 1.0 will allow <strong>rolling upgrades</strong> of
your nodes without having to do the whole cluster in one fell swoop.</p>
<p>You <em>can</em> <strong>backup</strong> the data in current Elasticsearch clusters, but it’s very
much a do-it-yourself process: disable flushing, find all primary shard
locations, copy their files, enable flushing. Version 1.0 will provide API
methods to trigger a snapshot which will be written to a configured
<em>repository</em> (S3, HDFS, etc.) Comparable changes have been made to the process
of <strong>restoring</strong> a snapshot: the current manual process will be replaced with a
few API calls.</p>
<p>The <strong>percolator</strong> functionality – which allows applications to do things like
reverse search, alerts, and updatable result sets – is now implemented in a
way which lets it scale as well as any other index in the cluster. It also
supports multiple indices, aliases, and has a bunch of other improvements.</p>
<p>The new <strong>cat API</strong> provides direct access to a range of metrics in
human-friendly formats (i.e. not large JSON documents). This includes a bunch
of things that humans and monitoring systems are often curious about: sizes,
counts, statuses, etc.</p>
<p>The existing support for facets has been drastically improved with a new
feature called <strong>aggregations</strong>. These allow you to express a bunch of things
which aren’t really expressible with traditional facets. These looked very
powerful and very cool!</p>
<p><a href="https://speakerdeck.com/elasticsearch/new-features-in-elasticsearch-v1-dot-0">Clinton’s slides</a> (originally prepared by Igor Motov) are available on
Speaker Deck; go read them!</p>
<p>The questions prompted a few interesting details: Elasticsearch have just hired
a few machine learning people to work on the product; they aren’t yet sure
what, specifically, they’ll be working on, but we can expect some learning-type
things in Elasticsearch soon.</p>]]></summary>
</entry>

</feed>
