|
Posted by Jeremy on 01/08/08 19:47
Franz Von Bayros wrote:
> Hello all.
>
> I have some PHP scripts run by cron that email me all day for no good
> reason. The scripts are outputting warnings like:
>
> PHP Warning: Module 'mysql' already loaded in Unknown on line 0
> PHP Warning: Module 'gd' already loaded in Unknown on line 0
> PHP Warning: Module 'zlib' already loaded in Unknown on line 0
>
>
> The environment is PHP 5.1.2 (cli) under FreeBSD.
>
> The jobs are called like so:
>
> 0,15,30,45 * * * * /usr/local/bin/php -f /www/subsites/whatever/
> htdocs/syncher.php
>
> Though I have also tried this using the -q flag instaed of -f.
>
> Any thoughts on suppressing this?
>
> There doesn't seem to be a flag for it here:
>
> http://us2.php.net/manual/en/features.commandline.php
>
> TIA for any help!!!
>
> FvB
I would try to figure out why PHP is attempting to load those extensions
twice. It's always better to fix problems than to suppress their symptoms.
If your PHP setup is like mine (which it may well not be), you might
find that you have multiple php.(conf|ini) files - separate for apache
and cli - and a set of individual extension config files that are shared
between both, located in a php.d (or similar) directory. If the modules
are being loaded in the php.conf file as well as in an individual config
file under php.d, the problem could be corrected by removing the
`extension=XXX.so` lines from the main config file.
Jeremy
[Back to original message]
|