Zabbix Documentation 3.0

3.04.04.4 (current)| In development:5.0 (devel)| Unsupported:1.82.02.22.43.23.44.2Guidelines

User Tools

Site Tools


manual:installation:upgrade

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
manual:installation:upgrade [2015/10/23 11:41]
glebs.ivanovskis [7 Install new Zabbix web interface] warned user about the need to update PHP
manual:installation:upgrade [2018/02/15 07:10] (current)
martins-v warning level note about the upped php version
Line 1: Line 1:
-==== Upgrade procedure ====+==== Upgrade procedure ​using sources ​====
  
 === Overview === === Overview ===
  
-This section provides the steps required for a successful upgrade ​from Zabbix 2.4.x to 3.0.+This section provides the steps required for a successful upgrade to Zabbix ​3.0. 
  
-Database ​upgrade to version ​3.0 may take a long time.+Direct ​upgrade to Zabbix ​3.0 is possible from Zabbix 2.4.x, 2.2.x and 2.0.x. For upgrading from earlier versions consult Zabbix documentation for 2.0 and earlier.
  
-<note important>​Make sure to read [[upgrade_notes_300|upgrade notes]] ​before proceeding with the upgrade.</​note>​+While upgrading Zabbix agents is not mandatory (but recommended),​ Zabbix server and proxies must be of the [[:​manual/​appendix/​compatibility|same major version]]. Therefore, in a server-proxy setup, Zabbix server and all proxies have to be stopped and upgraded.  
 + 
 +To minimize downtime and data loss during the upgrade, it is recommended to stop and upgrade Zabbix server and then stop, upgrade and start Zabbix proxies one after another. When all proxies are upgraded, start Zabbix server. During the Zabbix server downtime, running proxies will keep collecting and storing data and will pass the data to Zabbix server when the server is up and running. Any notifications for problems during Zabbix server downtime will be generated only after the upgraded server is started. 
 + 
 +<note important>​It is known to be possible to start the upgraded server and have older, yet unupgraded proxies report data to a newer server (the proxies can't refresh their configuration though). This approach, however, is not recommended and not supported by Zabbix and choosing it is entirely at your own risk.</​note>​ 
 + 
 +Note that with SQLite database on proxies, history data from proxies before the upgrade will be lost, because SQLite database upgrade is not supported and the SQLite database file has to be manually removed. When proxy is started for the first time and the SQLite database file is missing, proxy creates it automatically. 
 + 
 +**Before the upgrade** from 2.4.x to 3.0: 
 + 
 +  * read the [[upgrade_notes_300|upgrade notes for 3.0]] 
 +  * check [[:​manual/​installation/​requirements|requirements for 3.0]] 
 + 
 +If upgrading from earlier versions, read also the upgrade ​notes for [[https://​www.zabbix.com/​documentation/​2.2/​manual/​installation/​upgrade_notes_220|2.0 -> 2.2]] and [[https://​www.zabbix.com/​documentation/​2.4/​manual/​installation/​upgrade_notes_240|2.2 -> 2.4]]. 
 + 
 +<note tip>It may be handy to run two parallel SSH sessions during the upgrade, executing the upgrade steps in one and monitoring the server/​proxy logs in another. For example, run ''​tail -f zabbix_server.log''​ or  ''​tail -f zabbix_proxy.log''​ in the second SSH session showing you the latest log file entries and possible errors in real time. This can be critical for production instances.</​note>​ 
 +=== Server upgrade process ===
  
 == 1 Stop Zabbix server == == 1 Stop Zabbix server ==
Line 19: Line 35:
 == 3 Back up configuration files, PHP files and Zabbix binaries == == 3 Back up configuration files, PHP files and Zabbix binaries ==
  
-Make a backup copy of Zabbix binaries, configuration files and PHP files.+Make a backup copy of Zabbix binaries, configuration files and the PHP file directory.
  
 == 4 Install new server binaries == == 4 Install new server binaries ==
  
-You may use pre-compiled binaries or [[install#from_the_sources|compile your own]].+Use these [[install#installing_zabbix_daemons|instructions]] to compile Zabbix server from sources.
  
 == 5 Review server configuration parameters == == 5 Review server configuration parameters ==
  
-Some parameters of zabbix_server.conf might have changed from 2.4new parameters added. You may want to review them.+The //​HistoryTextCacheSize//​ parameter has been replaced by a new //​HistoryIndexCacheSize//​ server [[:​manual/​appendix/​config/​zabbix_server|parameter]]which must be present for the server ​to start
  
 +For other recommended changes and new parameters, see the [[:​manual/​introduction/​whatsnew300#​configuration_parameters|What'​s new]] section.
 == 6 Start new Zabbix binaries == == 6 Start new Zabbix binaries ==
  
 Start new binaries. Check log files to see if the binaries have started successfully. Start new binaries. Check log files to see if the binaries have started successfully.
  
-Zabbix server will automatically upgrade the database.+Zabbix server will automatically upgrade the database. ​When starting up, Zabbix server reports the current (mandatory and optional) and required database versions. If the current mandatory version is older than the required version, Zabbix server automatically executes the required database upgrade patches. The start and progress level (percentage) of the database upgrade is written to the Zabbix server log file. When the upgrade is completed, a "​database upgrade fully completed"​ message is written to the log file. If any of the upgrade patches fail, Zabbix server will not start. Zabbix server will also not start if the current mandatory database version is newer than the required one. Zabbix server will only start if the current mandatory database version corresponds to the required mandatory version. 
 + 
 +  8673:​20161117:​104750.259 current database version (mandatory/​optional):​ 03000000/​03000000 
 +  8673:​20161117:​104750.259 required mandatory version: 03000000
  
 Before you start the server: Before you start the server:
Line 39: Line 59:
   * Make sure the database user has enough permissions (create table, drop table, create index, drop index)   * Make sure the database user has enough permissions (create table, drop table, create index, drop index)
   * Make sure you have enough free disk space.   * Make sure you have enough free disk space.
- 
-Zabbix server automatically upgrades the database only since Zabbix 2.0.x to 3.0. For upgrading from earlier versions consult Zabbix documentation for 2.0 and earlier. 
  
 == 7 Install new Zabbix web interface == == 7 Install new Zabbix web interface ==
  
-The minimum required PHP version has been [[upgrade_notes_300?&#​frontend_changes|upped]] from 5.3.0 to 5.4.0. Update if needed and follow [[install#​installing_zabbix_web_interface|installation instructions]].+<note warning>The minimum required PHP version has been [[upgrade_notes_300?&#​frontend_changes|upped]] from 5.3.0 to 5.4.0.</​note>​ 
 + 
 +Update if needed and then follow ​the [[install#​installing_zabbix_web_interface|installation instructions]]. 
 + 
 +== 8 Clear web browser cookies and cache == 
 + 
 +After the upgrade you may need to clear web browser cookies and web browser cache for the Zabbix web interface to work properly. 
 + 
 +=== Proxy upgrade process === 
 + 
 +== 1 Stop Zabbix proxy == 
 + 
 +Stop Zabbix proxy. 
 + 
 +== 2 Back up configuration files and Zabbix proxy binaries == 
 + 
 +Make a backup copy of the Zabbix proxy binary and configuration file. 
 + 
 +== 3 Install new proxy binaries == 
 + 
 +Use these [[install#​installing_zabbix_daemons|instructions]] to compile Zabbix proxy from sources. 
 + 
 +== 4 Review proxy configuration parameters == 
 + 
 +The //​HistoryTextCacheSize//​ parameter has been replaced by a new //​HistoryIndexCacheSize//​ proxy [[:​manual/​appendix/​config/​zabbix_proxy|parameter]],​ which must be present for the proxy to start.  
 + 
 +For other recommended changes and new parameters, see the [[:​manual/​introduction/​whatsnew300#​configuration_parameters|What'​s new]] section. 
 + 
 +== 5 Start new Zabbix proxy == 
 + 
 +Start the new Zabbix proxy. Check log files to see if the proxy has started successfully. 
 + 
 +Zabbix proxy will automatically upgrade the database. Database upgrade takes place similarly as when starting [[:​manual/​installation/​upgrade#​start_new_zabbix_binaries|Zabbix server]]. 
 + 
 +=== Agent upgrade process === 
 + 
 +<note important>​Upgrading agents is not mandatory. You only need to upgrade agents if it is required to access the new functionality.</​note>​ 
 + 
 +== 1 Stop Zabbix agent == 
 + 
 +Stop Zabbix agent. 
 + 
 +== 2 Back up configuration files and Zabbix agent binaries == 
 + 
 +Make a backup copy of the Zabbix agent binary and configuration file. 
 + 
 +== 3 Install new agent binaries == 
 + 
 +Use these [[install#​installing_zabbix_daemons|instructions]] to compile Zabbix agent from sources. 
 + 
 +Alternatively,​ you may download pre-compiled Zabbix agents from the [[http://​www.zabbix.com/​download.php|Zabbix download page]]. 
 + 
 +== 4 Review agent configuration parameters == 
 + 
 +There are no mandatory changes in this version to agent [[:​manual/​appendix/​config/​zabbix_agentd|parameters]]. For recommended changes and new optional parameters, see the [[:​manual/​introduction/​whatsnew300#​configuration_parameters|What'​s new]] section. 
 + 
 +== 5 Start new Zabbix agent == 
 + 
 +Start the new Zabbix agent. Check log files to see if the agent has started successfully. 
 + 
 +=== Upgrade between minor versions ===
  
 +When upgrading between minor versions of 3.0.x (for example from 3.0.1 to 3.0.3) it is required to execute the same actions for server/​proxy/​agent as during the upgrade between major versions. The only difference is that when upgrading between minor versions no changes to the database are made.