in the
Linux
Serverdeployment in the environmentSSH2extension to compilePHPin the fileSSHscript commands, the specific configuration method is as follows, if it is in a formal environment to run directly, it is recommended to do backup.
1. Installing the supported library files
command: Yum Install php-devel php-pear libssh2 libssh2-devel
2. build ssh2 Extensions
command: pecl install-f ssh2
After that, the installed log will be displayed, and you will need to press ENTER directly when selecting.
3. After the installation is successful, you need to modify Ssh2.ini
[Email protected] etc]# Touch/etc/php.d/ssh2.ini
[Email protected] etc]# echo extension=ssh2.so >/etc/php.d/ssh2.ini
can be used Vim Open /etc/php.d/ssh2.ini confirm that you have included extension=ssh2.so
4. Verify that the installation is successful
php-m | grep SSH2
Show SSH2 indicates that the installation was successful
SSH2 extended installation and basic Operation Linux System learning