Scheduled Backups Page
Scheduled Backups Page
Recently updated PHP on our XI install from 7.2 to 7.4. Went pretty well except php-pecl-ssh2 was uninstalled by yum during the upgrade and the scheduled backups broke. Since RHEL 8 went to 2 repos the os and appstream and it appears that package is only available in the remi repo is there any alternative or do I need to get the remi repo added to reinstall that package?
Re: Scheduled Backups Page
Hi
I am not sure what the remi repo is. But this is what we do to get at the
EOL OS repos
CentOS 8.5.2111 EOL Vault Setup:
mkdir /etc/yum.repos.d/old
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/old/
cat << EOF > /etc/yum.repos.d/CentOS-vault.repo
[C8-BaseOS]
name=CentOS 8 - BaseOS
baseurl=https://vault.centos.org/8.5.2111/BaseOS/$basearch/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
[C8-AppStream]
name=CentOS 8 - AppStream
baseurl=https://vault.centos.org/8.5.2111/AppSt ... search/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
[C8-PowerTools]
name=CentOS 8 - PowerTools
baseurl=https://vault.centos.org/8.5.2111/Power ... search/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
EOF
cat << EOF > /etc/yum.repos.d/epel.repo
[epel]
name=Extra Packages for Enterprise Linux $releasever - $basearch
# It is much more secure to use the metalink, but if you wish to use a local mirror
# place its address here.
#baseurl=https://download.example/pub/epel/$rele ... /$basearch
metalink=https://mirrors.fedoraproject.org/metal ... contentdir
enabled=1
gpgcheck=1
countme=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-8
EOF
Thanks
I am not sure what the remi repo is. But this is what we do to get at the
EOL OS repos
CentOS 8.5.2111 EOL Vault Setup:
mkdir /etc/yum.repos.d/old
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/old/
cat << EOF > /etc/yum.repos.d/CentOS-vault.repo
[C8-BaseOS]
name=CentOS 8 - BaseOS
baseurl=https://vault.centos.org/8.5.2111/BaseOS/$basearch/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
[C8-AppStream]
name=CentOS 8 - AppStream
baseurl=https://vault.centos.org/8.5.2111/AppSt ... search/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
[C8-PowerTools]
name=CentOS 8 - PowerTools
baseurl=https://vault.centos.org/8.5.2111/Power ... search/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
EOF
cat << EOF > /etc/yum.repos.d/epel.repo
[epel]
name=Extra Packages for Enterprise Linux $releasever - $basearch
# It is much more secure to use the metalink, but if you wish to use a local mirror
# place its address here.
#baseurl=https://download.example/pub/epel/$rele ... /$basearch
metalink=https://mirrors.fedoraproject.org/metal ... contentdir
enabled=1
gpgcheck=1
countme=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-8
EOF
Thanks
Re: Scheduled Backups Page
Adding the Remi repo is part of the PHP upgrade instructions on https://support.nagios.com/kb/article/n ... 7-860.html
RHEL 7 | CentOS 7 | Oracle Linux 7
rpm -Uvh http://rpms.remirepo.net/enterprise/remi-release-7.rpm
Quick google said it was only available in that repo https://access.redhat.com/discussions/4325631, but you see php-pecl-ssh2 just fine with your repo when you do a yum search?
RHEL 7 | CentOS 7 | Oracle Linux 7
rpm -Uvh http://rpms.remirepo.net/enterprise/remi-release-7.rpm
Quick google said it was only available in that repo https://access.redhat.com/discussions/4325631, but you see php-pecl-ssh2 just fine with your repo when you do a yum search?
Re: Scheduled Backups Page
HI,
The instructions I posted were for Centos8.
So you are looking for the remi repo for Centos7, is that right?
Thanks
The instructions I posted were for Centos8.
So you are looking for the remi repo for Centos7, is that right?
Thanks
Re: Scheduled Backups Page
Sorry no I am on RHEL 8. The Nagios PHP upgrade page has no instructions for RHEL 8, so I've had to assume some pieces. Part of what I was asking is if it's still expected to use that REMI repo in the RHEL 7 instructions since from what I could find php-pecl-ssh2 wasn't in the base repo's for RHEL 8 (At least on my end, but maybe sounds like you can see it available?)
Re: Scheduled Backups Page
Hi
I just upgraded 7.2 to 7.4 on Centos8.
Because of Centos8 EOL you'll need to run this:
Then:
dnf install https://dl.fedoraproject.org/pub/epel/e ... noarch.rpm
dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm
dnf module list php
Disable the 7.2 module that is enabled:
dnf module reset php:7.2
dnf module list php
dnf module enable php:remi-7.4
dnf 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
sed -i "s:;date.timezone =.*:date.timezone = ${PHPTZ}:" /etc/php.ini
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
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
Edit /etc/php.ini and add 'extension=ixed.7.4.lin' directive
Restart the server
shutdown -r now
Let me know how it works out for you.
Thank you
I just upgraded 7.2 to 7.4 on Centos8.
Because of Centos8 EOL you'll need to run this:
Code: Select all
mkdir /etc/yum.repos.d/old
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/old/
cat << \EOF > /etc/yum.repos.d/CentOS-vault.repo
[C8-BaseOS]
name=CentOS 8 - BaseOS
baseurl= https://vault.centos.org/8.5.2111/BaseOS/$basearch/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
[C8-AppStream]
name=CentOS 8 - AppStream
baseurl= https://vault.centos.org/8.5.2111/AppStream/$basearch/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
[powertools]
name=CentOS 8 - PowerTools
baseurl= https://vault.centos.org/8.5.2111/PowerTools/$basearch/os/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
enabled=1
metadata_expire=never
EOF
cat << \EOF > /etc/yum.repos.d/epel.repo
[epel]
name=Extra Packages for Enterprise Linux $releasever - $basearch
# It is much more secure to use the metalink, but if you wish to use a local mirror
# place its address here.
#baseurl= https://download.example/pub/epel/$releasever/Everything/$basearch
metalink= https://mirrors.fedoraproject.org/metalink?repo=epel-$releasever&arch=$basearch&infra=$infra&content=$contentdir
enabled=1
gpgcheck=0
countme=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-8
EOF
Then:
dnf install https://dl.fedoraproject.org/pub/epel/e ... noarch.rpm
dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm
dnf module list php
Disable the 7.2 module that is enabled:
dnf module reset php:7.2
dnf module list php
dnf module enable php:remi-7.4
dnf 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
sed -i "s:;date.timezone =.*:date.timezone = ${PHPTZ}:" /etc/php.ini
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
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
Edit /etc/php.ini and add 'extension=ixed.7.4.lin' directive
Code: Select all
;;;;;;;;;;;;;;;;;;;;;;
; Dynamic Extensions ;
;;;;;;;;;;;;;;;;;;;;;;
; If you wish to have an extension loaded automatically, use the following
; syntax:
;
; extension=modulename
;
; For example:
;
; extension=mysqli
;
; When the extension library to load is not located in the default extension
; directory, You may specify an absolute path to the library file:
;
; extension=/path/to/extension/mysqli.so
;
; Note : The syntax used in previous PHP versions ('extension=<ext>.so' and
; 'extension='php_<ext>.dll') is supported for legacy reasons and may be
; deprecated in a future PHP major version. So, when it is possible, please
; move to the new ('extension=<ext>) syntax.
;;;;
; Note: packaged extension modules are now loaded via the .ini files
; found in the directory /etc/php.d; these are loaded by default.
;;;;
; added for php 7.4
extension=ixed.7.4.lin
Restart the server
shutdown -r now
Let me know how it works out for you.
Thank you
Re: Scheduled Backups Page
Yep looks like what I figured out on my end, so glad I got that right. So seems like the REMI repo IS still needed. I'll need to work with my Unix team to get that allowed.
Just my recommendation but I think those instructions would be great to add support.nagios.com on that KB article for PHP upgrades. Definitely would have saved me time.
Just my recommendation but I think those instructions would be great to add support.nagios.com on that KB article for PHP upgrades. Definitely would have saved me time.
Re: Scheduled Backups Page
Hi,
Yes, I agree. I'll try t get it added ASAP.
Would you like to leave this thread unlocked until you complete the upgrade?
Thanks
Yes, I agree. I'll try t get it added ASAP.
Would you like to leave this thread unlocked until you complete the upgrade?
Thanks
Re: Scheduled Backups Page
Nope outside of that one area for the backups the upgrade went well, so I think I'm good. Thank you again.
Re: Scheduled Backups Page
Sounds great.
Thanks for letting me know.
Thanks for letting me know.