Cron Job error Windows open_basedir restriction

Ask your questions regarding TimeTrex installation here.
Locked
Walle
Posts: 2
Joined: Tue Jan 15, 2013 10:16 pm

Cron Job error Windows open_basedir restriction

Post by Walle »

I am new to TimeTrex - it seems like Cron Job is working but I get this error in my PHP logs.

[15-Jan-2013 23:36:00 America/New_York] PHP Warning: is_executable(): open_basedir restriction in effect. File(C:\progra~1\php\php.exe) is not within the allowed path(s): (C:\www\timetrex;) in C:\www\timetrex\classes\modules\cron\CronJobFactory.class.php on line 373

Any ideas?

I created the schedule task from cmd.exe in Windows 2003 server:

schtasks /create /tn "TimeTrex Scheduled Jobs" /tr "php-win.exe C:\www\timetrex\maint\cron.php" /sc minute

Thank you.
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: Cron Job error Windows open_basedir restriction

Post by shaunw »

You will need to disable open_basedir in your php.ini file, or allow it to run C:\progra~1\php\php.exe
Walle
Posts: 2
Joined: Tue Jan 15, 2013 10:16 pm

Re: Cron Job error Windows open_basedir restriction

Post by Walle »

Why?

I have scheduled a Cron job through the OS with php-win.exe C:\www\timetrex\maint\cron.php

What does this have to do with:

C:\progra~1\php\php.exe ?

OR my open_basedir restrictions ?

Is this a PHP flaw... Or programmer error...

Thanks, Doug
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: Cron Job error Windows open_basedir restriction

Post by shaunw »

The TimeTrex maintenance jobs need to execute PHP to run each job itself, but the way you have PHP setup its preventing that from happening.
Locked