Skip to content
Newer
Older
100644 48 lines (32 sloc) 1.76 KB
f1a155e First commit.
Evan Miller authored
1 mod_rrd_graph
2 =============
3
4 RRDtool[1] stores and graphs time-series data. ngx_rrd_graph provides an HTTP
5 interface to RRDtool's graphing facilities. By linking RRDtool code directly
6 into Nginx, it is faster than scripts and CGIs with similar purposes.
7
8 To install, compile nginx with this option:
9
10 --add-module=/path/to/this/directory
11
12 ngx_rrd_graph requires RRDtool 1.3 or later.
13
14 After compiling, installing, and restarting Nginx, ngx_rrd_graph can be enabled
15 at a particular location with the "rrd_graph" directive, like so:
16
17 location /rrdtool {
18 rrd_graph;
19 }
20
21 RRDtool graphing commands can then be appended to that location in request
22 URLs. The syntax is just the same as the arguments to the "rrdtool graph"
23 command, omitting the filename. (Refer to rrdgraph(1).) These commands should
24 be URL-encoded, so that this command-line invocation:
25
26 rrdtool graph --start now-300s \
27 --end now \
28 DEF:ds0=test.rrd:reading:AVERAGE \
29 LINE1:ds0#00FF00
30
31 becomes:
32
33 http://mysite.com/rrdtool--start%20now-300s%20--end%20now%20DEF%3Ads0%3Dtest.rrd%3Areading%3AAVERAGE%20LINE1%3Ads0%2300FF00
34
a67111a Support spaces with quotation marks around strings
Evan Miller authored
35 If you need spaces in arguments, put quotation marks ("") around the string.
36
f1a155e First commit.
Evan Miller authored
37 The module supports all the features of your copy of RRDtool. It can output
38 PNG, PDF, SVG, and EPS graphics (see the --imgformat option of rrdgraph(1)).
39
40 If you'd prefer not to provide absolute paths to files referenced in DEF commands,
41 you may supply a root directory with the "rrd_graph_root" directive. Files mentioned
42 in DEF commands will be automatically prefixed with the value of rrd_graph_root.
43 As of this writing there are no guards against relative paths (e.g. "..").
44
45 Questions/comments to emmiller@gmail.com.
46
47 [1] http://oss.oetiker.ch/rrdtool/
Something went wrong with that request. Please try again.