This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit

eZ Community » Forums » Install & configuration » Cronjob failure

Cronjob failure

Cronjob failure

Sunday 16 December 2007 1:39:22 pm - 7 replies

Trying to set up cronjobs to allow notification settings etc to work on eZP 4Alpha2 and not managing.

Server is running PHP 5.1.6-3.4.fc6, MySQl 5.0.27-1.fc6 and Apache 2 (in prefork mode)

When running runcronjobs.php through the PHP CLI manually from the directory with runcronjobs.php in it by typing the following at the command line:

 /usr/bin/php -C runcronjobs.php

I get the following error messages:

PHP Warning:  in_array(): Wrong datatype for second argument in /var/www/vhosts/                on line 1055
Error initializing script: database error: No database handler was found for ''.

the PHP Warning line repeats 5 times - looking at the code it's part of the debug functionality which is looping through an array (or so it seems to me).

I get the same messages when using the -q -s site_access_name 2>&1 as well

site.ini and cronjob.ini are pretty much as initially installed.

I'm not very experienced with CLI or cron so I may be doing something stupid.....

Wondering whether it's a bug and I need to upgrade to ezP 4.0 proper (and not sure how to do that if that's the case).

Help hugely appreciated!

Modified on Sunday 16 December 2007 9:55:04 pm by Mark Emms

Sunday 16 December 2007 10:34:30 pm

Hi Mark

eZ Publish 4.0.0 stable was recently released, so better to use this than alpha2 in the first place. But seems like this bug will be fixed in 4.0.1:

Monday 17 December 2007 11:50:59 am

Many, many thanks Kristof - you may have saved me hours of work there!

Is there a way of knowing (or getting some idea of) how long it is until future releases come out?

I have a client who is very keen to have this up and running - and if I can give an indication of days/weeks/months then I can keep them happyish!

Monday 17 December 2007 12:16:47 pm

4.0.1 is expected to be there in January. In the meantime, you can use it from svn maybe?
I didn't notice the second warning you got when I was replying you the first time: "Error initializing script: database error: No database handler was found for ''. Rather strange. I would inspect your [DatabaseSettings] block in all site.ini.append(.php) setting files.

Monday 17 December 2007 12:38:03 pm

Yes - I looked using the admin interface at site.ini and all seemed OK - will check all of them now by ftp.


Monday 17 December 2007 12:55:06 pm

OK. Have had a look. Have got the following in all of them:


also through the admin interface I have

DatabasePluginPath default ""

All content works fine so the connection to the database must be correctly set up.

I'm totally stumped!

Have tried specifying the site access using the -s siteaccessname too but get the same result.

Tuesday 18 December 2007 6:19:06 pm

I've tried a number of different versions of ezscript.php from the svn (perhaps not the right one - sorry don't know my way around yet!). All give the same error message (but on different line numbers obviously).

Which version were you suggesting I tried?

Wednesday 19 December 2007 3:31:02 pm

It turned out that safe_mode was on for php cli. The INI system uses file_exists() to check if an INI file is there, but this doesn't work when safe mode is on and will return false.


You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from