Move installer dir under packaging (#5009)
* move installer dir under packaging * fix docs creation * uninstaller is broken and fix will be created in #5031 * fix links in docs
Paweł Krupa committed
Dec 19, 2018 at 12:08 UTC
545aa974552f45ecd7950dbd53ec36bae60fb838
21 files changed
+339
-339
Makefile.am
+8
-8
@@ -78,9 +78,9 @@ dist_noinst_DATA= \
78
docs/Charts.md \
79
docs/configuration-guide.md \
80
docs/generator/custom \
81
- installer/README.md \
82
- installer/UNINSTALL.md \
83
- installer/UPDATE.md \
81
+ packaging/installer/README.md \
82
+ packaging/installer/UNINSTALL.md \
83
+ packaging/installer/UPDATE.md \
84
netlify.toml \
85
$(NULL)
86
@@ -91,7 +91,7 @@ dist_noinst_SCRIPTS= \
91
kickstart.sh \
92
kickstart-static64.sh \
93
netdata-installer.sh \
94
- installer/functions.sh \
94
+ packaging/installer/functions.sh \
95
docs/generator/buildhtml.sh \
96
docs/generator/buildyaml.sh \
97
docs/generator/checklinks.sh \
@@ -125,10 +125,10 @@ AM_CFLAGS = \
125
$(NULL)
126
127
sbin_PROGRAMS =
128
-dist_cache_DATA = installer/.keep
129
-dist_varlib_DATA = installer/.keep
130
-dist_registry_DATA = installer/.keep
131
-dist_log_DATA = installer/.keep
128
+dist_cache_DATA = packaging/installer/.keep
129
+dist_varlib_DATA = packaging/installer/.keep
130
+dist_registry_DATA = packaging/installer/.keep
131
+dist_log_DATA = packaging/installer/.keep
132
plugins_PROGRAMS =
133
134
LIBNETDATA_FILES = \
README.md
+2
-2
@@ -94,7 +94,7 @@ The above command will:
94
2. download netdata source to `/usr/src/netdata.git`
95
3. compile it, install it and start it
96
97
-More installation methods and additional options can be found at the [installation page](installer/#installation).
97
+More installation methods and additional options can be found at the [installation page](packaging/installer/#installation).
98
99
To try netdata in a docker container, run this:
100
@@ -459,7 +459,7 @@ Here is a quick list:
459
460
Directory|Description
461
:---|:---
462
-[`installer`](installer/)|Instructions to install netdata on your systems.
462
+[`installer`](packaging/installer/)|Instructions to install netdata on your systems.
463
[`docker`](packaging/docker/)|Instructions to install netdata using docker.
464
[`daemon`](daemon/)|Information about the netdata daemon and its configuration.
465
[`collectors`](collectors/)|Information about data collection plugins.
backends/WALKTHROUGH.md
+1
-1
@@ -67,7 +67,7 @@ chooses the base container images (centos:latest). After running this you should
67
be sitting inside the shell of the container.
68
69
After we have entered the shell we can install Netdata. This process could not
70
-be easier. If you take a look at [this link](../installer/#installation), the Netdata devs give us
70
+be easier. If you take a look at [this link](../packaging/installer/#installation), the Netdata devs give us
71
several one-liners to install netdata. I have not had any issues with these one
72
liners and their bootstrapping scripts so far (If you guys run into anything do
73
share). Run the following command in your container.
backends/prometheus/README.md
+1
-1
@@ -9,7 +9,7 @@ Prometheus is a distributed monitoring system which offers a very simple setup a
9
10
### Installing netdata
11
12
-There are number of ways to install netdata according to [Installation](../../installer/#installation)
12
+There are number of ways to install netdata according to [Installation](../../packaging/installer/#installation)
13
The suggested way of installing the latest netdata and keep it upgrade automatically. Using one line installation:
14
15
```
contrib/rhel/build-netdata-rpm.sh
+1
-1
@@ -5,7 +5,7 @@
5
6
cd "$(dirname "$0")/../../" || exit 1
7
# shellcheck disable=SC1091
8
-source "installer/functions.sh" || exit 1
8
+source "packaging/installer/functions.sh" || exit 1
9
10
set -e
11
docs/GettingStarted.md
+3
-3
@@ -1,6 +1,6 @@
1
# Getting Started
2
3
-These are your first steps **after** you have installed netdata. If you haven't installed it already, please check the [installation page](../installer).
3
+These are your first steps **after** you have installed netdata. If you haven't installed it already, please check the [installation page](../packaging/installer).
4
5
## Accessing the dashboard
6
@@ -14,11 +14,11 @@ http://your.server.ip:19999/
14
15
**Verify Netdata is running.**
16
17
-Open an ssh session to the server and execute `sudo ps -e | grep netdata`. It should respond with the PID of the netdata daemon. If it prints nothing, Netdata is not running. Check the [installation page](../installer) to install it.
17
+Open an ssh session to the server and execute `sudo ps -e | grep netdata`. It should respond with the PID of the netdata daemon. If it prints nothing, Netdata is not running. Check the [installation page](../packaging/installer) to install it.
18
19
**Verify Netdata responds to HTTP requests.**
20
21
-Using the same ssh session, execute `curl -Ss http://localhost:19999`. It should dump on your screen the `index.html` page of the dashboard. If it does not, check the [installation page](../installer) to install it.
21
+Using the same ssh session, execute `curl -Ss http://localhost:19999`. It should dump on your screen the `index.html` page of the dashboard. If it does not, check the [installation page](../packaging/installer) to install it.
22
23
**Verify Netdata receives the HTTP requests.**
24
docs/generator/buildyaml.sh
+3
-3
@@ -125,10 +125,10 @@ echo -ne " - 'docs/Why-Netdata.md'
125
- CHANGELOG.md
126
- CONTRIBUTING.md
127
- Installation:
128
- - 'installer/README.md'
128
+ - 'packaging/installer/README.md'
129
- 'packaging/docker/README.md'
130
- - 'installer/UPDATE.md'
131
- - 'installer/UNINSTALL.md'
130
+ - 'packaging/installer/UPDATE.md'
131
+ - 'packaging/installer/UNINSTALL.md'
132
- 'docs/GettingStarted.md'
133
- Running netdata:
134
- 'daemon/README.md'
kickstart-static64.sh
+1
-1
@@ -9,7 +9,7 @@ umask 022
9
[ -z "${UID}" ] && export UID="$(id -u)"
10
11
# ---------------------------------------------------------------------------------------------------------------------
12
-# library functions copied from installer/functions.sh
12
+# library functions copied from packaging/installer/functions.sh
13
14
which_cmd() {
15
# shellcheck disable=SC2230
kickstart.sh
+1
-1
@@ -31,7 +31,7 @@ umask 022
31
[ -z "${UID}" ] && UID="$(id -u)"
32
33
# ---------------------------------------------------------------------------------------------------------------------
34
-# library functions copied from installer/functions.sh
34
+# library functions copied from packaging/installer/functions.sh
35
36
which_cmd() {
37
# shellcheck disable=SC2230
makeself/build-x86_64-static.sh
+1
-1
@@ -1,7 +1,7 @@
1
#!/usr/bin/env bash
2
# SPDX-License-Identifier: GPL-3.0-or-later
3
4
-. $(dirname "$0")/../installer/functions.sh || exit 1
4
+. $(dirname "$0")/../packaging/installer/functions.sh || exit 1
5
6
set -e
7
makeself/functions.sh
+1
-1
@@ -49,7 +49,7 @@ fetch() {
49
# -----------------------------------------------------------------------------
50
51
# load the functions of the netdata-installer.sh
52
-. "${NETDATA_SOURCE_PATH}/installer/functions.sh"
52
+. "${NETDATA_SOURCE_PATH}/packaging/installer/functions.sh"
53
54
# -----------------------------------------------------------------------------
55
makeself/jobs/99-makeself.install.sh
+1
-1
@@ -45,7 +45,7 @@ run mkdir -p "${NETDATA_INSTALL_PATH}/system"
45
run cp \
46
makeself/post-installer.sh \
47
makeself/install-or-update.sh \
48
- installer/functions.sh \
48
+ packaging/installer/functions.sh \
49
configs.signatures \
50
system/netdata-init-d \
51
system/netdata-lsb \
netdata-installer.sh
+6
-6
@@ -34,10 +34,10 @@ cd "${netdata_source_dir}" || exit 1
34
# -----------------------------------------------------------------------------
35
# load the required functions
36
37
-if [ -f "${installer_dir}/installer/functions.sh" ]; then
38
- source "${installer_dir}/installer/functions.sh" || exit 1
37
+if [ -f "${installer_dir}/packaging/installer/functions.sh" ]; then
38
+ source "${installer_dir}/packaging/installer/functions.sh" || exit 1
39
else
40
- source "${netdata_source_dir}/installer/functions.sh" || exit 1
40
+ source "${netdata_source_dir}/packaging/installer/functions.sh" || exit 1
41
fi
42
43
# make sure we save all commands we run
@@ -885,7 +885,7 @@ fi
885
# -----------------------------------------------------------------------------
886
progress "Create netdata-uninstaller.sh"
887
888
-cp ./installer/netdata-uninstaller.sh netdata-uninstaller.sh
888
+cp ./packaging/installer/netdata-uninstaller.sh netdata-uninstaller.sh
889
chmod 750 netdata-uninstaller.sh
890
891
# -----------------------------------------------------------------------------
@@ -911,7 +911,7 @@ END
911
echo >&2 "Uninstall script is located at: ${TPUT_RED}${TPUT_BOLD}./netdata-uninstaller.sh${TPUT_RESET}"
912
913
if [ -d .git ]; then
914
- cp ./installer/netdata-updater.sh netdata-updater.sh
914
+ cp ./packaging/installer/netdata-updater.sh netdata-updater.sh
915
sed -i "s|THIS_SHOULD_BE_REPLACED_BY_INSTALLER_SCRIPT|${REINSTALL_PWD}|" netdata-updater.sh
916
chmod 755 netdata-updater.sh
917
echo >&2 "Update script is located at: ${TPUT_GREEN}${TPUT_BOLD}./netdata-updater.sh${TPUT_RESET}"
@@ -956,7 +956,7 @@ else
956
fi
957
958
# Save environment variables
959
-cat <<EOF > installer/.environment.sh
959
+cat <<EOF > packaging/installer/.environment.sh
960
PATH="${PATH}"
961
CFLAGS="${CFLAGS}"
962
NETDATA_PREFIX="${NETDATA_PREFIX}"
packaging/installer/.keep
renamed
packaging/installer/README.md
renamed
+300
-300
@@ -17,7 +17,7 @@ The best way to install Netdata is directly from source. Our **automatic install
17
7. [Enable on FreeNAS Corral](#freenas)
18
8. [Install on macOS (OS X)](#macos)
19
20
-See also the list of Netdata [package maintainers](../packaging/maintainers) for ASUSTOR NAS, OpenWRT, ReadyNAS, etc.
20
+See also the list of Netdata [package maintainers](../maintainers) for ASUSTOR NAS, OpenWRT, ReadyNAS, etc.
21
22
---
23
@@ -31,7 +31,7 @@ To install Netdata from source and keep it up to date automatically, run the fol
31
bash <(curl -Ss https://my-netdata.io/kickstart.sh)
32
```
33
34
-*(do not `sudo` this command, it will do it by itself as needed)*
34
+*(do not `sudo` this command, it will do it by itself as needed)*
35
36
 
37
@@ -47,43 +47,43 @@ Verify the integrity of the script with this:
47
48
The `kickstart.sh` script:
49
50
-- detects the Linux distro and **installs the required system packages** for building Netdata (will ask for confirmation)
51
-- downloads the latest Netdata source tree to `/usr/src/netdata.git`.
52
-- installs Netdata by running `./netdata-installer.sh` from the source tree.
50
+- detects the Linux distro and **installs the required system packages** for building Netdata (will ask for confirmation)
51
+- downloads the latest Netdata source tree to `/usr/src/netdata.git`.
52
+- installs Netdata by running `./netdata-installer.sh` from the source tree.
53
- installs `netdata-updater.sh` to `cron.daily`, so your Netdata installation will be updated daily (you will get a message from cron only if the update fails).
54
- For QA purposes, this installation method lets us know if it succeed or failed.
55
56
-The `kickstart.sh` script passes all its parameters to `netdata-installer.sh`, so you can add more parameters to change the installation directory, enable/disable plugins, etc (check below).
57
-
56
+The `kickstart.sh` script passes all its parameters to `netdata-installer.sh`, so you can add more parameters to change the installation directory, enable/disable plugins, etc (check below).
57
+
58
For automated installs, append a space + `--dont-wait` to the command line. You can also append `--dont-start-it` to prevent the installer from starting Netdata. Example:
59
-
59
+
60
```bash
61
bash <(curl -Ss https://my-netdata.io/kickstart.sh) --dont-wait --dont-start-it
62
```
63
64
</details> <br/>
65
66
-Once Netdata is installed, see [Getting Started](../docs/GettingStarted.md).
66
+Once Netdata is installed, see [Getting Started](../../docs/GettingStarted.md).
67
68
---
69
70
## Linux 64bit pre-built static binary
71
72
-You can install a pre-compiled static binary of Netdata on any Intel/AMD 64bit Linux system
73
-(even those that don't have a package manager, like CoreOS, CirrOS, busybox systems, etc).
72
+You can install a pre-compiled static binary of Netdata on any Intel/AMD 64bit Linux system
73
+(even those that don't have a package manager, like CoreOS, CirrOS, busybox systems, etc).
74
You can also use these packages on systems with broken or unsupported package managers.
75
76
To install Netdata with a binary package on any Linux distro, any kernel version - for **Intel/AMD 64bit** hosts, run the following:
77
-
77
+
78
```bash
79
80
- bash <(curl -Ss https://my-netdata.io/kickstart-static64.sh)
80
+ bash <(curl -Ss https://my-netdata.io/kickstart-static64.sh)
81
82
```
83
84
*(do not `sudo` this command, it will do it by itself as needed; if the target system does not have `bash` installed, see below for instructions to run it without `bash`)*
85
86
- 
86
+ 
87
88
> The static builds install Netdata at **`/opt/netdata`**
89
@@ -98,27 +98,27 @@ Verify the integrity of the script with this:
98
99
*It should print `OK, VALID` if the script is the one we ship.*
100
101
-For automated installs, append a space + `--dont-wait` to the command line. You can also append `--dont-start-it` to prevent the installer from starting Netdata.
102
-
103
-Example:
104
-
101
+For automated installs, append a space + `--dont-wait` to the command line. You can also append `--dont-start-it` to prevent the installer from starting Netdata.
102
+
103
+Example:
104
+
105
```bash
106
107
- bash <(curl -Ss https://my-netdata.io/kickstart-static64.sh) --dont-wait --dont-start-it
107
+ bash <(curl -Ss https://my-netdata.io/kickstart-static64.sh) --dont-wait --dont-start-it
108
109
```
110
111
-If your shell fails to handle the above one liner, do this:
112
-
111
+If your shell fails to handle the above one liner, do this:
112
+
113
```bash
114
-# download the script with curl
115
-curl https://my-netdata.io/kickstart-static64.sh >/tmp/kickstart-static64.sh
116
-
117
-# or, download the script with wget
118
-wget -O /tmp/kickstart-static64.sh https://my-netdata.io/kickstart-static64.sh
119
-
120
-# run the downloaded script (any sh is fine, no need for bash)
121
-sh /tmp/kickstart-static64.sh
114
+# download the script with curl
115
+curl https://my-netdata.io/kickstart-static64.sh >/tmp/kickstart-static64.sh
116
+
117
+# or, download the script with wget
118
+wget -O /tmp/kickstart-static64.sh https://my-netdata.io/kickstart-static64.sh
119
+
120
+# run the downloaded script (any sh is fine, no need for bash)
121
+sh /tmp/kickstart-static64.sh
122
```
123
124
- The static binary files are kept in repo [binary-packages](https://github.com/netdata/binary-packages). You can download any of the `.run` files, and run it. These files are self-extracting shell scripts built with [makeself](https://github.com/megastep/makeself).
@@ -128,284 +128,284 @@ sh /tmp/kickstart-static64.sh
128
129
</details> <br/>
130
131
-Once Netdata is installed, see [Getting Started](../docs/GettingStarted.md).
131
+Once Netdata is installed, see [Getting Started](../../docs/GettingStarted.md).
132
133
---
134
135
## Run Netdata in a Docker container
136
-
137
-You can [Install Netdata with Docker](../packaging/docker/#install-netdata-with-docker).
136
+
137
+You can [Install Netdata with Docker](../docker/#install-netdata-with-docker).
138
+
139
+---
140
+
141
+## Install Netdata on Linux manually
142
+
143
+To install the latest git version of Netdata, please follow these 2 steps:
144
+
145
+1. [Prepare your system](#prepare-your-system)
146
+
147
+ Install the required packages on your system.
148
+
149
+2. [Install Netdata](#install-netdata)
150
+
151
+ Download and install Netdata. You can also update it the same way.
152
+
153
+---
154
+
155
+### Prepare your system
156
+
157
+Try our experimental automatic requirements installer (no need to be root). This will try to find the packages that should be installed on your system to build and run Netdata. It supports most major Linux distributions released after 2010:
158
+
159
+- **Alpine** Linux and its derivatives (you have to install `bash` yourself, before using the installer)
160
+- **Arch** Linux and its derivatives
161
+- **Gentoo** Linux and its derivatives
162
+- **Debian** Linux and its derivatives (including **Ubuntu**, **Mint**)
163
+- **Fedora** and its derivatives (including **Red Hat Enterprise Linux**, **CentOS**, **Amazon Machine Image**)
164
+- **SuSe** Linux and its derivatives (including **openSuSe**)
165
+- **SLE12** Must have your system registered with Suse Customer Center or have the DVD. See [#1162](https://github.com/netdata/netdata/issues/1162)
166
+
167
+Install the packages for having a **basic Netdata installation** (system monitoring and many applications, without `mysql` / `mariadb`, `postgres`, `named`, hardware sensors and `SNMP`):
168
+
169
+```sh
170
+curl -Ss 'https://raw.githubusercontent.com/netdata/netdata-demo-site/master/install-required-packages.sh' >/tmp/kickstart.sh && bash /tmp/kickstart.sh -i netdata
171
+```
172
+
173
+Install all the required packages for **monitoring everything Netdata can monitor**:
174
+
175
+```sh
176
+curl -Ss 'https://raw.githubusercontent.com/netdata/netdata-demo-site/master/install-required-packages.sh' >/tmp/kickstart.sh && bash /tmp/kickstart.sh -i netdata-all
177
+```
178
+
179
+If the above do not work for you, please [open a github issue](https://github.com/netdata/netdata/issues/new?title=packages%20installer%20failed&labels=installation%20help&body=The%20experimental%20packages%20installer%20failed.%0A%0AThis%20is%20what%20it%20says:%0A%0A%60%60%60txt%0A%0Aplease%20paste%20your%20screen%20here%0A%0A%60%60%60) with a copy of the message you get on screen. We are trying to make it work everywhere (this is also why the script [reports back](https://github.com/netdata/netdata/issues/2054) success or failure for all its runs).
180
+
181
+---
182
+
183
+This is how to do it by hand:
184
+
185
+```sh
186
+# Debian / Ubuntu
187
+apt-get install zlib1g-dev uuid-dev libmnl-dev gcc make git autoconf autoconf-archive autogen automake pkg-config curl
188
+
189
+# Fedora
190
+dnf install zlib-devel libuuid-devel libmnl-devel gcc make git autoconf autoconf-archive autogen automake pkgconfig curl findutils
191
+
192
+# CentOS / Red Hat Enterprise Linux
193
+yum install autoconf automake curl gcc git libmnl-devel libuuid-devel lm_sensors make MySQL-python nc pkgconfig python python-psycopg2 PyYAML zlib-devel
194
+
195
+```
196
+
197
+Please note that for RHEL/CentOS you might need [EPEL](http://www.tecmint.com/how-to-enable-epel-repository-for-rhel-centos-6-5/).
198
+
199
+Once Netdata is compiled, to run it the following packages are required (already installed using the above commands):
200
+
201
+package|description
202
+:-----:|-----------
203
+`libuuid`|part of `util-linux` for GUIDs management
204
+`zlib`|gzip compression for the internal Netdata web server
205
+
206
+*Netdata will fail to start without the above.*
207
+
208
+Netdata plugins and various aspects of Netdata can be enabled or benefit when these are installed (they are optional):
209
+
210
+package|description
211
+:-----:|-----------
212
+`bash`|for shell plugins and **alarm notifications**
213
+`curl`|for shell plugins and **alarm notifications**
214
+`iproute` or `iproute2`|for monitoring **Linux traffic QoS**<br/>use `iproute2` if `iproute` reports as not available or obsolete
215
+`python`|for most of the external plugins
216
+`python-yaml`|used for monitoring **beanstalkd**
217
+`python-beanstalkc`|used for monitoring **beanstalkd**
218
+`python-dnspython`|used for monitoring DNS query time
219
+`python-ipaddress`|used for monitoring **DHCPd**<br/>this package is required only if the system has python v2. python v3 has this functionality embedded
220
+`python-mysqldb`<br/>or<br/>`python-pymysql`|used for monitoring **mysql** or **mariadb** databases<br/>`python-mysqldb` is a lot faster and thus preferred
221
+`python-psycopg2`|used for monitoring **postgresql** databases
222
+`python-pymongo`|used for monitoring **mongodb** databases
223
+`nodejs`|used for `node.js` plugins for monitoring **named** and **SNMP** devices
224
+`lm-sensors`|for monitoring **hardware sensors**
225
+`libmnl`|for collecting netfilter metrics
226
+`netcat`|for shell plugins to collect metrics from remote systems
227
+
228
+*Netdata will greatly benefit if you have the above packages installed, but it will still work without them.*
229
+
230
+---
231
+
232
+### Install Netdata
233
+
234
+Do this to install and run Netdata:
235
+
236
+```sh
237
+
238
+# download it - the directory 'netdata' will be created
239
+git clone https://github.com/netdata/netdata.git --depth=1
240
+cd netdata
241
+
242
+# run script with root privileges to build, install, start Netdata
243
+./netdata-installer.sh
244
+
245
+```
246
+
247
+* If you don't want to run it straight-away, add `--dont-start-it` option.
248
+
249
+* If you don't want to install it on the default directories, you can run the installer like this: `./netdata-installer.sh --install /opt`. This one will install Netdata in `/opt/netdata`.
250
+
251
+Once the installer completes, the file `/etc/netdata/netdata.conf` will be created (if you changed the installation directory, the configuration will appear in that directory too).
252
+
253
+You can edit this file to set options. One common option to tweak is `history`, which controls the size of the memory database Netdata will use. By default is `3600` seconds (an hour of data at the charts) which makes Netdata use about 10-15MB of RAM (depending on the number of charts detected on your system). Check **[[Memory Requirements]]**.
254
+
255
+To apply the changes you made, you have to restart Netdata.
256
257
---
258
141
-## Install Netdata on Linux manually
142
-
143
-To install the latest git version of Netdata, please follow these 2 steps:
144
-
145
-1. [Prepare your system](#prepare-your-system)
146
-
147
- Install the required packages on your system.
148
-
149
-2. [Install Netdata](#install-netdata)
150
-
151
- Download and install Netdata. You can also update it the same way.
152
-
153
----
154
-
155
-### Prepare your system
156
-
157
-Try our experimental automatic requirements installer (no need to be root). This will try to find the packages that should be installed on your system to build and run Netdata. It supports most major Linux distributions released after 2010:
158
-
159
-- **Alpine** Linux and its derivatives (you have to install `bash` yourself, before using the installer)
160
-- **Arch** Linux and its derivatives
161
-- **Gentoo** Linux and its derivatives
162
-- **Debian** Linux and its derivatives (including **Ubuntu**, **Mint**)
163
-- **Fedora** and its derivatives (including **Red Hat Enterprise Linux**, **CentOS**, **Amazon Machine Image**)
164
-- **SuSe** Linux and its derivatives (including **openSuSe**)
165
-- **SLE12** Must have your system registered with Suse Customer Center or have the DVD. See [#1162](https://github.com/netdata/netdata/issues/1162)
166
-
167
-Install the packages for having a **basic Netdata installation** (system monitoring and many applications, without `mysql` / `mariadb`, `postgres`, `named`, hardware sensors and `SNMP`):
168
-
169
-```sh
170
-curl -Ss 'https://raw.githubusercontent.com/netdata/netdata-demo-site/master/install-required-packages.sh' >/tmp/kickstart.sh && bash /tmp/kickstart.sh -i netdata
171
-```
172
-
173
-Install all the required packages for **monitoring everything Netdata can monitor**:
174
-
175
-```sh
176
-curl -Ss 'https://raw.githubusercontent.com/netdata/netdata-demo-site/master/install-required-packages.sh' >/tmp/kickstart.sh && bash /tmp/kickstart.sh -i netdata-all
177
-```
178
-
179
-If the above do not work for you, please [open a github issue](https://github.com/netdata/netdata/issues/new?title=packages%20installer%20failed&labels=installation%20help&body=The%20experimental%20packages%20installer%20failed.%0A%0AThis%20is%20what%20it%20says:%0A%0A%60%60%60txt%0A%0Aplease%20paste%20your%20screen%20here%0A%0A%60%60%60) with a copy of the message you get on screen. We are trying to make it work everywhere (this is also why the script [reports back](https://github.com/netdata/netdata/issues/2054) success or failure for all its runs).
180
-
181
----
182
-
183
-This is how to do it by hand:
184
-
185
-```sh
186
-# Debian / Ubuntu
187
-apt-get install zlib1g-dev uuid-dev libmnl-dev gcc make git autoconf autoconf-archive autogen automake pkg-config curl
188
-
189
-# Fedora
190
-dnf install zlib-devel libuuid-devel libmnl-devel gcc make git autoconf autoconf-archive autogen automake pkgconfig curl findutils
191
-
192
-# CentOS / Red Hat Enterprise Linux
193
-yum install autoconf automake curl gcc git libmnl-devel libuuid-devel lm_sensors make MySQL-python nc pkgconfig python python-psycopg2 PyYAML zlib-devel
194
-
195
-```
196
-
197
-Please note that for RHEL/CentOS you might need [EPEL](http://www.tecmint.com/how-to-enable-epel-repository-for-rhel-centos-6-5/).
198
-
199
-Once Netdata is compiled, to run it the following packages are required (already installed using the above commands):
200
-
201
-package|description
202
-:-----:|-----------
203
-`libuuid`|part of `util-linux` for GUIDs management
204
-`zlib`|gzip compression for the internal Netdata web server
205
-
206
-*Netdata will fail to start without the above.*
207
-
208
-Netdata plugins and various aspects of Netdata can be enabled or benefit when these are installed (they are optional):
209
-
210
-package|description
211
-:-----:|-----------
212
-`bash`|for shell plugins and **alarm notifications**
213
-`curl`|for shell plugins and **alarm notifications**
214
-`iproute` or `iproute2`|for monitoring **Linux traffic QoS**<br/>use `iproute2` if `iproute` reports as not available or obsolete
215
-`python`|for most of the external plugins
216
-`python-yaml`|used for monitoring **beanstalkd**
217
-`python-beanstalkc`|used for monitoring **beanstalkd**
218
-`python-dnspython`|used for monitoring DNS query time
219
-`python-ipaddress`|used for monitoring **DHCPd**<br/>this package is required only if the system has python v2. python v3 has this functionality embedded
220
-`python-mysqldb`<br/>or<br/>`python-pymysql`|used for monitoring **mysql** or **mariadb** databases<br/>`python-mysqldb` is a lot faster and thus preferred
221
-`python-psycopg2`|used for monitoring **postgresql** databases
222
-`python-pymongo`|used for monitoring **mongodb** databases
223
-`nodejs`|used for `node.js` plugins for monitoring **named** and **SNMP** devices
224
-`lm-sensors`|for monitoring **hardware sensors**
225
-`libmnl`|for collecting netfilter metrics
226
-`netcat`|for shell plugins to collect metrics from remote systems
227
-
228
-*Netdata will greatly benefit if you have the above packages installed, but it will still work without them.*
229
-
230
----
231
-
232
-### Install Netdata
233
-
234
-Do this to install and run Netdata:
235
-
236
-```sh
237
-
238
-# download it - the directory 'netdata' will be created
239
-git clone https://github.com/netdata/netdata.git --depth=1
240
-cd netdata
241
-
242
-# run script with root privileges to build, install, start Netdata
243
-./netdata-installer.sh
244
-
245
-```
246
-
247
-* If you don't want to run it straight-away, add `--dont-start-it` option.
248
-
249
-* If you don't want to install it on the default directories, you can run the installer like this: `./netdata-installer.sh --install /opt`. This one will install Netdata in `/opt/netdata`.
250
-
251
-Once the installer completes, the file `/etc/netdata/netdata.conf` will be created (if you changed the installation directory, the configuration will appear in that directory too).
252
-
253
-You can edit this file to set options. One common option to tweak is `history`, which controls the size of the memory database Netdata will use. By default is `3600` seconds (an hour of data at the charts) which makes Netdata use about 10-15MB of RAM (depending on the number of charts detected on your system). Check **[[Memory Requirements]]**.
254
-
255
-To apply the changes you made, you have to restart Netdata.
256
-
257
----
258
-
259
-## Other Systems
260
-
261
-
262
-
263
-##### FreeBSD
264
-
265
-You can install Netdata from ports or packages collection.
266
-
267
-This is how to install the latest Netdata version from sources on FreeBSD:
268
-
269
-```sh
270
-# install required packages
271
-pkg install bash e2fsprogs-libuuid git curl autoconf automake pkgconf pidof
272
-
273
-# download Netdata
274
-git clone https://github.com/netdata/netdata.git --depth=1
275
-
276
-# install Netdata in /opt/netdata
277
-cd netdata
278
-./netdata-installer.sh --install /opt
279
-```
280
-
281
-##### pfSense
282
-To install Netdata on pfSense run the following commands (within a shell or under Diagnostics/Command Prompt within the pfSense web interface).
283
-
284
-Change platform (i386/amd64, etc) and FreeBSD versions (10/11, etc) according to your environment and change Netdata version (1.10.0 in example) according to latest version present within the FreeSBD repository:-
285
-
286
-Note first three packages are downloaded from the pfSense repository for maintaining compatibility with pfSense, Netdata is downloaded from the FreeBSD repository.
287
-```
288
-pkg install pkgconf
289
-pkg install bash
290
-pkg install e2fsprogs-libuuid
291
-pkg add http://pkg.freebsd.org/FreeBSD:11:amd64/latest/All/netdata-1.11.0.txz
292
-```
293
-To start Netdata manually run `service netdata onestart`
294
-
295
-To start Netdata automatically at each boot add `service netdata start` as a Shellcmd within the pfSense web interface (under **Services/Shellcmd**, which you need to install beforehand under **System/Package Manager/Available Packages**).
296
-Shellcmd Type should be set to `Shellcmd`.
297
-
298
-Alternatively more information can be found in https://doc.pfsense.org/index.php/Installing_FreeBSD_Packages, for achieving the same via the command line and scripts.
299
-
300
-If you experience an issue with `/usr/bin/install` absense on pfSense 2.3 or earlier, update pfSense or use workaround from [https://redmine.pfsense.org/issues/6643](https://redmine.pfsense.org/issues/6643)
301
-
302
-##### FreeNAS
303
-On FreeNAS-Corral-RELEASE (>=10.0.3), Netdata is pre-installed.
304
-
305
-To use Netdata, the service will need to be enabled and started from the FreeNAS **[CLI](https://github.com/freenas/cli)**.
306
-
307
-To enable the Netdata service:
308
-```
309
-service netdata config set enable=true
310
-```
311
-
312
-To start the netdata service:
313
-```
314
-service netdata start
315
-```
316
-
317
-##### macOS
318
-
319
-Netdata on macOS still has limited charts, but external plugins do work.
320
-
321
-You can either install Netdata with [Homebrew](https://brew.sh/)
322
-
323
-```sh
324
-brew install netdata
325
-```
326
-
327
-or from source:
328
-
329
-```sh
330
-# install Xcode Command Line Tools
331
-xcode-select --install
332
-```
333
-click `Install` in the software update popup window, then
334
-```sh
335
-# install HomeBrew package manager
336
-/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
337
-
338
-# install required packages
339
-brew install ossp-uuid autoconf automake pkg-config
340
-
341
-# download Netdata
342
-git clone https://github.com/netdata/netdata.git --depth=1
343
-
344
-# install Netdata in /usr/local/netdata
345
-cd netdata
346
-sudo ./netdata-installer.sh --install /usr/local
347
-```
348
-
349
-The installer will also install a startup plist to start Netdata when your Mac boots.
350
-
351
-##### Alpine 3.x
352
-
353
-Execute these commands to install Netdata in Alpine Linux 3.x:
354
-
355
-```
356
-# install required packages
357
-apk add alpine-sdk bash curl zlib-dev util-linux-dev libmnl-dev gcc make git autoconf automake pkgconfig python logrotate
358
-
359
-# if you plan to run node.js Netdata plugins
360
-apk add nodejs
361
-
362
-# download Netdata - the directory 'netdata' will be created
363
-git clone https://github.com/netdata/netdata.git --depth=1
364
-cd netdata
365
-
366
-
367
-# build it, install it, start it
368
-./netdata-installer.sh
369
-
370
-
371
-# make Netdata start at boot
372
-echo -e "#!/usr/bin/env bash\n/usr/sbin/netdata" >/etc/local.d/netdata.start
373
-chmod 755 /etc/local.d/netdata.start
374
-
375
-# make Netdata stop at shutdown
376
-echo -e "#!/usr/bin/env bash\nkillall netdata" >/etc/local.d/netdata.stop
377
-chmod 755 /etc/local.d/netdata.stop
378
-
379
-# enable the local service to start automatically
380
-rc-update add local
381
-```
382
-
383
-##### Synology
384
-
385
-The documentation previously recommended installing the Debian Chroot package from the Synology community package sources and then running Netdata from within the chroot. This does not work, as the chroot environment does not have access to `/proc`, and therefore exposes very few metrics to Netdata. Additionally, [this issue](https://github.com/SynoCommunity/spksrc/issues/2758), still open as of 2018/06/24, indicates that the Debian Chroot package is not suitable for DSM versions greater than version 5 and may corrupt system libraries and render the NAS unable to boot.
386
-
387
-The good news is that the 64-bit static installer works fine if your NAS is one that uses the amd64 architecture. It will install the content into `/opt/netdata`, making future removal safe and simple.
388
-
389
-When Netdata is first installed, it will run as _root_. This may or may not be acceptable for you, and since other installations run it as the _netdata_ user, you might wish to do the same. This requires some extra work:
390
-
391
-1. Creat a group `netdata` via the Synology group interface. Give it no access to anything.
392
-2. Create a user `netdata` via the Synology user interface. Give it no access to anything and a random password. Assign the user to the `netdata` group. Netdata will chuid to this user when running.
393
-3. Change ownership of the following directories, as defined in [Netdata Security](../docs/netdata-security.md#security-design):
394
-
395
-```
396
-$ chown -R root:netdata /opt/netdata/usr/share/netdata
397
-$ chown -R netdata:netdata /opt/netdata/var/lib/netdata /opt/netdata/var/cache/netdata
398
-$ chown -R netdata:root /opt/netdata/var/log/netdata
399
-```
400
-
401
-Additionally, as of 2018/06/24, the Netdata installer doesn't recognize DSM as an operating system, so no init script is installed. You'll have to do this manually:
402
-
403
-1. Add [this file](https://gist.github.com/oskapt/055d474d7bfef32c49469c1b53e8225f) as `/etc/rc.netdata`. Make it executable with `chmod 0755 /etc/rc.netdata`.
404
-2. Edit `/etc/rc.local` and add a line calling `/etc/rc.netdata` to have it start on boot:
405
-
406
-```
407
-# Netdata startup
408
-[ -x /etc/rc.netdata ] && /etc/rc.netdata start
259
+## Other Systems
260
+
261
+
262
+
263
+##### FreeBSD
264
+
265
+You can install Netdata from ports or packages collection.
266
+
267
+This is how to install the latest Netdata version from sources on FreeBSD:
268
+
269
+```sh
270
+# install required packages
271
+pkg install bash e2fsprogs-libuuid git curl autoconf automake pkgconf pidof
272
+
273
+# download Netdata
274
+git clone https://github.com/netdata/netdata.git --depth=1
275
+
276
+# install Netdata in /opt/netdata
277
+cd netdata
278
+./netdata-installer.sh --install /opt
279
+```
280
+
281
+##### pfSense
282
+To install Netdata on pfSense run the following commands (within a shell or under Diagnostics/Command Prompt within the pfSense web interface).
283
+
284
+Change platform (i386/amd64, etc) and FreeBSD versions (10/11, etc) according to your environment and change Netdata version (1.10.0 in example) according to latest version present within the FreeSBD repository:-
285
+
286
+Note first three packages are downloaded from the pfSense repository for maintaining compatibility with pfSense, Netdata is downloaded from the FreeBSD repository.
287
+```
288
+pkg install pkgconf
289
+pkg install bash
290
+pkg install e2fsprogs-libuuid
291
+pkg add http://pkg.freebsd.org/FreeBSD:11:amd64/latest/All/netdata-1.11.0.txz
292
+```
293
+To start Netdata manually run `service netdata onestart`
294
+
295
+To start Netdata automatically at each boot add `service netdata start` as a Shellcmd within the pfSense web interface (under **Services/Shellcmd**, which you need to install beforehand under **System/Package Manager/Available Packages**).
296
+Shellcmd Type should be set to `Shellcmd`.
297
+
298
+Alternatively more information can be found in https://doc.pfsense.org/index.php/Installing_FreeBSD_Packages, for achieving the same via the command line and scripts.
299
+
300
+If you experience an issue with `/usr/bin/install` absense on pfSense 2.3 or earlier, update pfSense or use workaround from [https://redmine.pfsense.org/issues/6643](https://redmine.pfsense.org/issues/6643)
301
+
302
+##### FreeNAS
303
+On FreeNAS-Corral-RELEASE (>=10.0.3), Netdata is pre-installed.
304
+
305
+To use Netdata, the service will need to be enabled and started from the FreeNAS **[CLI](https://github.com/freenas/cli)**.
306
+
307
+To enable the Netdata service:
308
+```
309
+service netdata config set enable=true
310
+```
311
+
312
+To start the netdata service:
313
+```
314
+service netdata start
315
+```
316
+
317
+##### macOS
318
+
319
+Netdata on macOS still has limited charts, but external plugins do work.
320
+
321
+You can either install Netdata with [Homebrew](https://brew.sh/)
322
+
323
+```sh
324
+brew install netdata
325
+```
326
+
327
+or from source:
328
+
329
+```sh
330
+# install Xcode Command Line Tools
331
+xcode-select --install
332
+```
333
+click `Install` in the software update popup window, then
334
+```sh
335
+# install HomeBrew package manager
336
+/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
337
+
338
+# install required packages
339
+brew install ossp-uuid autoconf automake pkg-config
340
+
341
+# download Netdata
342
+git clone https://github.com/netdata/netdata.git --depth=1
343
+
344
+# install Netdata in /usr/local/netdata
345
+cd netdata
346
+sudo ./netdata-installer.sh --install /usr/local
347
+```
348
+
349
+The installer will also install a startup plist to start Netdata when your Mac boots.
350
+
351
+##### Alpine 3.x
352
+
353
+Execute these commands to install Netdata in Alpine Linux 3.x:
354
+
355
+```
356
+# install required packages
357
+apk add alpine-sdk bash curl zlib-dev util-linux-dev libmnl-dev gcc make git autoconf automake pkgconfig python logrotate
358
+
359
+# if you plan to run node.js Netdata plugins
360
+apk add nodejs
361
+
362
+# download Netdata - the directory 'netdata' will be created
363
+git clone https://github.com/netdata/netdata.git --depth=1
364
+cd netdata
365
+
366
+
367
+# build it, install it, start it
368
+./netdata-installer.sh
369
+
370
+
371
+# make Netdata start at boot
372
+echo -e "#!/usr/bin/env bash\n/usr/sbin/netdata" >/etc/local.d/netdata.start
373
+chmod 755 /etc/local.d/netdata.start
374
+
375
+# make Netdata stop at shutdown
376
+echo -e "#!/usr/bin/env bash\nkillall netdata" >/etc/local.d/netdata.stop
377
+chmod 755 /etc/local.d/netdata.stop
378
+
379
+# enable the local service to start automatically
380
+rc-update add local
381
+```
382
+
383
+##### Synology
384
+
385
+The documentation previously recommended installing the Debian Chroot package from the Synology community package sources and then running Netdata from within the chroot. This does not work, as the chroot environment does not have access to `/proc`, and therefore exposes very few metrics to Netdata. Additionally, [this issue](https://github.com/SynoCommunity/spksrc/issues/2758), still open as of 2018/06/24, indicates that the Debian Chroot package is not suitable for DSM versions greater than version 5 and may corrupt system libraries and render the NAS unable to boot.
386
+
387
+The good news is that the 64-bit static installer works fine if your NAS is one that uses the amd64 architecture. It will install the content into `/opt/netdata`, making future removal safe and simple.
388
+
389
+When Netdata is first installed, it will run as _root_. This may or may not be acceptable for you, and since other installations run it as the _netdata_ user, you might wish to do the same. This requires some extra work:
390
+
391
+1. Creat a group `netdata` via the Synology group interface. Give it no access to anything.
392
+2. Create a user `netdata` via the Synology user interface. Give it no access to anything and a random password. Assign the user to the `netdata` group. Netdata will chuid to this user when running.
393
+3. Change ownership of the following directories, as defined in [Netdata Security](../../docs/netdata-security.md#security-design):
394
+
395
+```
396
+$ chown -R root:netdata /opt/netdata/usr/share/netdata
397
+$ chown -R netdata:netdata /opt/netdata/var/lib/netdata /opt/netdata/var/cache/netdata
398
+$ chown -R netdata:root /opt/netdata/var/log/netdata
399
+```
400
+
401
+Additionally, as of 2018/06/24, the Netdata installer doesn't recognize DSM as an operating system, so no init script is installed. You'll have to do this manually:
402
+
403
+1. Add [this file](https://gist.github.com/oskapt/055d474d7bfef32c49469c1b53e8225f) as `/etc/rc.netdata`. Make it executable with `chmod 0755 /etc/rc.netdata`.
404
+2. Edit `/etc/rc.local` and add a line calling `/etc/rc.netdata` to have it start on boot:
405
+
406
+```
407
+# Netdata startup
408
+[ -x /etc/rc.netdata ] && /etc/rc.netdata start
409
```
410
411
[]()
packaging/installer/UNINSTALL.md
renamed
packaging/installer/UPDATE.md
renamed
+2
-2
@@ -11,7 +11,7 @@ The update procedure depends on how you installed it:
11
12
### Manual update
13
14
-The installer `netdata-installer.sh` generates a `netdata-updater.sh` script in the directory you downloaded netdata.
14
+The installer `netdata-installer.sh` generates a `netdata-updater.sh` script in the directory you downloaded netdata.
15
You can use this script to update your netdata installation with the same options you used to install it in the first place.
16
Just run it and it will download and install the latest version of netdata. The same script can be put in a cronjob to update your netdata at regular intervals.
17
@@ -46,7 +46,7 @@ Keep in mind, netdata may now have new features, or certain old features may now
46
47
_Please, consider the risks of running an auto-update. Something can always go wrong. Keep an eye on your installation, and run a manual update if something ever fails._
48
49
-You can call `netdata-updater.sh` from a cron-job. A successful update will not trigger an email from cron.
49
+You can call `netdata-updater.sh` from a cron-job. A successful update will not trigger an email from cron.
50
51
```sh
52
# Edit your cron-jobs
packaging/installer/functions.sh
renamed
packaging/installer/netdata-uninstaller.sh
renamed
+2
-2
@@ -47,9 +47,9 @@ if [ "$YES" != "1" ]; then
47
fi
48
49
#shellcheck source=/dev/null
50
-source installer/.environment.sh || exit 1
50
+source packaging/installer/.environment.sh || exit 1
51
#shellcheck source=/dev/null
52
-source installer/functions.sh || exit 1
52
+source packaging/installer/functions.sh || exit 1
53
54
echo >&2 "Stopping a possibly running netdata..."
55
for p in $(stop_all_netdata netdata); do run kill "$p"; done
packaging/installer/netdata-updater.sh
renamed
+2
-2
@@ -17,7 +17,7 @@ REINSTALL_PWD="THIS_SHOULD_BE_REPLACED_BY_INSTALLER_SCRIPT"
17
cd "${REINSTALL_PWD}" || exit 1
18
19
#shellcheck source=/dev/null
20
-source installer/.environment.sh || exit 1
20
+source packaging/installer/.environment.sh || exit 1
21
22
if [ "${INSTALL_UID}" != "$(id -u)" ]
23
then
@@ -94,7 +94,7 @@ update() {
94
fi
95
96
popmsg="$(git stash pop 2>&1)"
97
- if [ $? -eq 0 ] ; then
97
+ if [ $? -eq 0 ] ; then
98
info "Stashing local git changes. You can use ${popmsg} to reapply your changes."
99
fi
100
tests/lifecycle.sh
+3
-3
@@ -29,6 +29,6 @@ git status
29
echo "========= UPDATE ========="
30
./netdata-updater.sh
31
32
-echo "========= UNINSTALL ========="
33
-mv /tmp/netdata-uninstaller.sh ./netdata-uninstaller.sh
34
-./netdata-uninstaller.sh --yes --force
32
+#echo "========= UNINSTALL ========="
33
+#mv /tmp/netdata-uninstaller.sh ./netdata-uninstaller.sh
34
+#./netdata-uninstaller.sh --yes --force