Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
en:documentation:02_installation:02_anexo_upgrade [2021/07/14 03:22] jimmy.olano [Online updates] Estilo. |
en:documentation:02_installation:02_anexo_upgrade [2023/05/16 08:31] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== Upgrades and updates ====== | ====== Upgrades and updates ====== | ||
+ | |||
{{indexmenu_n> | {{indexmenu_n> | ||
- | [[en: | + | [[:en: |
+ | |||
+ | ===== Warp Update (Update Manager) ===== | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | From version 763, Pandora FMS will be able to check online whether there is an update and, upon request, download it and automatically update your Web Console. | ||
+ | |||
+ | <WRAP center round info 60%> | ||
+ | |||
+ | If you have version 762 (or earlier) installed, use [[: | ||
+ | |||
+ | </ | ||
+ | |||
+ | This update has the following features: | ||
+ | |||
+ | * You will need to be [[: | ||
+ | * **Warp Update** | ||
+ | * Updates are the entire content of the Web Console, so the process can be quite long. | ||
+ | * The updates are automatic and in 99% of the cases it should work properly, although there is no guarantee that it will. | ||
+ | * You may also [[: | ||
+ | |||
+ | ==== Warp Update Online ==== | ||
+ | |||
+ | In order to update through **Warp Update** | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | In a few seconds **Warp Update** | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | ==== Warp Update Offline ==== | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | Once downloaded, go to the menu ►**Warp Update** → **Warp Update Offline** and click ♦**Browse it** (there is also the option to drag and drop the file). | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | <WRAP center round important 60%> | ||
+ | |||
+ | Applying offline patches may deem your console unusable, we recommend you to completely [[https:// | ||
+ | |||
+ | </ | ||
+ | {{ : | ||
+ | |||
+ | You will see something similar to the previous image where the changes are listed, click on the green icon located on the lower right corner to continue. Your Pandora FMS server will be up to date. | ||
+ | |||
+ | <WRAP center round important 90%> | ||
+ | |||
+ | **Important**: | ||
+ | < | ||
+ | |||
+ | sed -i -e " | ||
+ | |||
+ | </ | ||
+ | |||
+ | Save and restart the Apache service with '' | ||
+ | |||
+ | </ | ||
+ | |||
+ | |||
+ | ==== Warp Update Journal ==== | ||
+ | |||
+ | Go to ►**Warp Update** | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | Thoughout time many records will be accumulated, | ||
+ | |||
+ | ==== Warp Update Setup ==== | ||
+ | |||
+ | The default values are useful in most cases, however they can be changed. | ||
+ | |||
+ | <WRAP center round tip 60%> | ||
+ | |||
+ | **Enterprise version**: [[https:// | ||
+ | |||
+ | * **Warp Update URL**. | ||
+ | * **Use secured Warp Update**. | ||
+ | * **Proxy server**. | ||
+ | * **Proxy port**. | ||
+ | * **Proxy user**. | ||
+ | * **Proxy password**. | ||
+ | </ | ||
+ | |||
+ | {{ : | ||
+ | * **Allow no-consecutive patches**: It allows non-consecutive updates to be installed. Disabled by default and it is the recommended option. | ||
+ | * **Limit to LTS updates**: It allows you to update only long-term versions (**LTS**). | ||
+ | When you finish entering the changes, save the values by clicking **Update**. | ||
===== Manual Update ===== | ===== Manual Update ===== | ||
Line 9: | Line 100: | ||
It is important to understand the basic components in which Pandora FMS is divided. There are three main elements: console, server and database. | It is important to understand the basic components in which Pandora FMS is divided. There are three main elements: console, server and database. | ||
- | {{ wiki:Pandora FMS standard design.png ?600 }} | + | {{ :wiki:pandora_fms_standard_design.png }} |
In Opensource installations, | In Opensource installations, | ||
Line 21: | Line 112: | ||
* Database. | * Database. | ||
- | As for **Enterprise** installations: | + | [[https:// |
* Open Web Console. | * Open Web Console. | ||
Line 29: | Line 120: | ||
* Database (additional charts of the Enterprise version). | * Database (additional charts of the Enterprise version). | ||
- | Updates | + | Updates will **always** |
==== Update a minor version ==== | ==== Update a minor version ==== | ||
Line 35: | Line 127: | ||
These do not include any changes in the database, only in the console and sometimes in the server. E.g. updates 6.1 SP1 to 6.1 SP2. | These do not include any changes in the database, only in the console and sometimes in the server. E.g. updates 6.1 SP1 to 6.1 SP2. | ||
- | Initial precautions: | + | Initial precautions: |
1. Back up the database. E.g.: | 1. Back up the database. E.g.: | ||
+ | < | ||
- | | + | mysqldump -u root -p pandora> |
- | 2. Back up the config files: '' | + | </ |
- | 3. Back up server and agent plugins, at: | + | 2. Back up the config files: '' |
+ | |||
+ | 3. Back up server and agent plugins, at: | ||
< | < | ||
- | / | + | / |
- | | + | pandora_console/ |
- | / | + | / |
</ | </ | ||
- | 4. Suspend the following services: '' | + | 4. Suspend the following services: '' |
5. Proceed to update. | 5. Proceed to update. | ||
=== From RPM packages === | === From RPM packages === | ||
+ | |||
+ | Go to [[https:// | ||
* Open console update: | * Open console update: | ||
+ | < | ||
- | | + | rpm -U pandorafms_console*.rpm |
- | * Enterprise console update: | + | </ |
- | | + | |
+ | < | ||
- | * Open server update: | + | rpm -U pandorafms_console_enterprise_package.rpm |
- | rpm -U pandorafms_server_package.rpm | + | </ |
- | * Enterprise | + | * Open server update: |
< | < | ||
- | | + | rpm -U pandorafms_server*.rpm |
- | cd pandora_server | + | |
- | | + | |
</ | </ | ||
- | You can find out which version | + | * [[https:// |
+ | < | ||
- | rpm -qa | grep -i pandora | + | tar -xvzf pandorafms_server_enterprise_package.tar.gz |
+ | cd pandora_server | ||
+ | ./ | ||
- | === From DEB packages === | + | </ |
- | * Open console update: | + | |
- | | + | |
- | | + | < |
+ | rpm -U pandorafms_agent*.rpm | ||
- | dpkg -i pandorafms_console_enterprise_package.deb | + | </ |
- | * Open server update: | + | You can find out which version you have installed at any time, before or after the installation by executing the command: |
- | dpkg -i pandorafms_server_package.deb | ||
- | |||
- | * Enterprise server update: | ||
< | < | ||
- | tar zxvf pandorafms_server_enterprise_package.tar.gz | + | rpm -qa | grep -i pandora |
- | cd pandora_server/ | + | |
- | | + | |
</ | </ | ||
- | Before and after updating, you may find out the installed versions by executing this command: | + | {{:wiki: |
- | rpm -qa | grep -i pandora | ||
=== From Tarball / Sources === | === From Tarball / Sources === | ||
- | * Open console update: | + | Go to [[https:// |
+ | * Open Source console update: | ||
< | < | ||
- | tar xvzf pandorafms_console_package.tar.gz | ||
- | cd pandora_console | ||
- | | ||
- | </ | ||
- | * Enterprise console update: | + | tar xvzf pandorafms_console_package.tar.gz |
+ | cd pandora_console | ||
+ | ./ | ||
+ | |||
+ | </ | ||
+ | * [[https:// | ||
< | < | ||
- | tar xvzf pandorafms_console_enterprise_package.tar.gz | + | |
- | cd pandora_console | + | tar xvzf pandorafms_console_enterprise_package.tar.gz |
- | | + | cd pandora_console |
+ | ./ | ||
</ | </ | ||
- | * Open server update: | + | * Open Source |
< | < | ||
- | tar xvzf pandorafms_server_package.tar.gz | + | tar xvzf pandorafms_server_package.tar.gz |
- | cd pandora_server | + | cd pandora_server |
- | | + | ./ |
</ | </ | ||
- | * Enterprise server update: | + | * [[https:// |
< | < | ||
- | tar xvzf pandorafms_server_enterprise_package.tar.gz | + | |
- | cd pandora_server | + | tar xvzf pandorafms_server_enterprise_package.tar.gz |
- | | + | cd pandora_server |
+ | ./ | ||
</ | </ | ||
- | * Agent update: | + | * Software |
< | < | ||
- | tar xvzf pandorafms_agent_package.tar.gz | + | tar xvzf pandorafms_agent_package.tar.gz |
- | cd pandora_agent | + | cd pandora_agent |
- | | + | ./ |
</ | </ | ||
+ | |||
=== Version 7.0NG ( Rolling Release ) === | === Version 7.0NG ( Rolling Release ) === | ||
- | If you choose to update manually the Pandora FMS Console in version 7.0NG, (through '' | + | If you choose to update manually the Pandora FMS Console in version 7.0NG, (through '' |
In case of having an outdated database (a rare error that should not take place under normal circumstances), | In case of having an outdated database (a rare error that should not take place under normal circumstances), | ||
- | {{ wiki: | + | {{ :wiki: |
To solve this problem, enter the server where the Pandora FMS console is installed and go to the directory: | To solve this problem, enter the server where the Pandora FMS console is installed and go to the directory: | ||
- | | + | < |
+ | / | ||
- | There should be another directory located within labeled as '' | + | </ |
- | '' | + | There should be another directory located within labeled as '' |
- | [[email protected] | + | '' |
- | The MySQL user is '' | + | < |
+ | [root@localhost mr]# cat 1.sql | mysql -u root -p pandora | ||
- | Once applied, update the **MR** value in the '' | + | </ |
+ | The MySQL user is '' | ||
+ | |||
+ | Once applied, update the **MR** | ||
< | < | ||
- | mysql> use pandora; | + | |
- | mysql> update tconfig set value= XX where token=' | + | mysql -u root -p pandora> use pandora;> |
</ | </ | ||
- | Once done, the warning message will disappear from the Console and in the footer, the '' | + | Once done, the warning message will disappear from the Console and in the footer, the '' |
- | | + | < |
+ | [[email protected] mr]# mkdir -p updated | ||
+ | [[email protected] mr]# mv 1.sql updated/ | ||
+ | |||
+ | </ | ||
- | To know which MRs should be applied, please go to the next [[en: | + | To know which MRs should be applied, please go to the next [[:en: |
==== Major release update ==== | ==== Major release update ==== | ||
Major release updates always include database changes, so **you need to update your database schema**, e. g. updates from version 6.0 to 6.1; or 6.1 to 7.0. | Major release updates always include database changes, so **you need to update your database schema**, e. g. updates from version 6.0 to 6.1; or 6.1 to 7.0. | ||
+ | |||
+ | <WRAP center round info 90%> | ||
=== Database updates (" | === Database updates (" | ||
- | In order to update the database, first update the Open or Enterprise console, depending on your version. These updates allow the necessary **sql** files to be downloaded. | + | In order to update the database, first update the Open or Enterprise console, depending on your version. These updates allow the necessary **sql** |
- | Once the console is up to date, the **sql** scripts of the database update | + | Once the console is up to date, the **sql** |
+ | < | ||
+ | |||
+ | / | ||
+ | |||
+ | </ | ||
< | < | ||
- | / | + | / |
- | / | + | |
</ | </ | ||
Before updating, it is recommended to follow the precautions described above: back up the database and the config files, and suspend the Pandora FMS server: | Before updating, it is recommended to follow the precautions described above: back up the database and the config files, and suspend the Pandora FMS server: | ||
- | | + | < |
+ | service pandora_server stop | ||
+ | |||
+ | </ | ||
* Open database update: | * Open database update: | ||
- | | + | < |
+ | mysql -u username -p -D databasename | ||
+ | |||
+ | </ | ||
E. g.: | E. g.: | ||
- | | + | < |
+ | mysql -u pandora -p -D pandora | ||
+ | |||
+ | </ | ||
Execute the following from MySQL command-line: | Execute the following from MySQL command-line: | ||
- | | + | < |
+ | source / | ||
- | <WRAP center round tip 60%> | + | </ |
- | When executing the Open version migration, the Enterprise version will also be updated. | + | |
- | </ | + | <WRAP center round tip 60%> When executing the Open version migration, the Enterprise version will also be updated. </ |
To exit the MySQL client, execute '' | To exit the MySQL client, execute '' | ||
Line 220: | Line 352: | ||
< | < | ||
- | mysql -u username -p databasename | + | mysql -u username -p databasename> |
- | > drop database databasename; | + | > use newdatabasename; |
- | > create database newdatabasename; | + | > source |
- | > use newdatabasename; | + | |
- | > source | + | |
</ | </ | ||
Line 230: | Line 361: | ||
< | < | ||
- | mysql -u root -p pandora | + | mysql -u root -p pandora> drop database pandora;> |
- | > drop database pandora; | + | > use pandora; |
- | > create database pandora; | + | > source |
- | > use pandora; | + | |
- | > source | + | |
</ | </ | ||
===== Automatic update with Update Manager ===== | ===== Automatic update with Update Manager ===== | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | More information can be found in the video tutorial «[[https:// | ||
==== OpenSource updates ==== | ==== OpenSource updates ==== | ||
- | From version 4.0.2 onwards, Pandora FMS (Opensource version) allows semi-automatic weekly updates, based on improvements in the **Update Manager** system (previously exclusive to Enterprise). | + | From version 4.0.2 onwards, Pandora FMS (Opensource version) allows semi-automatic weekly updates, based on improvements in the **Update Manager** |
Updates feature the following characteristics: | Updates feature the following characteristics: | ||
- | * An outgoing Internet connection from the Pandora FMS console is necessary. | + | * An [[: |
- | * **Update manager** contacts our servers to find the latest version available (in Sourceforge). It sends statistical data on the number of agents used (the data is anonymous). | + | * **Update manager** |
* It downloads the update from Sourceforge, | * It downloads the update from Sourceforge, | ||
* Weekly updates are not incremental, | * Weekly updates are not incremental, | ||
* Updates are automatic: they are not checked by the team, and cannot be guaranteed. However, in 99% of cases they present no issues. | * Updates are automatic: they are not checked by the team, and cannot be guaranteed. However, in 99% of cases they present no issues. | ||
- | * Updates are **only** for the console, not for agents or server. | + | * Updates are **only** |
=== Console update process === | === Console update process === | ||
- | It is fairly simple. Go to **Update manager** → **Update manager online**. On the main screen you will see if there are any pending or available updates, plus the latest console version. | + | It is fairly simple. Go to **Update manager** |
{{ : | {{ : | ||
- | If there is any update, click **Ok** to install it. After downloading the package, a dialog will appear with the option to accept or reject the update. | + | If there is any update, click **Ok** |
{{ : | {{ : | ||
- | Click **Ok** to begin the installation process. | + | Click **Ok** |
Some updates contain database modifications. The update process launches a dialog to inform about these changes, as in the following screenshot: | Some updates contain database modifications. The update process launches a dialog to inform about these changes, as in the following screenshot: | ||
Line 275: | Line 409: | ||
{{ : | {{ : | ||
- | |||
==== Enterprise updates ==== | ==== Enterprise updates ==== | ||
Line 289: | Line 422: | ||
=== Configuration === | === Configuration === | ||
- | {{wiki: | + | {{:wiki: |
- | To be able to use **Update Manager** in the Enterprise version, first the updater must be correctly configured, which has its own section in the menu: | + | To be able to use **Update Manager** |
- | {{ wiki:Opciones_um_es.png?700 }} | + | {{ :wiki:opciones_um_es.png? |
=== Online updates === | === Online updates === | ||
Line 312: | Line 445: | ||
After, the updater will appear with the current version installed on Pandora FMS. | After, the updater will appear with the current version installed on Pandora FMS. | ||
- | |||
=== Offline updates === | === Offline updates === | ||
- | Offline Pandora FMS updates can also be downloaded, which have '' | + | {{: |
Upload them to the console with the following control: | Upload them to the console with the following control: | ||
- | {{ wiki:Um_offline_pag_principal_es.png?700 }} | + | {{ :wiki:um_offline_pag_principal_es.png }} |
Once uploaded, the file will appear. We can click on it to start the update. | Once uploaded, the file will appear. We can click on it to start the update. | ||
- | {{ wiki:Um_offline_pag_principal_cargado_es.png?560 }} | + | {{ :wiki:um_offline_pag_principal_cargado_es.png }} |
- | The update follows the same operation flow as online downloads, displaying the corresponding console and database update dialogs, if there are any changes to be applied there. | + | The update follows the same operation flow as online downloads, displaying the corresponding console and database update dialogs, if there are any changes to be applied there. |
- | <WRAP center round tip 60%> | + | <WRAP center round tip 60%> The Pandora FMS Console can be updated in the same way as with the OUMs, using zip files created by our team. </ |
- | The Pandora FMS Console can be updated in the same way as with the OUMs, using zip files created by our team. | + | |
- | </ | + | |
- | + | ||
- | <WRAP center round important 60%> | + | |
- | In case of updating an installation with High Availability (HA), it will be necessary to take into account what is indicated in [[en: | + | |
- | </ | + | |
+ | <WRAP center round important 60%> In case of updating an installation with High Availability (HA), it will be necessary to take into account what is indicated in [[: | ||
==== Additional PHP engine configuration for Update Manager ==== | ==== Additional PHP engine configuration for Update Manager ==== | ||
Line 342: | Line 469: | ||
The line is: | The line is: | ||
+ | < | ||
- | < | ||
memory_limit = 800M ; Maximum amount of memory a script may consume | memory_limit = 800M ; Maximum amount of memory a script may consume | ||
</ | </ | ||
- | To find out the location of the file '' | + | To find out the location of the file '' |
< | < | ||
php -i | grep php.ini | php -i | grep php.ini | ||
Line 356: | Line 484: | ||
Also, depending on Pandora FMS version you have installed, you may get the information to update to version PHP 7 [[: | Also, depending on Pandora FMS version you have installed, you may get the information to update to version PHP 7 [[: | ||
+ | ==== Migrating to another system ==== | ||
- | ===== Migrating | + | There can be many reasons |
- | You may want to use a new Pandora FMS version in another different or newer system or distribution, | + | // |
- | 1. Back up the previous system' | + | * A new version of Pandora FMS may require a different operating system, for example, migrating from CentOS 7 to Rocky Linux 8 or from CentOS 8 to RedHat Enterprise (RHEL) 8. |
+ | * It could also be the case of switching from one web service provider to another: less data is used by Pandora FMS than making an image of the entire operating system. | ||
+ | * In case of audits or to test new features, it is necessary to have a copy of the main server. | ||
+ | **Procedure: | ||
+ | |||
+ | Note: Generally the full path to the PFMS Web Console is ''/ | ||
+ | |||
+ | **1.-** | ||
+ | |||
+ | * Start by making a logical copy of the database with the following command: | ||
< | < | ||
- | mysqldump -u root -p pandora> backup_pandora_X.Y.sql | + | |
+ | mysqldump | ||
</ | </ | ||
- | 2. Install | + | * The resulting file ( '' |
+ | * Compress all existing configuration files in the directory '' | ||
+ | * Compress the entire directory and subdirectories of '' | ||
+ | * Custom images and icons in '' | ||
+ | * Compress the whole directory ''/ | ||
+ | * Compress all [[: | ||
+ | * Compress all dependencies installed on the source server, which are necessary for the correct operation of scripts / plugins installed on the source server | ||
+ | * Compress all SSL certificates and custom Apache web server configuration located in ''/ | ||
- | 3. Then, send or copy the '' | + | <WRAP center round important 60%> You are the only person responsible for safeguarding your data. Write down on pen and paper the procedure you will choose for migrating data. **Be careful**, use redundancy in backups and procedures with several people |
- | 4. Close all running | + | **2.-** Install the new Pandora FMS system from scratch, the [[: |
+ | |||
+ | **3.-** | ||
< | < | ||
Line 381: | Line 529: | ||
</ | </ | ||
- | <WRAP center round tip 60%>\\ | + | **4.-** |
- | From version NG 754 onwards, [[: | + | |
- | </ | + | |
- | 5. Stopping the Apache server will depend on the distribution | + | |
- | < | + | |
+ | < | ||
/ | / | ||
Line 401: | Line 546: | ||
</ | </ | ||
- | 6. Enter **MySQL** as root user. Access Pandora FMS database | + | **5.-** |
+ | |||
+ | **6.-** | ||
< | < | ||
# mysql -u root -p | # mysql -u root -p | ||
| | ||
| | ||
- | | + | |
</ | </ | ||
- | This path will vary depending on the directory where the backup is stored. | + | //This path will vary depending on the directory where you have the backup |
- | 7. In case of migrating | + | **7.-** |
- | 8. If you changed the distribution, | + | **8.- **If you made a distribution |
< | < | ||
- | #mysql -u root -p | + | |
- | mysql>use pandora | + | # mysql -u root -p> use pandora; |
- | | + | Database changed> UPDATE tconfig SET value = '/ |
- | mysql>UPDATE tconfig SET value = '/ | + | |
- | mysql>UPDATE tconfig SET value = '/ | + | |
</ | </ | ||
- | Keep these '' | + | //These //'' |
- | 9. Once the database | + | **9.-** |
- | a. Replace the new files with the old ones or replace the data of the new files for the old ones. | + | * //If they are the same, go to //**step 10**//.// |
- | + | * If different, choose only one of the following options: | |
- | b. Give the database | + | * Option ( a ): Replace the new files with the old ones. |
+ | * Option ( b ): Copy data ( '' | ||
+ | * Option ( c ): Give permissions to the database with the data of the new installation. | ||
< | < | ||
- | #mysql -u root -p | + | # mysql -u root -p> grant all privileges on pandora.* to ' |
- | mysql>grant all privileges on pandora.* to ' | + | |
- | mysql>flush privileges; | + | |
</ | </ | ||
- | Restart | + | **10.-** |
- | If it is the Enterprise version, follow | + | **11.-** |
+ | **12.-** | ||
- | ===== Update to a previous | + | <WRAP center round info 60%> \\ If it is the Enterprise |
- | To be able to update your software | + | ===== Downgrade ===== |
+ | |||
+ | In order to perform | ||
==== From RPM packages ==== | ==== From RPM packages ==== | ||
- | * Open console update: | + | * Open Source |
- | | + | < |
+ | rpm -i --force pandorafms_console_package.rpm | ||
+ | |||
+ | </ | ||
* Enterprise console update: | * Enterprise console update: | ||
- | | + | < |
+ | rpm -i --force pandorafms_console__enterprise_package.rpm | ||
+ | |||
+ | </ | ||
==== From Tarball/ | ==== From Tarball/ | ||
- | * Open console update: | + | * Open Source |
< | < | ||
- | tar -xvzf pandorafms_console_package.tar.gz | + | tar -xvzf pandorafms_console_package.tar.gz |
- | | + | mv --force |
</ | </ | ||
* Enterprise console update: | * Enterprise console update: | ||
+ | |||
< | < | ||
- | tar -xvzf pandorafms_console_package.tar.gz | + | tar -xvzf pandorafms_console_package.tar.gz |
- | mv -f ./ | + | mv --force |
</ | </ | ||
+ | |||
+ |