Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

We're running RHEL6 and just started getting this error when restarting php-fpm.

PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/gd.so' - /usr/lib64/php/modules/gd.so: undefined symbol: gdImageWebpCtx in Unknown

I've tried restarting the server and running yum update but haven't gotten rid of the error. Any help would be appreciated.

share|improve this question

4 Answers 4

up vote 2 down vote accepted

This means, that gdImageWebpCtx symbol cannot be found in shared libraries used by the module. gdImageWebpCtx is provided by gd/libgd (not php-gd).

readelf -s /usr/lib64/libgd.so.2

and

nm -D /usr/lib64/libgd.so.2

will list symbols and I'm very sure, that you won't find it there.

I had dozens of similar/compatibility problems with packages provided by Remi Collet (looks like he's very busy to maintain everything et cetera).

Remove all remi packages (rpm -qa|grep remi), delete remi-release package and install last available php/gg/etc packages from EPEL repository (you may need to downgrade them with rpm -Uvh package.rpm --oldversion). Then upgrade all packages (!).

If you want to have php 5.5, then I recommend you to download src.rpm's from remi's repo, install src.rpm and recompile with rpmbuild --target x86_64 -ba /root/rpmbuild/SPECS/php.spec . This way all binaries will be built according to your system.

That's the reason why I never use REMI's php rpms. Mysql ones are good.

share|improve this answer
    
Thank you. Could you walk me through or point me to some instructions for what you're talking about here: "Remove all remi packages (rpm -qa|grep remi), delete remi-release package and install last available php/gg/etc packages from EPEL repository (you may need to downgrade them with rpm -Uvh package.rpm --oldversion). Then upgrade all packages (!)." –  eisaacson Aug 13 '13 at 14:40
1  
you can delete package with "yum remove [package names]", i cant give you exact commands if you will list all your remi packages with "rpm -qa|grep remi", and then you will need to enter few more commands for futher steps –  GioMac Aug 14 '13 at 19:29

I've updated gd-last to latest version and it resolve my issue with remi packages.

share|improve this answer
    
I was using remi-test and tried: yum --disablerepo=* --enablerepo=remi-test upgrade gd-last No Packages marked for Update which didn't have any packages to upgrade, however then I realized you meant remi, not remi-test and that worked: yum --disablerepo=* --enablerepo=remi upgrade gd-last –  Gorilla3D Oct 26 '13 at 18:01

That's a linker failure. It looks like you may not have the gd library installed (or more likely that you have an incorrect version of the library installed).

Does ldd /usr/lib64/php/modules/gd.so report any missing libraries? (I don't expect it will.)

What version of libgd do you have installed?

share|improve this answer
    
How would the missing libraries be listed? libgd version: php-gd-5.5.1-1.el6.remi.x86_64 –  eisaacson Aug 12 '13 at 22:20
    
They would list without paths (and with a message about the library being missing) instead of listing the path to the library. But as I said it is more likely that you simply have a version of the library without that function in it. Where did you get libgd and php (or that php module) from? –  Etan Reisner Aug 12 '13 at 22:31
    
Nothing showed as missing then. Here's the url I used when installing php, php-fpm, and php-common: mirror-fpt-telecom.fpt.net/fedora/epel/6/i386/… –  eisaacson Aug 12 '13 at 22:49
    
That RPM installs the EPEL6 repository configuration. That php package does not come from there (and as far as I can tell EPEL6 does not have a php-gd package). As @GioMac indicated in his answer you are using a "remi" package (whatever that is) and it quite likely was built poorly and doesn't have the correct versioned dependency on the gd library (so you have the library but not the correct symbol, as it seems that symbol is fairly recent). –  Etan Reisner Aug 13 '13 at 2:45

I also just needed gd-last.

sudo yum --enablerepo=epel,remi,remi-php55 install gd-last

Worked for me with php 5.5.7 and REMI Repository. I previously had the same error.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.