1

I recently upgraded a small server to Ubuntu 12.10 (from 12.04), thus upgrading PHP from 5.3 to 5.4. However, I'm getting this in root's mailbox several times a day:

Subject: Cron <root@xxxxxxx> [ -x /usr/lib/php5/maxlifetime ] && [ -d /var/lib/php5 ] && find /var/lib/php5/ -depth -mindepth 1 -maxdepth 1 -type f -ignore_readdir_race -cmin +$(/usr/lib/php5/maxlifetime) ! -execdir fuser -s {} 2>/dev/null \; -delete Content-Type: text/plain; charset=ANSI_X3.4-1968 X-Cron-Env: <SHELL=/bin/sh> X-Cron-Env: <HOME=/root> X-Cron-Env: <PATH=/usr/bin:/bin> X-Cron-Env: <LOGNAME=root> Message-Id: xxxxxxxxxxxxxxxxxxxxxxxx Date: Sun, 9 Dec 2012 05:09:02 -0500 (EST) Failed loading /usr/lib/php5/20090626+lfs/ioncube_loader_lin_5.3.so: /usr/lib/php5/20090626+lfs/ioncube_loader_lin_5.3.so: undefined symbol: php_body_write 

I assume that's coming up because it's for PHP 5.3. How can I just get rid of ioncube? I have no need for it, I don't even remember installing it. That .so file doesn't exist, and I've grep'd several locations for "ioncube" and I can't seem to figure how to stop that message from flooding the mailbox.

4 Answers 4

2

Usually there is a specific ioncube.ini file in the php conf.d directory

/etc/php5/conf.d/ioncube.ini 

Just remove this one and the warnings will stop.

1

dpkg-reconfigure php5-ioncube-loader solved it at my server

1
  • Keep in mind this solution means you will have to redo your configuration. Commented Jan 22, 2015 at 10:27
0

There should be a zend_extension line for it in your /etc/php.ini - remove that.

If it's not there, try locate php.ini. If you don't have locate (e.g. you didn't run updatedb yet), then use find / -name php.ini.

If that doesn't work, and you can get this error on the command line, strace it:

strace -f -e trace=open php /path/to/script.php 2>&1 

One of those will be a configuration file. If not (e.g. you see an open attempt for ioncube_*.so and none of the *.inis contain a line for it) then the chances are your PHP script is trying to dl() it.

7
  • There was no zend_extension in any of my php.ini's. In fact: root@xxxxxx:~# grep -r 'ioncube' /etc root@xxxxxx:~# grep -r 'zend_' /etc /etc/php5/fpm/php.ini.ucf-dist:;report_zend_debug = 0 /etc/php5/fpm/php.ini:;report_zend_debug = 0 /etc/php5/cli/php.ini:;report_zend_debug = 0 (edit: Ugh, I really wish pressing enter didn't submit comments) Commented Dec 9, 2012 at 10:59
  • I ran strace on both PHP scripts (Roundcube and Postfixadmin), and didn't get any zend or ioncube related .ini or .so files :\ - thanks for your help on this. Commented Dec 9, 2012 at 11:01
  • Perhaps it forks another process, can you try with strace -f ...? Commented Dec 9, 2012 at 11:04
  • Nope. Here's the output for both scripts if interested: pastebinr.com/24w Commented Dec 9, 2012 at 11:07
  • There's also no attempt to open ioncube_*so. When you run it under strace, does the error appear? If it does, 'lower' the strace to strace -f -e trace=file (or even strace -f e -trace=all if that doesn't help). Commented Dec 9, 2012 at 11:09
0

Under /etc/php.d/ folder there must be ioncube.ini file usually looks like 20-ioncube.ini, you can remove this file and try to reinstall the ioncube loader using yum install php-ioncube-loader

You must log in to answer this question.