Date: Thu, 26 Aug 2010 16:37:07 +0200 From: =?ISO-8859-1?Q?Morgan_Wesstr=F6m?= <freebsd-ports@pp.dyndns.biz> To: "freebsd-ports@freebsd.org" <freebsd-ports@freebsd.org> Cc: Jeremy Chadwick <freebsd@jdc.parodius.com>, ale@freebsd.org Subject: Re: PHP warning after 5.3.3 -> 5.3.3_1 bump Message-ID: <4C767C13.2060306@pp.dyndns.biz> In-Reply-To: <20100826132220.GA90224@icarus.home.lan> References: <4C76599F.3090000@pp.dyndns.biz> <4C766106.7050008@FreeBSD.org> <20100826132220.GA90224@icarus.home.lan>
next in thread | previous in thread | raw e-mail | index | archive | help
>>> Upgraded lang/php from port revision 5.3.3 to 5.3.3_1 yesterday to >>> include the new native MySQL drivers. Now I get the following warning >>> every time a php script is executed: >>> >>> PHP Warning: Module 'zlib' already loaded in Unknown on line 0 >>> >>> Even a simple "php -v" displays this warning. >>> >>> - I have rebuilt php and all ports depending on it. >>> - I have verified that extensions.ini doesn't contain duplicates. >>> - I have searched for any other references to zlib. >>> >>> This isn't critical I guess, but annoying. Any suggestions on how to >>> solve this would be appreciated. >>> >>> Regards >>> Morgan >> >> Hi Morgan, >> >> The only time that I've seen that error, it has been caused by duplicate >> extension loading. If you've already removed duplicates from your >> extensions.ini file, set up a page with the phpinfo() function so you >> can see what other .ini file directories might be in the search path. The output from phpinfo is listed below and shows no traces of other ini-files than the default. Configuration File (php.ini) Path /usr/local/etc Loaded Configuration File /usr/local/etc/php.ini Scan this dir for additional .ini files /usr/local/etc/php Additional .ini files parsed /usr/local/etc/php/extensions.ini >> You might even get some good information from this command: >> >> truss -f -a -s 256 -o /tmp/php-cli.log php -v >> >> Once the process exits, check the /tmp/php-cli.log file and search for >> "zlib" in it. You might see the zlib extension loaded more than once >> and be able to determine what .ini file is causing the duplication. It only seems to be loaded once. # grep -E 'ini|zlib' /tmp/php-cli.log 11897: open("/usr/local/bin/php-cli.ini",O_RDONLY,0666) ERR#2 'No such file or directory' 11897: open("/usr/local/etc/php-cli.ini",O_RDONLY,0666) ERR#2 'No such file or directory' 11897: open("/usr/local/bin/php.ini",O_RDONLY,0666) ERR#2 'No such file or directory' 11897: open("/usr/local/etc/php.ini",O_RDONLY,0666) = 3 (0x3) 11897: lstat("/usr/local/etc/php.ini",{ mode=-r--r--r-- ,inode=14156568,size=46214,blksize=16384 }) = 0 (0x0) 11897: stat("/usr/local/etc/php/extensions.ini",{ mode=-rw-r--r-- ,inode=19524774,size=922,blksize=16384 }) = 0 (0x0) 11897: open("/usr/local/etc/php/extensions.ini",O_RDONLY,0666) = 3 (0x3) 11897: open("/usr/local/lib/php/20090626/zlib.so",O_RDONLY,044) = 3 (0x3) 11897: write(3,"[26-Aug-2010 16:28:27] PHP Warning: Module 'zlib' already loaded in Unknown on line 0\n",87) = 87 (0x57) > If this is true, then extension=zlib.so would be considered "redundant" > and cause the warning seen. You could test the validity of my claim by > commenting out (using semi-colon) extension=zlib.so in extensions.ini > and then use php -i and see if zlib is listed as a loaded extension. > You are correct Jeremy. Commenting out zlib.so removes the warning and zlib still shows up as a loaded module when I do php -i. Can I provide any further tests or information for you? Regards Morgan
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4C767C13.2060306>