Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Making Carbon in Graphite accept all data, no matter what

Tags:

graphite

The Carbon listener in Graphite has been designed and tuned to make it somewhat predictable in its load on your server, to avoid flooding the server itself with IO wait or skyrocketing the system load overall. It will drop incoming data if necessary, putting server load as the priority. After all, for the typical data being stored, it's no big deal.

I appreciate all that. However, I am trying to prime a large backlog of data into graphite, from a different source, instead of pumping in live data as it happens. I have a reliable data source from a third party that comes to me in bulk, once/day.

So in this case, I don't want any data values dropped on the floor. I don't really care how long the data import takes. I just want to disable all the safety mechanisms, let carbon do its thing, and know ALL my data has made it in.

I'm searching the docs and finding all kinds of advice on tuning the parameters of carbon_cache in carbon.conf, but I can't find this. It is starting to sound more like art than science. Any help appreciated.

like image 441
IcarusNM Avatar asked Oct 20 '22 21:10

IcarusNM


1 Answers

First thing of course is to receive data through tcp listener (line receiver) instead of udp to avoid loosing incoming points.

There are several settings in graphite that throttle part of the pipeline, though it is not always clear of what graphite does when threshold are reached. You'll have to test and/or read the carbon code.

You'll probably want to tune:

MAX_UPDATES_PER_SECOND = 500 (max number of disk updates in a second)

MAX_CREATES_PER_MINUTE = 50 (max number of metric creation per minute)

For the cache, USE_FLOW_CONTROL = True and MAX_CACHE_SIZE = inf (inf is a good value so revert to this if you changed it)

If you use a relay and/or aggregator, MAX_QUEUE_SIZE = 10000 and USE_FLOW_CONTROL = True are important.

like image 158
kamaradclimber Avatar answered Oct 23 '22 01:10

kamaradclimber