Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Php-json

Discussion in 'General Discussion' started by gahelm, Sep 21, 2006.

  1. gahelm

    gahelm Active Member

    Joined:
    Jun 21, 2003
    Messages:
    37
    Likes Received:
    0
    Trophy Points:
    156
    Location:
    Florida
    I have deployed a very complex CRM web based application for one of my clients. It works well although somewhat slow, in reading it's manual it discusses the need to implement PHP-JSON in order to significantly speed up the application. I tried to install that via PEAR and then was re-directed to PECL, however PECL fails when it attempts to run the size command. Here is it's output;

    # pecl install json
    downloading json-1.2.1.tgz ...
    Starting to download json-1.2.1.tgz (17,780 bytes)
    ......done: 17,780 bytes
    11 source files, building
    running: phpize
    Configuring for:
    PHP Api Version: 20020918
    Zend Module Api No: 20020429
    Zend Extension Api No: 20050606
    /usr/local/bin/phpize: /tmp/tmpSgFQPK/json-1.2.1/build/shtool: /bin/sh: bad interpreter: Permission denied
    Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF
    environment variable is set correctly and then rerun this script.

    ERROR: `phpize' failed


    Any help here would be appreciated!

    Forgot to mention that I am running PHP 4.4.4
     
    #1 gahelm, Sep 21, 2006
    Last edited: Sep 21, 2006
  2. rhenderson

    rhenderson Well-Known Member

    Joined:
    Apr 21, 2005
    Messages:
    785
    Likes Received:
    1
    Trophy Points:
    166
    Location:
    Oklahoma
    cPanel Access Level:
    Root Administrator
    My guess would be /tmp being mounted as nonexec.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. nettigritty

    nettigritty Well-Known Member
    PartnerNOC

    Joined:
    Jan 21, 2004
    Messages:
    192
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Bangalore, India
    1. Login to SSH
    2. Make tmp and var/tmp exec

    mount -v -o remount,exec /tmp
    mount -v -o remount,exec /var/tmp

    3. No go ahead and install JSON

    pecl install json

    4 . And finally, make tmp and var/tmp noexec again

    mount -v -o remount,noexec /tmp
    mount -v -o remount,noexec /var/tmp
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. rhenderson

    rhenderson Well-Known Member

    Joined:
    Apr 21, 2005
    Messages:
    785
    Likes Received:
    1
    Trophy Points:
    166
    Location:
    Oklahoma
    cPanel Access Level:
    Root Administrator
    When we installed json instead of mounting and unmounting, we just downloaded the source, do a ./configure, make, make install then copied the json.so over to our php extensions directrory. Seemed easier at the time.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. nettigritty

    nettigritty Well-Known Member
    PartnerNOC

    Joined:
    Jan 21, 2004
    Messages:
    192
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Bangalore, India
    yup, you can do that. this was just to overcome the /tmp issue when using a pecl install for anything.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice