PHP: libcurl.so.4 missing in jailshell

Patiek

Active Member
May 23, 2003
36
0
156
After recently upgrading PHP to 5.24 and Apache to 2.2, I am experiencing a problem when attempting to call PHP from a jailshell:
# php test.php
php: error while loading shared libraries: libcurl.so.4: cannot open shared object file: No such file or directory
The jailshell does not appear to include /opt/curlssl/libcurl.so.4 shared library link that PHP is compiled with ('--with-curl=/opt/curlssl/').

Now, I believe I can fix this for the current users, but I would like to ensure that new accounts will also have access. How can I go about repairing this problem permanently (or is this a cpanel bug that needs to be looked at)?
 

mtindor

Well-Known Member
Sep 14, 2004
1,463
114
193
inside a catfish
cPanel Access Level
Root Administrator
I never noticed that to be a problem - but for curiosity's sake I did this from a shell:

/usr/local/bin/php test.php
/usr/local/bin/php: error while loading shared libraries: libmcrypt.so.4: cannot open shared object file: No such file or directory

/usr/bin/php test.php
/usr/bin/php: error while loading shared libraries: libmcrypt.so.4: cannot open shared object file: No such file or directory

My libcurl is in /usr/lib and my mcrypt is in /opt/libmcrypt/lib. So I'm guessing it doesn't see anything in /opt. I'm not sure it makes any difference - even though I get those errors, mcrypt shows up in phpinfo on my site.

Mike
 

bamm

Well-Known Member
Feb 24, 2003
75
0
156
any solution for this?

can you explain how you fixed it for your current accounts?

Thanks a bunches for any advice.
 

ManXP

Well-Known Member
Feb 3, 2005
62
0
156
Anby update on this? Our servers have same problem too, so php scripts could not be launched from command line anymore
 

Patiek

Active Member
May 23, 2003
36
0
156
cPanel really needs a fix for this as it breaks all PHP command line (that includes cron, etc) that MANY, MANY scripts rely on.

You can fix a particular site:
mkdir /home/virtfs/username/opt
mount -o bind,ro /opt /home/virtfs/username/opt

...replacing username with site's username. Changes will revert on reboot.
 

Todd Mitchell

Well-Known Member
Staff member
Nov 13, 2006
301
1
243
Houston, TX
As barwin stated, if you are in need of a fix for this, please vote for the bug at http://bugzilla.cpanel.net/show_bug.cgi?id=6043

You can also add your email to the bug in order to receive any updates to the bug if needed. Currently, there isn't much activity on the bug and the more you vote for it or show a need for this to be fixed the more attention the develoeprs will give to that particular bug.