summaryrefslogtreecommitdiffstats
path: root/netdata-installer.sh
diff options
context:
space:
mode:
authorBernard Tyers <ei8fdb@users.noreply.github.com>2018-11-29 20:53:31 +0000
committerPaweł Krupa <pawel@krupa.net.pl>2018-11-29 22:53:31 +0200
commit5a6db4bca6b601697d60053087b151016f054aaa (patch)
tree1df35e9fa25bc738caa1bb434db484c75b94ec76 /netdata-installer.sh
parent9d5ec14343ea7ccf3834399f678c555cac300c54 (diff)
Small content change to the netdata-installer.sh (#4790)
* I'm suggesting a small content change to the instructions for users when running netdata-updater.sh. I've already seen in GH issues where people have asked for help. This content would make it clear what user the script needs to run as. * Small content change to the netdata-installer.sh
Diffstat (limited to 'netdata-installer.sh')
-rwxr-xr-xnetdata-installer.sh26
1 files changed, 13 insertions, 13 deletions
diff --git a/netdata-installer.sh b/netdata-installer.sh
index dfeb563968..896ccbdb35 100755
--- a/netdata-installer.sh
+++ b/netdata-installer.sh
@@ -273,39 +273,39 @@ if [ "${UID}" -ne 0 ]
then
netdata_banner "wrong command line options!"
cat <<NONROOTNOPREFIX
-
+
${TPUT_RED}${TPUT_BOLD}Sorry! This will fail!${TPUT_RESET}
-
+
You are attempting to install netdata as non-root, but you plan
to install it in system paths.
-
+
Please set an installation prefix, like this:
-
+
$0 ${@} --install /tmp
-
+
or, run the installer as root:
-
+
sudo $0 ${@}
-
+
We suggest to install it as root, or certain data collectors will
not be able to work. Netdata drops root privileges when running.
So, if you plan to keep it, install it as root to get the full
functionality.
-
+
NONROOTNOPREFIX
exit 1
else
cat <<NONROOT
-
+
${TPUT_RED}${TPUT_BOLD}IMPORTANT${TPUT_RESET}:
You are about to install netdata as a non-root user.
Netdata will work, but a few data collection modules that
require root access will fail.
-
+
If you installing netdata permanently on your system, run
the installer like this:
-
+
${TPUT_YELLOW}${TPUT_BOLD}sudo $0 ${@}${TPUT_RESET}
NONROOT
@@ -1121,7 +1121,7 @@ export NETDATA_CONFIGURE_OPTIONS="${NETDATA_CONFIGURE_OPTIONS}"
INSTALL_UID="${UID}"
if [ "\${INSTALL_UID}" != "\${UID}" ]
then
- echo >&2 "This script should be run as user with uid \${INSTALL_UID} but it now runs with uid \${UID}"
+echo >&2 "You are running this script as user with uid \${UID}. We recommend to run this script as root (user with uid 0)"
exit 1
fi
@@ -1283,5 +1283,5 @@ else
fi
echo >&2 " enjoy real-time performance and health monitoring..."
-echo >&2
+echo >&2
exit 0