diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-04-14 18:12:10 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-04-14 18:12:10 +0000 |
commit | b5321aff06d6ea8d730d62aec2ffd8e9271c1ffc (patch) | |
tree | 36c41e35994786456154f9d3bf88c324763aeea4 /packaging/installer/UPDATE.md | |
parent | Adding upstream version 1.33.1. (diff) | |
download | netdata-b5321aff06d6ea8d730d62aec2ffd8e9271c1ffc.tar.xz netdata-b5321aff06d6ea8d730d62aec2ffd8e9271c1ffc.zip |
Adding upstream version 1.34.0.upstream/1.34.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | packaging/installer/UPDATE.md | 104 |
1 files changed, 79 insertions, 25 deletions
diff --git a/packaging/installer/UPDATE.md b/packaging/installer/UPDATE.md index 8230d00cd..009e970f2 100644 --- a/packaging/installer/UPDATE.md +++ b/packaging/installer/UPDATE.md @@ -6,8 +6,9 @@ custom_edit_url: https://github.com/netdata/netdata/edit/master/packaging/instal # Update the Netdata Agent -By default, the Netdata Agent automatically updates with the latest nightly version. If you opted out of automatic -updates, you need to update your Netdata Agent to the latest nightly or stable version. +By default, the Netdata Agent automatically updates with the latest nightly or stable version depending on which +you installed. If you opted out of automatic updates, you need to update your Netdata Agent to the latest nightly +or stable version. You can also [enable or disable automatic updates on an existing install](#control-automatic-updates). > 💡 Looking to reinstall the Netdata Agent to enable a feature, update an Agent that cannot update automatically, or > troubleshoot an error during the installation process? See our [reinstallation doc](/packaging/installer/REINSTALL.md) @@ -16,32 +17,43 @@ updates, you need to update your Netdata Agent to the latest nightly or stable v Before you update the Netdata Agent, check to see if your Netdata Agent is already up-to-date by clicking on the update icon in the local Agent dashboard's top navigation. This modal informs you whether your Agent needs an update or not. -![Opening the Agent's Update modal](https://user-images.githubusercontent.com/1153921/99738428-add06780-2a87-11eb-8268-0e17b689eb3f.gif) +The exact update method to use depends on the install type: + +- Installs with an install type of 'custom' usually indicate installing a third-party package through the system + package manager. To update these installs, you should update the package just like you would any other package + on your system. +- Installs with an install type starting with `binpkg` or ending with `build` or `static` can be updated using + our [regular update method](#updates-for-most-systems). +- Installs with an install type of 'oci' were created from our official Docker images, and should be updated + using our [Docker](#docker) update procedure. +- macOS users should check [our update instructions for macOS](#macos). +- Manually built installs should check [our update instructions for manual builds](#manual-installation-from-git). ## Determine which installation method you used -If you are not sure where your Netdata config directory is, see the [configuration doc](/docs/configure/nodes.md). In -most installations, this is `/etc/netdata`. +Starting with netdata v1.33.0, you can use Netdata itself to determine the installation type by running: + +```bash +netdata -W buildinfo | grep 'Install type:' +``` + +If you are using an older version of Netdata, or the above command produces no output, you can run our one-line +installation script in dry-run mode to attempt to determine what method to use to update by running the following +command: -Use `cd` to navigate to the Netdata config directory, then use `ls -a` to look for a file called `.install-type`. +```bash +wget -O /tmp/netdata-kickstart.sh https://my-netdata.io/kickstart.sh && sh /tmp/netdata-kickstart.sh --dry-run +``` -- If the `.install-type` file doex not exist, look for a file in the same directory called `.environment`. - - If the `.environment` file does not exist, you probably installed Netdata using your system package manager - and should update it the same way you would run updates on the system itself. - - If the `.environment` file does exist, then our [regular update method](#updates-for-most-systems) should - work correctly. -- If the `.install-type` file does exist, check it’s contents with `cat .install-type`. - - If the `INSTALL_TYPE` key has a value of `custom`, you probably installed Netdata using your system - package manager and should update it the same way you would run updates on the system itself. - - If the `INSTALL_TYPE` key has a value of `oci`, the install is from a Docker image. - - Otherwise, the install should work with our [regular update method](#updates-for-most-systems). +Note that if you installed Netdata using an installation prefix, you will need to add an `--install` option +specifying that prefix to make sure it finds the existing install. -Next, use the appropriate method to update the Netdata Agent: +If you see a line starting with `--- Would attempt to update existing installation by running the updater script +located at:`, then our [regular update method](#updates-for-most-systems) will work for you. -- [Updates for most systems](#updates-for-most-systems) -- [Docker](#docker) -- [macOS](#macos) -- [Manual installation from Git](#manual-installation-from-git) +Otherwise, it should either indicate that the installation type is not supported (which probably means you either +have a `custom` instal or built Netdata manually) or indicate that it would create a new install (which means that +you either used a non-standard install path, or that you don’t actually have Netdata installed). ## Updates for most systems @@ -56,9 +68,21 @@ that prefix to this command to make sure it finds Netdata. wget -O /tmp/netdata-kickstart.sh https://my-netdata.io/kickstart.sh && sh /tmp/netdata-kickstart.sh ``` -> ❗ If the above command fails, you can [reinstall -> Netdata](/packaging/installer/REINSTALL.md#one-line-installer-script-kickstartsh) to get the latest version. This also -> preserves your [configuration](/docs/configure/nodes.md) in `netdata.conf` or other files. +### Issues with older binpkg installs + +The above command is known not to work with binpkg type installs for stable releases with a version number of +v1.33.1 or earlier, and nightly builds with a version number of v1.33.1-93 or earlier. If you have such a system, +the above command will report that it found an existing install, and then issue a warning about not being able to +find the updater script. + +On such installs, you can update Netdata using your distribution package manager. + +### If the kickstart script does not work + +If the above command fails, you can [reinstall +Netdata](/packaging/installer/REINSTALL.md#one-line-installer-script-kickstartsh) to get the latest version. This +also preserves your [configuration](/docs/configure/nodes.md) in `netdata.conf` or other files just like updating +normally would, though you will need to specify any installation options you used originally again. ## Docker @@ -95,6 +119,9 @@ Homebrew downloads the latest Netdata via the [formulae](https://github.com/Homebrew/homebrew-core/blob/master/Formula/netdata.rb), ensures all dependencies are met, and updates Netdata via reinstallation. +If you instead installed Netdata using our one-line installation script, you can use our [regular update +instructions](#updates-for-most-systems) to update Netdata. + ## Manual installation from Git If you installed [Netdata manually from Git](/packaging/installer/methods/manual.md), you can run that installer again @@ -117,4 +144,31 @@ sudo ./netdata-installer.sh > ⚠️ If you installed Netdata with any optional parameters, such as `--no-updates` to disable automatic updates, and > want to retain those settings, you need to set them again during this process. -[![analytics](https://www.google-analytics.com/collect?v=1&aip=1&t=pageview&_s=1&ds=github&dr=https%3A%2F%2Fgithub.com%2Fnetdata%2Fnetdata&dl=https%3A%2F%2Fmy-netdata.io%2Fgithub%2Finstaller%2FUPDATE&_u=MAC~&cid=5792dfd7-8dc4-476b-af31-da2fdb9f93d2&tid=UA-64295674-3)](<>) +## Control automatic updates + +Starting with Netdata v1.34.0, you can easily enable or disable automatic updates on an existing installation +using the updater script. + +For most installs on Linux, you can enable auto-updates with: + +```bash +/usr/libexec/netdata/netdata-updater.sh --enable-auto-updates +``` + +and disable them with: + +```bash +/usr/libexec/netdata/netdata-updater.sh --disable-auto-updates +``` + +For static installs, instead use: + +```bash +/opt/netdata/usr/libexec/netdata/netdata-updater.sh --enable-auto-updates +``` + +and: + +```bash +/opt/netdata/usr/libexec/netdata/netdata-updater.sh --disable-auto-updates +``` |