From owner-freebsd-questions Fri Jul 19 18:54:28 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CC9E437B400 for ; Fri, 19 Jul 2002 18:54:26 -0700 (PDT) Received: from catflap.home.slightlystrange.org (host217-39-153-84.in-addr.btopenworld.com [217.39.153.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id 40F0143E4A for ; Fri, 19 Jul 2002 18:54:26 -0700 (PDT) (envelope-from dan@slightlystrange.org) Received: from danielby by catflap.home.slightlystrange.org with local (Exim 3.36 #1) id 17VjRq-000DPR-00 for freebsd-questions@FreeBSD.ORG; Sat, 20 Jul 2002 02:54:18 +0100 Date: Sat, 20 Jul 2002 02:54:17 +0100 From: Daniel Bye To: freebsd-questions@FreeBSD.ORG Subject: Re: Cron: mailing owner: how to stopit! Message-ID: <20020720015417.GD51089@catflap.home.slightlystrange.org> Reply-To: dan@slightlystrange.org Mail-Followup-To: freebsd-questions@FreeBSD.ORG References: <20020720014445.GB51089@catflap.home.slightlystrange.org> <20020720015202.GA40625@dan.emsphone.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020720015202.GA40625@dan.emsphone.com> User-Agent: Mutt/1.4i X-Scanner: exiscan *17VjRq-000DPR-00*jwk4O.XfYrY* (SlightlyStrange.org, Using NOD32 http://www.nod32.com) Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Jul 19, 2002 at 08:52:02PM -0500, Dan Nelson wrote: > In the last episode (Jul 20), Daniel Bye said: > > On Fri, Jul 19, 2002 at 06:34:26PM -0700, Steve Warwick wrote: > > > I have several scripts that run very frequently and email the owner > > > every time the script is run. > > > > > > I have gone through all the setup / config files but cannot figure > > > out how to stop this from happening. Anyone have a list of > > > locations I should look for this configuration / option? > > > > AFAIK, any command run by cron that generates any output, will cause > > an e-mail to be sent to the owner of the job. To stop it, you need > > to make sure that the scripts called by cron don't generate any > > output. This can be done by redirecting the script's stdout to > > /dev/null. It's probably not a good idea to redirect stderr to > > /dev/null as well, though, as the owner will never receive > > notification if the job fails or throws up any warnings. > > You can also disable mail by setting MAILTO= in your crontab file, > before that entry. "man 5 crontab" for more info Cool - cheers, Dan. I had never come across that before. Dan -- Daniel Bye PGP Key: ftp://ftp.slightlystrange.org/pgpkey/dan.asc PGP Key fingerprint: 3D73 AF47 D448 C5CA 88B4 0DCF 849C 1C33 3C48 2CDC _ ASCII ribbon campaign ( ) - against HTML, vCards and X - proprietary attachments in e-mail / \ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message