Skip to content

Performance Retention

sethcleveland edited this page May 13, 2014 · 5 revisions

Overview

Europa stores all performance data (aka metrics) in Hbase using Opentsdb. The default retention policy saves the data forever. To change the default policy, the time to live (TTL) most be adjusted on the opentsdb column families in Hbase. The following steps explain how to change the TTL value using serviced and europa. TTL is defined in seconds and is a positive integer with a maximum value of 2147483647. Once the TTL value's changed, the data will adjust on the next major HBase compaction. By default, HBase performs a major compaction once per day.

Steps

Stop performance data writing

  1. Go to the serviced UI and stop the opentsdb writer service

Set the TTL value

  1. Using the UI or cli to identify the opentsdb reader service id
  2. SSH into the host running the opentsdb reader service
  3. Run the following ($id is the opentsdb reader service id, $ttl is your desired ttl value):

serviced service shell $id /opt/opentsdb/set-opentsdb-table-ttl.sh $ttl

Start performance data writing

  1. Go to the serviced UI and start the opentsdb writer service

References

  1. http://hbase.apache.org/book/ttl.html