{"id":231,"date":"2025-09-08T17:50:44","date_gmt":"2025-09-08T15:50:44","guid":{"rendered":"https:\/\/www.sysadmins.nl\/?p=231"},"modified":"2025-11-06T22:54:15","modified_gmt":"2025-11-06T21:54:15","slug":"minor-version-upgrade-timescaledb-for-zabbix","status":"publish","type":"post","link":"https:\/\/www.sysadmins.nl\/index.php\/2025\/09\/08\/minor-version-upgrade-timescaledb-for-zabbix\/","title":{"rendered":"Minor version Upgrade TimescaleDB for Zabbix"},"content":{"rendered":"<div class=\"wp-block-image\">\n<figure class=\"alignleft size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"346\" height=\"346\" src=\"https:\/\/www.sysadmins.nl\/wp-content\/uploads\/2025\/09\/logo-yellow-1.png\" alt=\"Tigerdata logo\" class=\"wp-image-236\" srcset=\"https:\/\/www.sysadmins.nl\/wp-content\/uploads\/2025\/09\/logo-yellow-1.png 346w, https:\/\/www.sysadmins.nl\/wp-content\/uploads\/2025\/09\/logo-yellow-1-300x300.png 300w, https:\/\/www.sysadmins.nl\/wp-content\/uploads\/2025\/09\/logo-yellow-1-150x150.png 150w\" sizes=\"auto, (max-width: 346px) 100vw, 346px\" \/><\/figure>\n<\/div>\n\n\n<p>As TimescaleDB has quite a lot minor version releases, you often come to a point that you have to update the TimescaleDB version you&#8217;re using.<\/p>\n\n\n\n<p>Before updating the version, always check which TimescaleDB versions are compatible with your PostgreSQL version. If your TimescaleDB version is <em>too new<\/em>, you will first have to upgrade your PostgreSQL server. A great page to visit and check the compatibility is this one: <a href=\"https:\/\/docs.tigerdata.com\/self-hosted\/latest\/upgrades\/minor-upgrade\/\">https:\/\/docs.tigerdata.com\/self-hosted\/latest\/upgrades\/minor-upgrade\/<\/a><\/p>\n\n\n\n<p>First let&#8217;s check the current version of PostgreSQL:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>su - postgres\npsql -X -d zabbix -c \"SELECT version();\"<\/code><\/pre>\n\n\n\n<p>This should give an output like this:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>-------------------------------------------------------------------------------------------------------------------------------------\n PostgreSQL 16.10 (Ubuntu 16.10-1.pgdg24.04+1) on x86_64-pc-linux-gnu, compiled by gcc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0, 64-bit\n(1 row)<\/code><\/pre>\n\n\n\n<p>After this check the current version of TimescaleDB:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>psql -X -d zabbix -c \"\\dx timescaledb;\"<\/code><\/pre>\n\n\n\n<p>This should give an output like this:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>                                              List of installed extensions\n    Name     | Version | Schema |                                      Description                                      \n-------------+---------+--------+---------------------------------------------------------------------------------------\n timescaledb | 2.21.3  | public | Enables scalable inserts and complex queries for time-series data (Community Edition)\n(1 row)\n<\/code><\/pre>\n\n\n\n<p>Before upgrading the installed TimescaleDB extension for your Zabbix database, you&#8217;ll have to check which extension version is available. This can be done with the following SQL-query:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>psql -X -d zabbix -c \"SELECT default_version, installed_version FROM pg_available_extensions WHERE name = 'timescaledb';\"<\/code><\/pre>\n\n\n\n<p>The output should be something like this:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code> default_version | installed_version \n-----------------+-------------------\n 2.22.0          | 2.21.3\n(1 row)<\/code><\/pre>\n\n\n\n<p>When all is great, you can perform the TimescaleDB extension upgrade. Type the exact version in which was displayed above in the column <strong><em>default_version<\/em><\/strong>:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>psql -X -d zabbix -c \"ALTER EXTENSION timescaledb UPDATE TO '2.22.0';\"<\/code><\/pre>\n\n\n\n<p>After this is done, check which version of the TimescaleDB extension you&#8217;re running right now:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>psql -X -d zabbix -c \"\\dx timescaledb;\"<\/code><\/pre>\n\n\n\n<p>Now you can see the new version of the extension is activated!<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code>Name     | Version | Schema |                                      Description                                      \n-------------+---------+--------+---------------------------------------------------------------------------------------\n timescaledb | 2.22.0  | public | Enables scalable inserts and complex queries for time-series data (Community Edition)\n(1 row)<\/code><\/pre>\n\n\n\n<p>As the releases of TimescaleDB are very often, Zabbix server sometimes will fail to start as you&#8217;re running a version which isn&#8217;t supported by Zabbix. To run Zabbix server on a <em>bleeding edge<\/em> version of the TimescaleDB extension you will have to change a setting in your <strong><em>zabbix_server.conf<\/em><\/strong>, this can be set like this:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>AllowUnsupportedDBVersions=1<\/code><\/pre>\n\n\n\n<p>After you&#8217;ve performed all the previous steps, you&#8217;re running a new TimescaleDB extension for your Zabbix server!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>As TimescaleDB has quite a lot minor version releases, you often come to a point that you have to update the TimescaleDB version you&#8217;re using. Before updating the version, always check which TimescaleDB versions are compatible with your PostgreSQL version. If your TimescaleDB version is too new, you will first have to upgrade your PostgreSQL [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":236,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[10,7,8],"tags":[24,23,14,6],"class_list":["post-231","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-education","category-observability","category-zabbix","tag-postgresql","tag-timescaledb","tag-upgrade","tag-zabbix"],"_links":{"self":[{"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/posts\/231","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/comments?post=231"}],"version-history":[{"count":5,"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/posts\/231\/revisions"}],"predecessor-version":[{"id":239,"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/posts\/231\/revisions\/239"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/media\/236"}],"wp:attachment":[{"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/media?parent=231"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/categories?post=231"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sysadmins.nl\/index.php\/wp-json\/wp\/v2\/tags?post=231"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}