]> arthur.barton.de Git - netdata.git/blob - README.md
Update README.md
[netdata.git] / README.md
1 netdata
2 =======
3
4 linux real time system monitoring
5
6 This program is a daemon that collects system information from /proc and other sources.
7 It is heavily optimized and lightweight.
8
9 It updates everything every second!
10 But tt only needs a few microseconds (just a fraction of a millisecond) of one of your cores and a few megabytes of memory.
11
12 If listens on port 19999 and it will give you a full featured web interface using google charts.
13
14 Check it live at:
15
16 http://www.tsaousis.gr:19999/
17
18 Here is a screenshot:
19
20 ![image](https://cloud.githubusercontent.com/assets/2662304/2593406/3c797e88-ba80-11e3-8ec7-c10174d59ad6.png)
21
22 # How it works
23
24 1. You run a daemon on your linux: netdata.
25  This deamon is written in C and is extremely lightweight.
26  
27  netdata:
28
29   - reads several /proc files
30   - keeps track of the values in memroy (a short history)
31   - generates JSON and JSONP HTTP responses containing all the data needed for the web graphs
32   - is a web server. You can access JSON data by using:
33  
34  ```
35  http://127.0.0.1:19999/data/net.eth0
36  ```
37  
38  This will give you the JSON file for traffic on eth0.
39  The above is equivalent to:
40  
41  ```
42  http://127.0.0.1:19999/data/net.eth0/3600/1/average
43  ```
44  
45  where:
46
47   - 3600 is the number of entries to generate (3600 is a default which can be overwritten by -l).
48   - 1 is grouping count, 1 = every single entry, 2 = half the entries, 3 = one every 3 entries, etc
49   - `average` is the grouping method. It can also be `max`.
50
51
52 2. On your web page, you add a few javascript lines and a DIV for every graph you need.
53  Your browser will hit the web server to fetch the JSON data and refresh the graphs.
54
55 3. Graphs are generated using Google Charts API.
56
57
58
59 # Installation
60
61 ## Automatic installation
62
63 1. Download the git.
64 2. cd to that directory
65 3. run:
66
67 ```sh
68 ./netdata.start
69 ```
70
71 Once you run it, the file netdata.conf will be created. You can edit this file to set options for each graph.
72 To apply the changes you made, you have to run netdata.start again.
73
74 To access the web site for all graphs, go to:
75
76  ```
77  http://127.0.0.1:19999/
78  ```
79
80
81
82 ---
83
84 ## Installation by hand
85
86 ### Compile netdata
87 step into the directory you downloaded everything and compile netdata
88
89 ```sh
90 gcc -Wall -O3 -o netdata netdata.c -lpthread -lz
91 ```
92
93 ### run netdata
94 Run netdata:
95
96 ```sh
97 ./netdata -u nobody -d -l 1200 -u 1 -p 19999
98 ```
99  - -d says to go daemon mode
100  - -l 1200 says to keep 1200 history entries (20 minutes)
101  - -t 1 says to add a new history entry every second
102  - -p 19999 is the port to listen for web clients
103  - -u nobody to run as nobody
104
105 ### open a web browser
106
107  ```
108  http://127.0.0.1:19999/
109  ```
110