欧洲杯投注软件We recommend that you upgrade Grafana often to stay up to date with the latest fixes and enhancements. In order make this a reality, Grafana upgrades are backward compatible and the upgrade process is simple and quick.
Upgrading is generally safe (between many minor and one major version) and dashboards and graphs will look the same. There may be minor breaking changes in some edge cases, which are outlined in the Release Notes and
欧洲杯投注软件After you have upgraded it is highly recommended that you update all your plugins as a new version of Grafana can make older plugins stop working properly.
欧洲杯投注软件You can update all plugins using
grafana-cli plugins update-all
欧洲杯投注软件Before upgrading it can be a good idea to backup your Grafana database. This will ensure that you can always rollback to your previous version. During startup, Grafana will automatically migrate the database schema (if there are changes or new tables). Sometimes this can cause issues if you later want to downgrade.
If you use sqlite you only need to make a backup of your
grafana.db file. This is usually located at
/var/lib/grafana/grafana.db on Unix systems.
If you are unsure what database you use and where it is stored check you grafana configuration file. If you
installed grafana to custom location using a binary tar/zip it is usually in
backup: > mysqldump -u root -p[root_password] [grafana] > grafana_backup.sql restore: > mysql -u root -p grafana < grafana_backup.sql
backup: > pg_dump grafana > grafana_backup restore: > psql grafana < grafana_backup
Ubuntu or Debian
欧洲杯投注软件You can upgrade Grafana by following the same procedure as when you installed it.
Upgrade Debian package
If you installed Grafana by downloading a Debian package (
.deb), then you can execute the same
dpkg -i command but with the new package. It will upgrade your Grafana installation.
Go to the download page for the latest download links.
wget <debian package url> sudo apt-get install -y adduser libfontconfig1 sudo dpkg -i grafana_<version>_amd64.deb
Upgrade from APT repository
If you installed Grafana from our APT repository, then Grafana will automatically update when you run apt-get upgrade to upgrade all system packages.
sudo apt-get update
Upgrade from binary .tar file
If you downloaded the binary
.tar.gz package, then you can just download and extract the new package and overwrite all your existing files. However, this might overwrite your config changes.
We recommend that you save your custom config changes in a file named
This allows you to upgrade Grafana without risking losing your configuration changes.
Centos / RHEL
If you installed Grafana by downloading an RPM package you can just follow the same installation guide and execute the same
yum install or
rpm -i command but with the new package. It will upgrade your Grafana installation.
If you used our YUM repository:
sudo yum update grafana
欧洲杯投注软件This just an example, details depend on how you configured your grafana container.
docker pull grafana/grafana docker stop my-grafana-container docker rm my-grafana-container docker run -d --name=my-grafana-container --restart=always -v /var/lib/grafana:/var/lib/grafana grafana/grafana
If you downloaded the Windows binary package you can just download a newer package and extract to the same location (and overwrite the existing files). This might overwrite your config changes. We recommend that you save your config changes in a file named
<grafana_install_dir>/conf/custom.ini as this will make upgrades easier without risking losing your config changes.
Upgrading from 1.x
Upgrading from 2.x
We are not aware of any issues upgrading directly from 2.x to 4.x but to be on the safe side go via 3.x => 4.x.
Upgrading to v5.0
The dashboard grid layout engine has changed. All dashboards will be automatically upgraded to new positioning system when you load them in v5. Dashboards saved in v5 will not work in older versions of Grafana. Some external panel plugins might need to be updated to work properly.
For more details on the new panel positioning system, click here
Upgrading to v5.2
欧洲杯投注软件One of the database migrations included in this release will update all annotation timestamps from second to millisecond precision. If you have a large amount of annotations the database migration may take a long time to complete which may cause problems if you use systemd to run Grafana.
We’ve got one report where using systemd, PostgreSQL and a large amount of annotations (table size 1645mb) took 8-20 minutes for the database migration to complete. However, the grafana-server process was killed after 90 seconds by systemd. Any database migration queries in progress when systemd kills the grafana-server process continues to execute in database until finished.
If you’re using systemd and have a large amount of annotations consider temporary adjusting the systemd
TimeoutStartSec setting to something high like
30m before upgrading.
Upgrading to v6.0
If you have text panels with script tags they will no longer work due to a new setting that per default disallow unsanitized HTML. Read more here about this new setting.
Authentication and security
If your using Grafana’s builtin, LDAP (without Auth Proxy) or OAuth authentication all users will be required to login upon the next visit after the upgrade.
If you have
cookie_secure set to
true in the
session section you probably want to change the
true in the
security section as well. Ending up with a configuration like this:
[session] cookie_secure = true [security] cookie_secure = true
cookie_remember_name settings in the
security section are no longer being used so they’re safe to remove.
If you have
login_remember_days欧洲杯投注软件 configured to 0 (zero) you should change your configuration to this to accomplish similar behavior, i.e. a logged in user will maximum be logged in for 1 day until being forced to login again:
[auth] login_maximum_inactive_lifetime_days = 1 login_maximum_lifetime_days = 1
The default cookie name for storing the auth token is
grafana_session. you can configure this with
Upgrading to v6.2
Ensure encryption of data source secrets
Data sources store passwords and basic auth passwords in secureJsonData encrypted (AES-256 in CFB mode) by default. Existing data source will keep working with unencrypted passwords. If you want to migrate to encrypted storage for your existing data sources you can do that by:
- For data sources created through UI, you need to go to data source config, re enter the password or basic auth password and save the data source.
- For data sources created by provisioning, you need to update your config file and use secureJsonData.password or secureJsonData.basicAuthPassword field. See provisioning docs for example of current configuration.
If you’re embedding Grafana in a
<object> on a different website it will no longer work due to a new setting
that per default instructs the browser to not allow Grafana to be embedded. Read more here欧洲杯投注软件 about
this new setting.
Session storage is no longer used
In 6.2 we completely removed the backend session storage since we replaced the previous login session implementation with an auth token. If you are using Auth proxy with LDAP an shared cached is used in Grafana so you might want configure [remote_cache] instead. If not Grafana will fallback to using the database as an shared cache.
Upgrading Elasticsearch to v7.0+
The semantics of
max concurrent shard requests changed in Elasticsearch v7.0, see for reference.
If you upgrade Elasticsearch to v7.0+ you should make sure to update the data source configuration in Grafana so that version
max concurrent shard requests properly configured. 256 was the default in pre v7.0 versions. In v7.0 and above 5 is the default.
Upgrading to v6.4
Annotations database migration
One of the database migrations included in this release will merge multiple rows used to represent an annotation range into a single row. If you have a large number of region annotations the database migration may take a long time to complete. See Upgrading to v5.2 for tips on how to manage this process.
Grafana’s docker image is now based on instead of .
Plugins that need updating
Upgrading to v6.5
欧洲杯投注软件Pre Grafana 6.5.0, the CloudWatch datasource used the GetMetricStatistics API for all queries that did not have an ´id´ and did not have an ´expression´ defined in the query editor. The GetMetricStatistics API has a limit of 400 transactions per second (TPS). In this release, all queries use the GetMetricData API which has a limit of 50 TPS and 100 metrics per transaction. We expect this transition to be smooth for most of our users, but in case you do face throttling issues we suggest you increase the TPS quota. To do that, please visit the . For more details around CloudWatch API limits, .
Each request to the GetMetricData API can include 100 queries. This means that each panel in Grafana will only issue one GetMetricData request, regardless of the number of query rows that are present in the panel. Consequently as it is no longer possible to set
HighRes on a per query level anymore, this switch is now removed from the query editor. High resolution can still be achieved by choosing a smaller minimum period in the query editor.
The handling of multi-valued template variables in dimension values has been changed in Grafana 6.5. When a multi template variable is being used, Grafana will generate a search expression. In the GetMetricData API, expressions are limited to 1024 characters, so it might be the case that this limit is reached when a multi-valued template variable that has a lot of values is being used. If this is the case, we suggest you start using
*欧洲杯投注软件 wildcard as dimension value instead of a multi-valued template variable.
Upgrading to v6.6
The Generic OAuth setting
send_client_credentials_via_post, used for supporting non-compliant providers, has been removed. From now on, Grafana will automatically detect if credentials should be sent as part of the URL or request body for a specific provider. The result will be remembered and used for additional OAuth requests for that provider.
Important changes regarding SameSite cookie attribute
Chrome 80 treats cookies as
SameSite=Lax by default if no
SameSite欧洲杯投注软件 attribute is specified, see .
Due to this change in Chrome, the
cookie_samesite configured to
none now renders cookies with
SameSite=None attribute compared to before where no
SameSite attribute was added to cookies. To get the old behavior, use value
disabled instead of
none, see cookie_samesite in Configuration欧洲杯投注软件 for more information.
Note: There is currently a bug affecting Mac OSX and iOS that causes
SameSite=None cookies to be treated as
SameSite=Strict and therefore not sent with cross-site requests, see for details. Until this is fixed,
SameSite=None欧洲杯投注软件 might not work properly on Safari.
This version of Chrome also rejects insecure
SameSite=None cookies. See for more information. Make sure that you
true and use HTTPS when
cookie_samesite is configured to
none, otherwise authentication in Grafana won’t work properly.