From owner-freebsd-questions@FreeBSD.ORG Thu Apr 24 22:08:18 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D21291065679 for ; Thu, 24 Apr 2008 22:08:18 +0000 (UTC) (envelope-from datahead4@gmail.com) Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.172]) by mx1.freebsd.org (Postfix) with ESMTP id B8D988FC15 for ; Thu, 24 Apr 2008 22:08:18 +0000 (UTC) (envelope-from datahead4@gmail.com) Received: by wf-out-1314.google.com with SMTP id 25so2589532wfa.7 for ; Thu, 24 Apr 2008 15:08:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=JaDyYhISe5a+CDwvrcmp+fUOEwNkl+w4LxrWaG5G3eM=; b=l9oOq09nVH/p/bpVutrUxyCUzlx/Kh80X0WGJoXmR7112szzyQENy7ZdQwJLcj2/fUS3wRHbXxgU0+OUbXPbhoAxW7O8oT9bP8eoNp/0hqXUF6KbaK/1mgBHplTpoz2uSL36uA2CiGFFWrmQi423nDKvsB9Yu2Kx8j2gYjD1Sdc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=MfGPGRghQOJvrXRRaShk4vDP8KQ+Ph/8Q9n7UJKyxPKip3bTe5ioRos4EMj9EhfyOQTOxTG2xucTvaMBH0VcdzFwyhBlhXfqHs2aDtNkgB/AaLIHqZTWMnolBGeZbLk2jOVipKL9IwzFn7U7DE008Q63wEakBzQBaVlQxjAg4BI= Received: by 10.142.70.21 with SMTP id s21mr151809wfa.240.1209073267324; Thu, 24 Apr 2008 14:41:07 -0700 (PDT) Received: by 10.143.122.6 with HTTP; Thu, 24 Apr 2008 14:41:07 -0700 (PDT) Message-ID: Date: Thu, 24 Apr 2008 16:41:07 -0500 From: Matt To: "John Almberg" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: Cc: freebsd-questions@freebsd.org Subject: Re: Cron question X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Apr 2008 22:08:18 -0000 On Thu, Apr 24, 2008 at 3:26 PM, John Almberg wrote: > SHELL=/usr/local/bin/bash Did you install bash from ports and does it run OK from outside of cron? > > PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/usr/X11R6/bin:/home/gs/bin > HOME=/home/gs > 0 15 * * * /home/gs/bin/script.php >>/home/gs/log/script.log > > I can see from the cron log that cron runs script.php at the appointed > hour: > > Apr 24 15:00:03 on /usr/sbin/cron[72414]: (gs) CMD > (/home/gs/bin/script.php >>/home/gs/log/script.log) This entry in the cron log will still show up if the shell listed in the crontab is not available. However, as someone else already mentioned, cron sends a mail when it goes to run and can't execute the shell.