]> arthur.barton.de Git - netdata.git/blob - README.md
updated readme
[netdata.git] / README.md
1 netdata
2 =======
3
4 linux real time system monitoring over the web
5
6 Netdata is a daemon that collects system information from a linux system and presents a web site to view the data.
7 The presentation is full of charts that precisely render all system values, in realtime, for a short time (1 hour by default).
8
9 You can use it to monitor all your servers, linux PCs or linux embedded devices, without the need to ssh to them.
10 Also, you can view a short history of all collected values.
11
12 Check it live at:
13
14  - [My Home Gentoo Box](http://195.97.5.206:19999/)
15  - [My Home Raspberry Pi B+](http://195.97.5.202:19999/) with data collection every 5s (raspbian playing movies 24x7)
16  - [My Home Raspberry Pi 2](http://195.97.5.203:19999/) (osmc as an access point)
17
18 Here is a screenshot:
19
20 ![image](https://cloud.githubusercontent.com/assets/2662304/2593406/3c797e88-ba80-11e3-8ec7-c10174d59ad6.png)
21
22
23 # Features
24
25 - **highly optimized C code**
26
27   It only needs a few milliseconds per second to collect all the data.
28   It will nicelly run even on a raspberry pi with just one cpu core, or any other embedded system.
29
30 - **extremely lightweight**
31
32   It only needs a few megabytes of memory to store all its round robin database.
33   
34   Internally, it uses a **custom-made 32-bit number** to store all the values, along with a limited number of metadata for each collected value. This floating point number can store in 32 bits values from -167772150000000.0 to  167772150000000.0 with a precision of 0.00001 (yes, it is a floating point number, meaning that higher integer values have less decimal precision). Of course, this provides an extremely optimized memory footprint. 
35
36 - **per second data collection**
37
38   Every chart, every value, is updated every second. Of course, you can control collection period per module.
39
40 - **visualizes QoS classes automatically**
41
42   If you also use FireQOS for QoS, it collects class names automatically.
43
44 - **appealing web site**
45
46   The web site uses bootstrap and google charts for a very appealing result.
47   It works even on mobile devices and adapts to screen size changes and rotation.
48
49 - **web charts do respect your browser resources**
50
51   The charts adapt to show only as many points are required to have a clear view.
52   Also, the javascript code respects your browser resources (stops refreshing when the window looses focus, when scrolling, etc).
53
54 - **highly configurable**
55
56   All charts and all features can be enabled or disabled.
57   The program generates its configuration file based on the resources available on the system it runs, for you to edit.
58
59 - It reads and renders charts for all these:
60  - `/proc/net/dev` (all netwrok interfaces for all their values)
61  - `/proc/diskstats` (all disks for all their values)
62  - `/proc/net/snmp` (total IPv4, TCP and UDP usage)
63  - `/proc/net/netstat` (more IPv4 usage)
64  - `/proc/net/stat/nf_conntrack` (connection tracking performance)
65  - `/proc/net/ip_vs/stats` (IPVS connection statistics)
66  - `/proc/stat` (CPU utilization)
67  - `/proc/meminfo` (memory information)
68  - `/proc/vmstat` (system performance)
69  - `/proc/net/rpc/nfsd` (NFS server statistics for both v3 and v4 NFS)
70  - `tc` classes (QoS classes)
71
72 - It supports **plugins** for collecting information from other sources!
73
74   Plugins can be written in any computer language (pipe / stdout communication for data collection).
75
76   It ships with 2 plugins: `apps.plugin` and `charts.d.plugin`:
77
78  - `apps.plugin` is a plugin that attempts to collect statistics per process.
79
80  - `charts.d.plugin` provides a simple way to script data collection in BASH. It includes example plugins that collect values from:
81
82   - `nut` (UPS load, frequency, voltage, etc)
83   - `pi` (raspberry pi CPU clock and temperature)
84   - `postfix` (e-mail queue size)
85   - `squid` (web proxy statistics)
86
87 - netdata is a web server, supporting gzip compression
88
89   It serves its own static files and dynamic files for rendering the site.
90   (it does not support authentication or SSL - limit its access using your firewall)
91
92
93 # How it works
94
95 1. You run a daemon on your linux: netdata.
96  This deamon is written in C and is extremely lightweight.
97  
98  netdata:
99
100   - reads several /proc files
101   - keeps track of the values in memroy (a short history)
102   - generates JSON and JSONP HTTP responses containing all the data needed for the web graphs
103   - is a web server. You can access JSON data by using:
104  
105  ```
106  http://127.0.0.1:19999/data/net.eth0
107  ```
108  
109  This will give you the JSON file for traffic on eth0.
110  The above is equivalent to:
111  
112  ```
113  http://127.0.0.1:19999/data/net.eth0/3600/1/average/0/0
114  ```
115  
116  where:
117
118   - 3600 is the number of entries to generate.
119   - 1 is grouping count, 1 = every single entry, 2 = half the entries, 3 = one every 3 entries, etc
120   - `average` is the grouping method. It can also be `max`.
121   - 0/0 they are `before` and `after` timestamps, allowing panning on the data
122
123
124 2. On your web page, you add a few javascript lines and a DIV for every graph you need.
125  Your browser will hit the web server to fetch the JSON data and refresh the graphs.
126
127 3. Graphs are generated using Google Charts API (so, your client needs to have internet access).
128
129
130 # Installation
131
132 ## Automatic installation
133
134 Before you start, make sure you have `zlib` development files installed.
135 To install it in Ubuntu, you need to run:
136
137 ```sh
138 apt-get install zlib1g-dev
139 ```
140
141 Then do this to install and run netdata:
142
143 ```sh
144 git clone https://github.com/ktsaou/netdata.git netdata.git
145 cd netdata.git
146 ./netdata.start
147 ```
148
149 Once you run it, the file conf.d/netdata.conf will be created. You can edit this file to set options for each graph.
150 To apply the changes you made, you have to run netdata.start again.
151
152 To access the web site for all graphs, go to:
153
154  ```
155  http://127.0.0.1:19999/
156  ```
157