Page 1 of 1
PHP 8.3? or 8.4?
Posted: Fri Dec 20, 2024 11:14 am
by tim620
Is there any guidance for upgrading to PHP 8.3 or 8.4? Is it compatible and are the newer versions of PHP supported by Nagios?
We need to keep up with supported versions of PHP on all our servers, including the Nagios Log and Nagios XI servers.
Re: PHP 8.3? or 8.4?
Posted: Fri Dec 20, 2024 11:42 am
by danderson
Thanks for reaching out,
PHP 8.3 should work with Nagios XI and Log Server. You may encounter some issues however, so I would definitely make a system backup or snapshot before doing any of these changes. You will have to make sure that the correct sourceguardian loaders are available on the system. On my RHEL 9 system, the sourceguardian loader is in `/usr/lib64/php/modules/` and the file is called `ixed.8.0.lin`
You can find the loaders
here
I will say, upgrading PHP isn't recommended and migrating XI to a new OS with the PHP version you prefer is the recommended approach. You can find the docs to do so
here
Re: PHP 8.3? or 8.4?
Posted: Fri Dec 20, 2024 11:56 am
by tim620
I'm not going to migrate to a new Linux VM every time I need to upgrade PHP.
We are currently running our Nagios XI on Oracle Linux 9 and Nagios Log servers on Oracle Linux 8.
I think Nagios should have documentation and support for the remi PHP repos and keep up with supported versions of PHP.
I should have asked, if PHP 8.3 and 8.4 are officially supported by Nagios? Will we run into problems with support, if I update our PHP to version 8.3 or 8.4?
Re: PHP 8.3? or 8.4?
Posted: Fri Dec 20, 2024 1:21 pm
by DoubleDoubleA
As mentioned in the nearly identical post in the XI forum, since Oracle 9 supports up to php 8.2, an XI system on that distro running php 8.3 is not supported.
Re: PHP 8.3? or 8.4?
Posted: Fri Dec 20, 2024 4:29 pm
by tim620
Are PHP versions from the "remi" repos supported?
I.e. If Oracle Linux 9.5 comes with PHP 8.2. Can I install the PHP 8.2 from "remi"? In order to be able to get support from Nagios? Or does it have to be PHP 8.2 from the Oracle Linux repos?
The main reason I ask about the "remi" repos is that we used the remi repos in order to get to PHP 8.1 in the first place. It would be easier to update to PHP 8.2 via the remi repos than it would be to remove the current PHP 8.1 and reinstall PHP via the Oracle Linux repos.
Also... If "remi" repos are a supported PHP from Nagios, then would the PHP 8.3 be supported from remi as well as 8.2? Because I did see a response that said 8.3 should work with Nagios XI (although I have not seen that for the Nagios Log servers yet).
Re: PHP 8.3? or 8.4?
Posted: Fri Dec 20, 2024 6:00 pm
by jmichaelson
Chiming in from your post on the XI side: no, they're not officially supported. As for PHP 8.3 in Nagios Log Server, we do support it on Ubuntu 24, which ships with PHP 8.3 so like XI it is compatible with PHP 8.3.
Re: PHP 8.3? or 8.4?
Posted: Mon Dec 23, 2024 11:06 am
by tim620
Thanks.
I think there was some previous misunderstanding on our team about how PHP "module enable" worked on RHEL clones worked. For example, on Oracle Linux 8 (and 9), the default php when you do a "dnf install php" give a 7.x version... unless you do a "module enable" to make 8.2 or 8.1 the default.
One of our system admins switched over to the "remi" repos to get access to the 8.x versions, not realizing you can also change the default PHP module versions on the OS repo's themselves. So... we have been on the "remi" repos for a while.
Switching to the OS versions would be ideal, but may take some testing, as I'm guessing that removing the remi versions will cause a number of other dependences to be removed. etc.
Re: PHP 8.3? or 8.4?
Posted: Mon Dec 23, 2024 5:13 pm
by jmichaelson
it might not be all that bad. i can't speak for the rhel, but the sury php repositories for Debian and Ubuntu are maintained by the same person who maintains the official Debian PHP packages, so on that front I'm certain that (so long as you're keeping the distros up to date anyway) that they're a drop-in replacement that's better than their backports.
This article is related to Cent 8, but it is likely a very similar process for EL9 based distros:
https://serverfault.com/questions/10645 ... -appstream