Upgrade Sensu
Upgrade to Sensu Go 6.0 from a 5.x deployment
IMPORTANT: Before you upgrade to Sensu 6.0, use sensuctl dump
to create a backup of your existing installation.
You will not be able to downgrade to a Sensu 5.x version after you upgrade your database to Sensu 6.0 in step 3 of this process.
To upgrade your Sensu Go 5.x deployment to 6.0:
-
Install the 6.0 packages or Docker image.
-
Restart the services.
NOTE: For systems that use
systemd
, runsudo systemctl daemon-reload
before restarting the services.# Restart the Sensu agent sudo service sensu-agent restart # Restart the Sensu backend sudo service sensu-backend restart
-
Run a single upgrade command on one your Sensu backends to migrate the cluster:
sensu-backend upgrade
- Add the
--skip-confirm
flag to skip the confirmation in step 4 and immediately run the upgrade command.
sensu-backend upgrade --skip-confirm
NOTE: If you are deploying a new Sensu 6.0 cluster rather than upgrading from 5.x, you do not need to run the
sensu-backend upgrade
command. - Add the
-
Enter
y
orn
to confirm if you did not add the--skip-confirm
flag. Otherwise, skip this step. -
Wait a few seconds for the upgrade command to run.
You may notice some inconsistencies in your entity list until the cluster finishes upgrading. Despite this, your cluster will continue to publish standard check requests and process events.
If you run the upgrade command more than once, it will not harm the cluster — you’ll just see a response that the upgrade command has already been run.
Upgrade to the latest 5.x version of Sensu Go from 5.0.0 or later
To upgrade to the latest version of Sensu Go from version 5.0.0 or later, install the latest packages.
Then, restart the services.
NOTE: For systems that use systemd
, run sudo systemctl daemon-reload
before restarting the services.
# Restart the Sensu agent
sudo service sensu-agent restart
# Restart the Sensu backend
sudo service sensu-backend restart
Use the version
command to determine the installed version using the sensu-agent
, sensu-backend
, and sensuctl
tools.
For example, sensu-backend version
.
Upgrade to Sensu Go 5.16.0 from any earlier version
As of Sensu Go 5.16.0, Sensu’s free entity limit is 100 entities. All commercial features are available for free in the packaged Sensu Go distribution up to an entity limit of 100.
When you upgrade to 5.16.0, if your existing unlicensed instance has more than 100 entities, Sensu will continue to monitor those entities. However, if you try to create any new entities via the HTTP API or sensuctl, you will see the following message:
This functionality requires a valid Sensu Go license with a sufficient entity limit. To get a valid license file, arrange a trial, or increase your entity limit, contact Sales.
Connections from new agents will fail and result in a log message like this:
{"component":"agent","error":"handshake failed with status 402","level":"error","msg":"reconnection attempt failed","time":"2019-11-20T05:49:24-07:00"}
In the web UI, you will see the following message when you reach the 100-entity limit:
If your Sensu instance includes more than 100 entities, contact Sales to learn how to upgrade your installation and increase your limit. See our blog announcement for more information about our usage policy.
Upgrade Sensu clusters from 5.7.0 or earlier to 5.8.0 or later
NOTE: This section applies only to Sensu clusters with multiple backend nodes.
Due to updates to etcd serialization, you must shut down Sensu clusters with multiple backend nodes while upgrading from Sensu Go 5.7.0 or earlier to 5.8.0 or later. See the backend reference for more information about stopping and starting backends.
Upgrade Sensu backend binaries to 5.1.0
NOTE: This section applies only to Sensu backend binaries downloaded from s3-us-west-2.amazonaws.com/sensu.io/sensu-go
, not to Sensu RPM or DEB packages.
For Sensu backend binaries, the default state-dir
in 5.1.0 is now /var/lib/sensu/sensu-backend
instead of /var/lib/sensu
.
To upgrade your Sensu backend binary to 5.1.0, first download the latest version.
Then, make sure the /etc/sensu/backend.yml
configuration file specifies a state-dir
.
To continue using /var/lib/sensu
as the state-dir
, add the following configuration to /etc/sensu/backend.yml
.
# /etc/sensu/backend.yml configuration to store backend data at /var/lib/sensu
state-dir: "/var/lib/sensu"
Then restart the backend.