- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: cron job completion emails
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-24-2001 04:15 AM
08-24-2001 04:15 AM
..Joe
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-24-2001 04:27 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-24-2001 04:42 AM
08-24-2001 04:42 AM
Re: cron job completion emails
...jcd...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-24-2001 05:00 AM
08-24-2001 05:00 AM
Re: cron job completion emails
cron will send all output (stdout & stderr) to the mailbox of the cron user. You will have to redirect all output yourself if don't want this to fill up your mailbox, as already mentioned.
1 1 * * * job > /dev/null 2>&1 is however not always a good idea, you might miss error messages which you will not be able to review ever.
regards,
Thierry.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-24-2001 06:07 AM
08-24-2001 06:07 AM
Re: cron job completion emails
I confirm, with crontab jobs, all standard output and standard error will be sent to the user who had plan the cron job ( because there is no related attached tty to that script ).
If you want to remove all these output ( Standard and error ) you should redirect them to /dev/null.
But attention, sometimes these information are really important to debug some abnormal situation.
If you know about standard output and you assume to redirect to /dev/null, I would PREFER leaving standard error go to the mail so that in case of troubles you will be at least notified for that.
Examples :
1. Redirection of both standard output and standard error :
* * * * * /users/.../script1.sh > /dev/null 2>&1
2. Redirection of only standard output :
* * * * * /users/.../script1.sh > /dev/null
3. Redirection of only standard error:
* * * * * /users/.../script1.sh 2> /dev/null
Good luck.
Magdi