Re: [Fwd: [ph-linux-newbie] help on cron]
am 07.11.2002 15:53:43 von mixo
try :
* * * * * /path/to/php -i /usr/local/apache/htdocs/xxx.php
Joseph Syjuco wrote:
>
>
>
> ------------------------------------------------------------ ------------
>
> Subject:
> [ph-linux-newbie] help on cron
> From:
> Joseph Syjuco
> Date:
> 07 Nov 2002 15:58:12 +0000
> To:
> ph-linux-newbie@lists.q-linux.com
>
>
>id like to execute a php file automatically during certain periods of
>time so what i did i installed php-cgi (which allows me to execute php
>using cmd php ). Ive finished my php script, tried it and it
>worked but when i put it in crontab
>* * * * * php /usr/local/apache/htdocs/xxx.php
>it didnt work ... it didnt spew any errors ... just did nothing
>in order to verify if cron is working properly i added a new entry
>* * * * * rm /home/postgres/test.txt
>when i inspected the results ... 2nd script worked (rm) but not the php
>script
>any ideas whats wrong?
>path of script is ok and path is working when i execute it in command
>line
>TIA
>joseph
>
>
>
>_______________________________________________
>ph-linux-newbie mailing list
>http://lists.q-linux.com/mailman/listinfo/ph-linux-newbie
>plug website http://plug.linux.org.ph
>to unsubscribe, send 'unsubscribe' to ph-linux-newbie-request@lists.q-linux.com
>
>
>----------------------------------------------------------- -------------
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 4: Don't 'kill -9' the postmaster
>
>
---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster
[Fwd: [ph-linux-newbie] help on cron]
am 07.11.2002 17:02:26 von Joseph Syjuco
--=-FVQIpAEbUefgkg7RLX5x
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
--=-FVQIpAEbUefgkg7RLX5x
Content-Disposition: inline
Content-Description: Forwarded message - [ph-linux-newbie] help on cron
Content-Type: message/rfc822
Return-Path:
Delivered-To: joseph@asti.dost.gov.ph
Received: from mail.q-linux.com (unknown [203.176.80.8]) by
kitana.asti.dost.gov.ph (Postfix) with ESMTP id 140E12585E for
; Thu, 7 Nov 2002 16:01:21 +0800 (PHT)
Received: from mail.q-linux.com (localhost.localdomain [127.0.0.1]) by
mail.q-linux.com (Postfix) with ESMTP id 6EF462846C; Thu, 7 Nov 2002
16:00:14 +0800 (PHT)
Delivered-To: ph-linux-newbie@lists.q-linux.com
Received: from kitana.asti.dost.gov.ph (kitana.asti.dost.gov.ph
[202.90.128.8]) by mail.q-linux.com (Postfix) with ESMTP id 7CB1327FA2 for
; Thu, 7 Nov 2002 15:59:33 +0800 (PHT)
Received: from [10.10.5.200] (unknown [10.10.5.200]) by
kitana.asti.dost.gov.ph (Postfix) with ESMTP id C6CDA2581D for
; Thu, 7 Nov 2002 16:00:27 +0800 (PHT)
From: Joseph Syjuco
To: ph-linux-newbie@lists.q-linux.com
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
X-Mailer: Ximian Evolution 1.0.3 (1.0.3-4)
Message-Id: <1036684693.16728.4.camel@Falcon>
Mime-Version: 1.0
Subject: [ph-linux-newbie] help on cron
Sender: ph-linux-newbie-admin@lists.q-linux.com
Errors-To: ph-linux-newbie-admin@lists.q-linux.com
X-BeenThere: ph-linux-newbie@lists.q-linux.com
X-Mailman-Version: 2.0.5
Precedence: bulk
Reply-To: ph-linux-newbie@lists.q-linux.com
List-Help:
List-Post:
List-Subscribe:
,
List-Id: Philippine Linux Newbies Mailing List
List-Unsubscribe:
,
List-Archive:
Date: 07 Nov 2002 15:58:12 +0000
id like to execute a php file automatically during certain periods of
time so what i did i installed php-cgi (which allows me to execute php
using cmd php ). Ive finished my php script, tried it and it
worked but when i put it in crontab
* * * * * php /usr/local/apache/htdocs/xxx.php
it didnt work ... it didnt spew any errors ... just did nothing
in order to verify if cron is working properly i added a new entry
* * * * * rm /home/postgres/test.txt
when i inspected the results ... 2nd script worked (rm) but not the php
script
any ideas whats wrong?
path of script is ok and path is working when i execute it in command
line
TIA
joseph
_______________________________________________
ph-linux-newbie mailing list
http://lists.q-linux.com/mailman/listinfo/ph-linux-newbie
plug website http://plug.linux.org.ph
to unsubscribe, send 'unsubscribe' to ph-linux-newbie-request@lists.q-linux.com
--=-FVQIpAEbUefgkg7RLX5x
Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
MIME-Version: 1.0
---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster
--=-FVQIpAEbUefgkg7RLX5x--
Re: [Fwd: [ph-linux-newbie] help on cron]
am 07.11.2002 17:52:51 von Scott Marlowe
On 7 Nov 2002, Joseph Syjuco wrote:
> worked but when i put it in crontab
> * * * * * php /usr/local/apache/htdocs/xxx.php
> it didnt work ... it didnt spew any errors ... just did nothing
Try editing your php script so the first line looks something like this:
#!/usr/local/bin/php -q
script goes here
?>
Note that the /usr/local/bin part might be different on your box than on
mine.
---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?
http://archives.postgresql.org