5

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.

5 Answers 5

3

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.

2
  • 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, 2013 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, 2013 at 19:29
2

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

1
  • 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 Oct 26, 2013 at 18:01
2

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.

1
  • This also solved my problem with v5.5.6
    – edigu
    Feb 9, 2015 at 17:08
0

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?

4
  • How would the missing libraries be listed? libgd version: php-gd-5.5.1-1.el6.remi.x86_64
    – eisaacson
    Aug 12, 2013 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? Aug 12, 2013 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, 2013 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). Aug 13, 2013 at 2:45
0

In my case after update from remi-php56 repo the solution was to delete old gdlib.so files from /usr/lib, /usr/lib64 and /usr/local/lib. Check forum message

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .