php sockets扩展安装

今天安装cacti发现需要php sockets扩展,而现在的lnmp没有安装,于是想到了phpize工具安装扩展,安装方法如下:

  1. cd php-5.3.8/ext/sockets/
  2. /usr/local/php/bin/phpize
  3. ./configure --enable-sockets --with-php-config=/usr/local/php/bin/php-config
  4. make
  5. make install

接着在/etc/php.ini添加加载扩展代码:

  1. extension=sockets.so

service php-fpm reload或service httpd reload

标签:PHPSocket 发布于:2019-11-24 10:38:29