1.安装librdkafka
wget https://frame.usualtool.com/down/soft/librdkafka.zip
unzip librdkafka.zip
cd librdkafka
./configure
make && make install
2.编译rdkafka
wget https://frame.usualtool.com/down/soft/php-rdkafka.zip
unzip php-rdkafka.zip
cd php-rdkafka
/www/server/php/74/bin/phpize
./configure --with-php-config=/www/server/php/74/bin/php-config --with-rdkafka
make all -j 5
make install
php.ini 增加扩展:extension = rdkafka.so
重启Nginx
重启php-fpm