Menu

SSH2 Modules "Not Available" Centos 7.5

sysadmin
2018-11-07
2018-11-08
  • sysadmin

    sysadmin - 2018-11-07

    Good afternoon,

    I got nagios 4.3.4-5 installed but when going through the nagiosql requirements, it fails to detect the SSH2.so module. I have been following your pdf.
    I have php5.4 (nagios dependency) and 5.5 (from SCL). If I reinstall nagios, it will reinstall php5.4 then the ssh2 check will pass but the php5.5 will fail. So I copy back the php.conf files from php55 and ssh2 fails again.

    Running php -m I get that ssh2 is enabled.

    Has anyone found a solution for this?

    Regards

     

    Last edit: sysadmin 2018-11-07
  • Martin

    Martin - 2018-11-07

    SSH2 is an extension that should defined in your php.ini which is used by apache. You have to restart apache after each change before test. Check that the extension (ssh2.so) linked in php.ini will exist in your filesystem.

    Sometimes php 5.4 and php 5.5 uses different php.ini. You can check the path with:
    # php -i | grep php.ini

    Sometimes there are different php.ini for cli and apache, too.

     
  • sysadmin

    sysadmin - 2018-11-08

    Thanks Martin. That pointed me to the right direction.

    Php -iwas calling/usr/bin/phpwhich is 5.4. The actual binary I needed for php55 was in /opt/rh/php55/root/bin. From there I installed gcc and run./pecl install ssh2, then I added the file ssh2.ini to/opt/rh/php55/root/etc/php.d/ with the extension /opt/rh/php55/root/usr/lib64/php/modules/ssh2.so.

    I hope that helps and thanks again!

     

Log in to post a comment.