How to Install RdKafka with PHP

Step 1: Download Libary of RdKafka from below link

https://launchpadlibrarian.net/329894498/librdkafka_0.11.0.orig.tar.gz

then un-tar it

cd linrdkafka-0.11.0

execute the commands

step 2: ./configure –prefix/usr/

Step 3: make

Step 4: make install

Step 5: ldconfig (This is very important step otherwise rdkafka will not execute with PHP)

Step 6: pecl install rdkafka

Step 7:  vi /etc/php.ini

add following: extension=rdkafka.so

Step 8: check rdkafka installed properly with PHP

command: php -v

Step 9: If there is not error in step 8 then reload the Apache / Nginx whatever you have.

 

 

 

 

 

Comments are closed.