Install Datastax Cassandra PHP Extension in Ubuntu ( Part 4 )



                                                   

Step 1 : Install Dependencies

        sudo apt-get install g++ make cmake libuv-dev libssl-dev libgmp-dev  php5-dev openssl libpcre3-dev


Step 2 : Install cpp-drivers as per your requirement from the link :
              http://downloads.datastax.com/cpp-driver/ubuntu/


        # sudo apt-get install php-config  //to solve cpp driver version issue with php

        dpkg -i libuv_1.8.0-1_amd64.deb
        dpkg -i libuv-dbg_1.8.0-1_amd64.deb
        dpkg -i libuv-dev_1.8.0-1_amd64.deb
        dpkg -i cassandra-cpp-driver_2.4.2-1_amd64.deb
        dpkg -i cassandra-cpp-driver-dbg_2.4.2-1_amd64.deb
        dpkg -i cassandra-cpp-driver-dev_2.4.2-1_amd64.deb


Step 3 : Build Datastax C/C++ Driver.

       git clone https://github.com/datastax/cpp-driver.git
       mkdir cpp-driver/build
       cd cpp-driver/build
       cmake ..
       make install

Step 4 : Install the PHP extension

       git clone https://github.com/datastax/php-driver.git
       cd php-driver
       git submodule update --init
       cd ext
       ./install.sh

       phpize
      ./configure
       make install


Step 5 : Enable the PHP extension

Then edited t php configuration file ../fpm/php.ini and ../cli/php.ini to add in : extension=cassandra.so

         echo -e "; DataStax PHP Driver\nextension=cassandra.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`

Comments

Popular posts from this blog

Datastax Error : Cannot start node if snitch's data center (dc1) differs from previous data center (dc2)

Datastax Error : Cassandra - Saved cluster name Test Cluster != configured name

Configure Nagios plugin " check_logfiles " for scanning log file

Popular posts from this blog

Datastax Error : Cannot start node if snitch's data center (dc1) differs from previous data center (dc2)

Datastax Error : Cassandra - Saved cluster name Test Cluster != configured name

Configure Nagios plugin " check_logfiles " for scanning log file