LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.

Notices


Reply
  Search this Thread
Old 06-09-2010, 01:33 PM   #1
grob115
Member
 
Registered: Oct 2005
Posts: 542

Rep: Reputation: 32
Need to direct to >2&1 for cron?


Heard that cron will generate an e-mail whenever it executes a line, and to prevent this, each cron line should have >2&1 appended at the end. Is this true?
 
Old 06-09-2010, 02:48 PM   #2
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,824

Rep: Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615
Mostly true; you need ">/dev/null 2>&1"
 
Old 06-10-2010, 07:32 AM   #3
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789

Rep: Reputation: 492Reputation: 492Reputation: 492Reputation: 492Reputation: 492
To clarify, cron only sends e-mails when the executed program is outputting something in either its stdout or stderr. These redirections are discarding these potential outputs.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Direct Cron Output in Text carlosinfl Linux - Server 1 04-29-2010 08:20 AM
gentoo 2007.0 & ati radeon 9700 pro & direct rendering jimerickso Linux - Desktop 10 04-01-2008 09:05 AM
Slackware 10.2 & Direct Rendering securitybreach Slackware 13 12-05-2005 10:30 AM
KDE & IP Direct Printing technochef Linux - Software 1 07-21-2005 11:14 AM
RH9 & direct cd's warheros Linux - Software 15 08-04-2003 02:23 PM

LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris

All times are GMT -5. The time now is 03:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration