Cron Job php with '.....' in the ending

Discussion in 'Installation/Configuration' started by Imam86, Sep 24, 2012.

  1. Imam86

    Imam86 New Member

    Hello.. I'd like to ask about php cron job with '....' in the ending.

    30 * * * * php -q /var/www/clients/client5/web5/web/billing/services.php 'mailer'


    I'm using Debian Squeeze, with ISPConfig 3.0.4.6
    And from this tutorial: http://www.howtoforge.com/perfect-server-debian-squeeze-with-bind-and-dovecot-ispconfig-3

    I configured like this:

    Client Limits
    --------------

    Code:
    Max. number of Shell users : 0
    Allowed Cronjob : Chrooted Cron
    Cron Job
    ----------

    Code:
    Command to run: https://example.com/billing/services.php 'mailer'
    Code:
    [email protected]:~# ls -la /etc/cron.d
    total 40
    drwxr-xr-x   2 root root 4096 Sep 23 14:35 .
    drwxr-xr-x 105 root root 4096 Sep 23 14:32 ..
    -rw-r--r--   1 root root  179 Dec 16  2010 amavisd-new
    -rw-r--r--   1 root root  243 Sep 20 15:46 awstats
    -rw-r--r--   1 root root   74 Sep 22 04:15 ddos.cron
    -rw-r--r--   1 root root 1474 Sep 23 14:44 ispc_web5
    -rw-r--r--   1 root root 1393 Sep 20 15:35 mailman
    -rw-r--r--   1 root root  506 Sep  6 07:05 munin-node
    -rw-r--r--   1 root root  499 Sep 14 05:59 php5
    -rw-r--r--   1 root root  102 Dec 18  2010 .placeholder
    Code:
    [email protected]:~# cat /etc/cron.d/ispc_web5
    MAILTO=''
    SHELL='/bin/sh'
    
    30      *       *       *       *       web5    /usr/bin/wget -q -t 1 -T 7200 -O /dev/null 'https://example.com/member/services.php '\''mailer'\''' >/dev/null 2>&1        #example.com
    

    But I got this error:

    Code:
    [email protected]:~# cat /var/log/syslog
    server1 /USR/SBIN/CRON[25156]: (CRON) error (grandchild #25163 failed with exit status 8)

    I really don't understand, I use the same configuration with the other php files, and it's running cron job well, but with '....' in the ending? :confused:

    I'm sorry for my bad English.

    How to solve this..??

    Thanks for your help and attention.
     
  2. Imam86

    Imam86 New Member

    [solved]

    Ohh.. I got it. :eek:

    I check the php files again.

    Cron Job
    ----------

    php -q /var/www/clients/client5/web5/web/member/services.php 'mailer'


    The previous setting in ISPConfig:
    Code:
    https://example.com/billing/services.php 'mailer'
    It should be:
    Code:
    https://example.com/billing/services.php?service=mailer
    Because it's not configured to run cron from URL.

    This cron job is one of my friend request, but I try to run it with ISPConfig system, and it works now.

    Thanks for the ISPConfig developers.

    I love you all.. :)
     

Share This Page