Hi, this is weird. After a general upgrade to Ubuntu 12.04 (and of all the installed packages), the ssh2 library is loaded just fine, but the wrappers ssh2.sftp, ssh2.exec, etc. are loaded only when PHP is run via Apache, not via CLI.
I don't know it if is a bug of Zend Server, PHP or ssh2 library, but since I have the libraries php-5.3-sockets-zend-server (5.3.9+b260) and php-5.3-ssh2-zend-server (5.3.9+b260) installed...
On my system there are also libssh2-php (0.11.2-1) and libssh2-1-dev (1.2.8-2)
On phpinfo, both on CLI and Apache, it returns SSH2 extension version 0.11.3-dev and libssh2 version 1.4.1 and banner SSH-2.0-libssh2_1.4.1
Again, everything worked fine before the upgrade of the zend libraries (Ubuntu upgrade was after that, as an attempt to solve the problem). After the upgrade, library is loaded but wrappers are not registered in the CLI, so I guess it's a bug of Zend Server.
Apache:
Registered PHP Streams => https, ftps, compress.zlib, php, file, glob, data, http, ftp, compress.bzip2, phar, ssh2.shell, ssh2.exec, ssh2.tunnel, ssh2.scp, ssh2.sftp, zip
Registered Stream Socket Transports => tcp, udp, unix, udg, ssl, sslv3, sslv2, tls
Registered Stream Filters => zlib.*, convert.iconv.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk, bzip2.*, mcrypt.*, mdecrypt.*
CLI:
Registered PHP Streams => https, ftps, compress.zlib, compress.bzip2, php, file, glob, data, http, ftp, phar, zip
Registered Stream Socket Transports => tcp, udp, unix, udg, ssl, sslv3, tls
Registered Stream Filters => zlib.*, bzip2.*, convert.iconv.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk, mcrypt.*, mdecrypt.*

