Hi,
I've executed the commands that you've speciied, but still Nagios is not Starting up.
Below is the output for your reference.
[root@localhost modules]# systemctl enable /etc/systemd/system/multi-user.target.wants/nagios.service
root@localhost modules]# systemctl start nagios
Job for nagios.service failed because the control process exited with error code. See "systemctl status nagios.service" and "journalctl -xe" for details.
[root@localhost modules]# systemctl status nagios.service -l
● nagios.service - Nagios Core 4.4.6
Loaded: loaded (/usr/lib/systemd/system/nagios.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Sat 2021-06-12 00:04:25 EDT; 17s ago
Docs: https://www.nagios.org/documentation
Process: 10339 ExecStopPost=/usr/bin/rm -f /usr/local/nagios/var/rw/nagios.cmd (code=exited, status=0/SUCCESS)
Process: 10336 ExecStartPre=/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg (code=exited, status=203/EXEC)
Jun 12 00:04:25 localhost.localdomain systemd[1]: Starting Nagios Core 4.4.6...
Jun 12 00:04:25 localhost.localdomain systemd[1]: nagios.service: control process exited, code=exited status=203
Jun 12 00:04:25 localhost.localdomain systemd[1]: Failed to start Nagios Core 4.4.6.
Jun 12 00:04:25 localhost.localdomain systemd[1]: Unit nagios.service entered failed state.
Jun 12 00:04:25 localhost.localdomain systemd[1]: nagios.service failed.
[root@localhost modules]# journalctl -xe
Jun 12 00:53:01 localhost.localdomain systemd[1]: Started Session 7235 of user nagios.
-- Subject: Unit session-7235.scope has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/li ... temd-devel
--
-- Unit session-7235.scope has finished starting up.
--
-- The start-up result is done.
Jun 12 00:53:01 localhost.localdomain CROND[13323]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13324]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13325]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13326]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13327]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13328]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13329]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13330]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13331]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:01 localhost.localdomain CROND[13332]: (nagios) CMD (/usr/bin/php -q /usr/
Jun 12 00:53:02 localhost.localdomain systemd[1]: Removed slice User Slice of nagios.
-- Subject: Unit user-1001.slice has finished shutting down
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/li ... temd-devel
--
-- Unit user-1001.slice has finished shutting down.
Kindly Assist.
NagiosXi Not working after Upgrading PHP (Offline)
Re: NagiosXi Not working after Upgrading PHP (Offline)
Regards,
Vision
Vision
Re: NagiosXi Not working after Upgrading PHP (Offline)
Hi Vision,
Is this a new (clean) install of Nagios XI?
What version of XI and OS are you running?
Can you please share the history of your Nagios XI? .... I'm not sure what has been removed/installed during the PHP upgrade process. (if you can let me know the command used to upgrade PHP).
Can you please post (upload) the "profile.zip" system file?
Nagios XI GUI > Admin >System Config > System Profile
If you're unable to generate the the profile through the web interface,
please try generating it from the command line by running these commands as root:
rm -rf /usr/local/nagiosxi/var/components/profile*
/usr/local/nagiosxi/scripts/components/getprofile.sh SUPPORT
or older system:
/usr/local/nagiosxi/html/includes/components/profile/getprofile.sh SUPPORT
Also, please share the outputs of the below command:
Best Regards,
Vinh
Is this a new (clean) install of Nagios XI?
What version of XI and OS are you running?
Can you please share the history of your Nagios XI? .... I'm not sure what has been removed/installed during the PHP upgrade process. (if you can let me know the command used to upgrade PHP).
Can you please post (upload) the "profile.zip" system file?
Nagios XI GUI > Admin >System Config > System Profile
If you're unable to generate the the profile through the web interface,
please try generating it from the command line by running these commands as root:
rm -rf /usr/local/nagiosxi/var/components/profile*
/usr/local/nagiosxi/scripts/components/getprofile.sh SUPPORT
or older system:
/usr/local/nagiosxi/html/includes/components/profile/getprofile.sh SUPPORT
Also, please share the outputs of the below command:
Code: Select all
rpm -qa | grep nagios
Vinh
Re: NagiosXi Not working after Upgrading PHP (Offline)
Hi,
Am trying to upgrade just the PHP version from 5.4.16 to 7.4.19 using offline Tarball, in my existing Nagios setup.
Nagios XI Version: 5.6.13
OS-- (64bit) Centos-release-7-8.2003.0.el7.centos.x86_64
VMware Image or Manual Install of XI? -- Manual Installation from Offline Tarball
I've followed the official documentation to upgrade PHP (https://support.nagios.com/kb/article/n ... 7-860.html)
The below are the commands that I've executed,
yum -y install epel-release wget
yum remove nagiosxi-deps* -y
rpm -Uvh http://rpms.remirepo.net/enterprise/remi-release-7.rpm
yum -y install yum-utils
PHPTZ=$(grep -s '^date.timezone' /etc/php.ini | awk '{print $3}')
yum -y remove php-*
yum-config-manager --enable remi-php74
yum -y install php php-imap php-opcache php-devel php-gd php-ldap php-mbstring php-pdo php-pdo-dblib php-mysqlnd php-pgsql php-pear php-pecl-ssh2 php-pgsql php-process php-snmp php-xml php-odbc
sed -i "s:;date.timezone =.*:date.timezone = ${PHPTZ}:" /etc/php.ini
Since It was an Installation from Offline Tarball, I've skipped the following steps,
cd /tmp
rm -rf /tmp/nagiosxi
wget https://assets.nagios.com/downloads/nag ... est.tar.gz
tar zxf xi-latest.tar.gz
cd /tmp/nagiosxi
rm -rf /etc/php.d/sourceguardian.ini
./init.sh
Then I executed below commands, but it doesn't return any results,
sed -i '/^PHP script/d' xi-sys.cfg
sed -i '/^1)/d' xi-sys.cfg
sed -i '/^2)/d' xi-sys.cfg
sed -i '/^3)/d' xi-sys.cfg
The install-sourceguardian-extension.sh is not found in Offline Tarball, so it returned "No such File or Directory" as output.
Now the PHP got upgraded from 5.4.16 to 7.4.20 but when we do, systemctl restart httpd the Nagios doesnt start.
Then as per your Instructions I've manually downloaded ixed.7.4.lin and nagios.service file.
The Output for pm -qa | grep nagios is:
[root@localhost components]# rpm -qa | grep nagios
nagiosxi-pnp-5.6.13-1.el7.x86_64
nagiosxi-nrds-5.6.13-1.el7.x86_64
nagiosxi-nrpe-5.6.13-1.el7.x86_64
nagiosxi-nagiosmobile-5.6.13-1.el7.x86_64
nagiosxi-nagiosplugins-5.6.13-1.el7.x86_64
nagiosxi-nsca-5.6.13-1.el7.x86_64
nagiosxi-nxti-5.6.13-1.el7.x86_64
nagiosxi-mrtg-5.6.13-1.el7.x86_64
nagiosxi-shellinabox-5.6.13-1.el7.x86_64
nagiosxi-wmic-5.6.13-1.el7.x86_64
nagiosxi-ndoutils-5.6.13-1.el7.x86_64
nagiosxi-wkhtmltox-5.6.13-1.el7.x86_64
Enclosed Nagios Profile for reference.
Am trying to upgrade just the PHP version from 5.4.16 to 7.4.19 using offline Tarball, in my existing Nagios setup.
Nagios XI Version: 5.6.13
OS-- (64bit) Centos-release-7-8.2003.0.el7.centos.x86_64
VMware Image or Manual Install of XI? -- Manual Installation from Offline Tarball
I've followed the official documentation to upgrade PHP (https://support.nagios.com/kb/article/n ... 7-860.html)
The below are the commands that I've executed,
yum -y install epel-release wget
yum remove nagiosxi-deps* -y
rpm -Uvh http://rpms.remirepo.net/enterprise/remi-release-7.rpm
yum -y install yum-utils
PHPTZ=$(grep -s '^date.timezone' /etc/php.ini | awk '{print $3}')
yum -y remove php-*
yum-config-manager --enable remi-php74
yum -y install php php-imap php-opcache php-devel php-gd php-ldap php-mbstring php-pdo php-pdo-dblib php-mysqlnd php-pgsql php-pear php-pecl-ssh2 php-pgsql php-process php-snmp php-xml php-odbc
sed -i "s:;date.timezone =.*:date.timezone = ${PHPTZ}:" /etc/php.ini
Since It was an Installation from Offline Tarball, I've skipped the following steps,
cd /tmp
rm -rf /tmp/nagiosxi
wget https://assets.nagios.com/downloads/nag ... est.tar.gz
tar zxf xi-latest.tar.gz
cd /tmp/nagiosxi
rm -rf /etc/php.d/sourceguardian.ini
./init.sh
Then I executed below commands, but it doesn't return any results,
sed -i '/^PHP script/d' xi-sys.cfg
sed -i '/^1)/d' xi-sys.cfg
sed -i '/^2)/d' xi-sys.cfg
sed -i '/^3)/d' xi-sys.cfg
The install-sourceguardian-extension.sh is not found in Offline Tarball, so it returned "No such File or Directory" as output.
Now the PHP got upgraded from 5.4.16 to 7.4.20 but when we do, systemctl restart httpd the Nagios doesnt start.
Then as per your Instructions I've manually downloaded ixed.7.4.lin and nagios.service file.
The Output for pm -qa | grep nagios is:
[root@localhost components]# rpm -qa | grep nagios
nagiosxi-pnp-5.6.13-1.el7.x86_64
nagiosxi-nrds-5.6.13-1.el7.x86_64
nagiosxi-nrpe-5.6.13-1.el7.x86_64
nagiosxi-nagiosmobile-5.6.13-1.el7.x86_64
nagiosxi-nagiosplugins-5.6.13-1.el7.x86_64
nagiosxi-nsca-5.6.13-1.el7.x86_64
nagiosxi-nxti-5.6.13-1.el7.x86_64
nagiosxi-mrtg-5.6.13-1.el7.x86_64
nagiosxi-shellinabox-5.6.13-1.el7.x86_64
nagiosxi-wmic-5.6.13-1.el7.x86_64
nagiosxi-ndoutils-5.6.13-1.el7.x86_64
nagiosxi-wkhtmltox-5.6.13-1.el7.x86_64
Enclosed Nagios Profile for reference.
Regards,
Vision
Vision
Re: NagiosXi Not working after Upgrading PHP (Offline)
Hi Vision,
How are you doing?
Your Nagios XI version is "5.6.13". Based on the PHP upgrade KB below, the supported PHP version for Nagios XI 5.6.x is "7.3"
https://support.nagios.com/kb/article/n ... 7-860.html
Nagios XI is compatible with the following versions of PHP.
5.3, 5.4, 5.5, 5.6 | 7.0, 7.1, 7.2 (XI 5.5+) | 7.3 (XI 5.6.8+) | 7.4 (XI 5.7.0+)
Please either upgrade Nagios XI to the latest or downgrade your PHP to "7.3".
Also, you can not skip the below steps. Please manually download "xi-latest.tar.gz" to your laptop and copy the "xi-latest.tar.gz" to your Nagios XI machine by using "WinSCP" .... and do the following steps as instructed in the KB:
Also, please upload "profile.zip". I did not see it in your last replied ...
Best Regards,
Vinh
How are you doing?
Your Nagios XI version is "5.6.13". Based on the PHP upgrade KB below, the supported PHP version for Nagios XI 5.6.x is "7.3"
https://support.nagios.com/kb/article/n ... 7-860.html
Nagios XI is compatible with the following versions of PHP.
5.3, 5.4, 5.5, 5.6 | 7.0, 7.1, 7.2 (XI 5.5+) | 7.3 (XI 5.6.8+) | 7.4 (XI 5.7.0+)
Please either upgrade Nagios XI to the latest or downgrade your PHP to "7.3".
Also, you can not skip the below steps. Please manually download "xi-latest.tar.gz" to your laptop and copy the "xi-latest.tar.gz" to your Nagios XI machine by using "WinSCP" .... and do the following steps as instructed in the KB:
Code: Select all
cd /tmp
rm -rf /tmp/nagiosxi
wget https://assets.nagios.com/downloads/nagiosxi/xi-latest.tar.gz
tar zxf xi-latest.tar.gz
cd /tmp/nagiosxi
rm -rf /etc/php.d/sourceguardian.ini
./init.sh
sed -i '/^PHP script/d' xi-sys.cfg
sed -i '/^1)/d' xi-sys.cfg
sed -i '/^2)/d' xi-sys.cfg
sed -i '/^3)/d' xi-sys.cfg
./install-sourceguardian-extension.sh
Also, please upload "profile.zip". I did not see it in your last replied ...
Best Regards,
Vinh