PHP ssh2 Extension Installation

Source: Internet
Author: User

Toss half a day, the conclusion is as follows:

1. You need OpenSSL first

Use which OpenSSL to see if it is installed

2. Then LIBSSH2

View with RPM-QL Libssh2

3. Download the source shh2x.x.x.tgz package

4. Unpack and enter and then use the Phpize command

$ CD ssh2x.x.x

$ phpize

$./configure--with-php-config=/usr/local/php5/bin/php-config-----(php-config path, can be found with Find/-name php-config)

$make && make Install

5. Add ssh2 Extension in PHP

$vim/usr/local/php5/php.ini

Add this line

extension=/usr/local/php5/lib/php/extensions/no-debug-non-zts-20060613/ssh2.so-----(ssh2.so path, can also be found with find)

Then restart the Apache server

Then go to the PHP test page to view

PHP ssh2 Extension Installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.