安装swoole

php需要安装swoole扩展 swoole4.3.2 

    cd /usr/local/src/
    wget https://pecl.php.net/get/swoole-4.3.2.tgz
    tar -zxvf swoole-4.3.2.tgz
    mv swoole-4.3.2 swoole
    cd swoole
    /usr/local/php/bin/phpize
    # 增加php配置
    ./configure --enable-openssl --enable-swoole --enable-http2 --enable-sockets --with-php-config=/usr/local/php/bin/php-config
    make && make install

    # 给php开启swoole扩展
    vim /usr/local/php/etc/php.ini

    # 增加 extension = swoole.so

    /etc/init.d/php-fpm restart

 

posted on 2019-04-25 15:21  薇薇123456  阅读(188)  评论(0编辑  收藏  举报

导航