• Howdy! Welcome to our community of more than 130.000 members devoted to web hosting. This is a great place to get special offers from web hosts and post your own requests or ads. To start posting sign up here. Cheers! /Peo, FreeWebSpace.net
managed wordpress hosting

SSH2 + php 5.4

Hamed

Active Member
Hello,

I am new user of directadmin (Web host control panel)

Now I want to install ssh2 in my server.

I follow this http://blog.treehost.in.th/2011/12/01/php-ssh2/

Now I get this error:

PHP Warning: PHP Startup: ssh2: Unable to initialize module
Module compiled with module API=20090626
PHP compiled with module API=20100525
These options need to match
in Unknown on line 0



How can I fix this problem?
 
CentOS release 6.5 (Final)
Linux server 2.6.32-431.5.1.el6.i686 #1 SMP Tue Feb 11 21:56:33 UTC 2014 i686 i686 i386 GNU/Linux
 
The module has been compiled for 5.3 and you are trying to load in 5.4

It is likely the case that you have two installations of php on your system, when you configure the pecl module you must pass the configuration option

--with-php-config=/path/to/php-config

/path/to/php-config should be the correct path the the php-config script that was installed for your 5.4 installation.

It's often the case with control panels that they do install more than one copy of the interpreter, one to service the panels internals and another to service clients.

Another common cause of two installations is having one in /usr/local and one in /usr; /usr/local is the default prefix but nearly all package maintainers configure prefix /usr.

Search your filesystem for php binaries:

Code:
[joe@fiji php-src]$ find / -name php 2>/dev/null
/opt/bin/php
/opt/include/php
/opt/php
/opt/php/5.5.11/no-zts/debug/bin/php
/opt/php/5.5.11/no-zts/debug/include/php
/opt/php/5.5.11/no-zts/debug/php
/opt/php/5.5.11/no-zts/debug/lib/php
/opt/php/5.5.11/no-zts/no-debug/bin/php
/opt/php/5.5.11/no-zts/no-debug/include/php
/opt/php/5.5.11/no-zts/no-debug/php
/opt/php/5.5.11/no-zts/no-debug/lib/php
/opt/php/5.5.11/zts/debug/bin/php
/opt/php/5.5.11/zts/debug/include/php
/opt/php/5.5.11/zts/debug/php
/opt/php/5.5.11/zts/debug/lib/php
/opt/php/5.5.11/zts/no-debug/bin/php
/opt/php/5.5.11/zts/no-debug/include/php
/opt/php/5.5.11/zts/no-debug/php
/opt/php/5.5.11/zts/no-debug/lib/php
/opt/php/5.6/no-zts/debug/bin/php
/opt/php/5.6/no-zts/debug/include/php
/opt/php/5.6/no-zts/debug/php
/opt/php/5.6/no-zts/debug/lib/php
/opt/php/5.6/no-zts/no-debug/bin/php
/opt/php/5.6/no-zts/no-debug/include/php
/opt/php/5.6/no-zts/no-debug/php
/opt/php/5.6/no-zts/no-debug/lib/php
/opt/php/5.6/zts/debug/bin/php
/opt/php/5.6/zts/debug/include/php
/opt/php/5.6/zts/debug/php
/opt/php/5.6/zts/debug/lib/php
/opt/php/5.6/zts/no-debug/bin/php
/opt/php/5.6/zts/no-debug/include/php
/opt/php/5.6/zts/no-debug/php
/opt/php/5.6/zts/no-debug/lib/php
/opt/php/master/no-zts/debug/bin/php
/opt/php/master/no-zts/debug/include/php
/opt/php/master/no-zts/debug/php
/opt/php/master/no-zts/debug/lib/php
/opt/php/master/no-zts/no-debug/bin/php
/opt/php/master/no-zts/no-debug/include/php
/opt/php/master/no-zts/no-debug/php
/opt/php/master/no-zts/no-debug/lib/php
/opt/php/master/zts/debug/bin/php
/opt/php/master/zts/debug/include/php
/opt/php/master/zts/debug/php
/opt/php/master/zts/debug/lib/php
/opt/php/master/zts/no-debug/bin/php
/opt/php/master/zts/no-debug/include/php
/opt/php/master/zts/no-debug/php
/opt/php/master/zts/no-debug/lib/php
/opt/php/5.5.7/no-zts/debug/bin/php
/opt/php/5.5.7/no-zts/debug/include/php
/opt/php/5.5.7/no-zts/debug/php
/opt/php/5.5.7/no-zts/debug/lib/php
/opt/php/5.5.7/no-zts/no-debug/bin/php
/opt/php/5.5.7/no-zts/no-debug/include/php
/opt/php/5.5.7/no-zts/no-debug/php
/opt/php/5.5.7/no-zts/no-debug/lib/php
/opt/php/5.5.7/zts/debug/bin/php
/opt/php/5.5.7/zts/debug/include/php
/opt/php/5.5.7/zts/debug/php
/opt/php/5.5.7/zts/debug/lib/php
/opt/php/5.5.7/zts/no-debug/bin/php
/opt/php/5.5.7/zts/no-debug/include/php
/opt/php/5.5.7/zts/no-debug/php
/opt/php/5.5.7/zts/no-debug/lib/php
/opt/php/5.5.9/no-zts/debug/bin/php
/opt/php/5.5.9/no-zts/debug/include/php
/opt/php/5.5.9/no-zts/debug/php
/opt/php/5.5.9/no-zts/debug/lib/php
/opt/php/5.5.9/no-zts/no-debug/bin/php
/opt/php/5.5.9/no-zts/no-debug/include/php
/opt/php/5.5.9/no-zts/no-debug/php
/opt/php/5.5.9/no-zts/no-debug/lib/php
/opt/php/5.5.9/zts/debug/bin/php
/opt/php/5.5.9/zts/debug/include/php
/opt/php/5.5.9/zts/debug/php
/opt/php/5.5.9/zts/debug/lib/php
/opt/php/5.5.9/zts/no-debug/bin/php
/opt/php/5.5.9/zts/no-debug/include/php
/opt/php/5.5.9/zts/no-debug/php
/opt/php/5.5.9/zts/no-debug/lib/php
/opt/lib/php
/usr/src/php-5.3.27/sapi/cli/php
/usr/src/php-5.4.25/sapi/cli/php
/usr/src/php-src/sapi/cli/php
/usr/src/suck/php-build/5.5.11/sapi/cli/php
/usr/src/suck/php-build/5.6/sapi/cli/php
/usr/src/suck/php-build/master/sapi/cli/php
/usr/src/suck/php-build/5.5.7/sapi/cli/php
/usr/src/suck/php-build/5.5.9/sapi/cli/php
/usr/local/bin/php

If you do only have two installations, then count yourself lucky :D
 
Last edited:
Back
Top