The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Facing issue in Solaris OS in crontab for running shell script mabrar Shell Programming and Scripting 2 11-02-2007 02:32 AM
Crontab Mail message pankajkrmishra Shell Programming and Scripting 1 09-22-2006 01:36 AM
Recieved: Header help for sendmail rkf45144 UNIX for Advanced & Expert Users 0 06-29-2006 07:26 PM
NIS map mail.aliases specified, but NIS not running stancwong UNIX for Dummies Questions & Answers 2 08-29-2005 06:29 PM
running sql in crontab dorilevy UNIX for Dummies Questions & Answers 4 08-22-2002 04:13 AM

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-04-2006
Registered User
 

Join Date: Jul 2006
Posts: 55
Mail not recieved when running from Crontab

Hi

I am not able to recieve mail when a script is run as a cron job. But when same job is run from command prompt mail is recieved .

Any help will be appreciated.

Thanks
Pankaj
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 08-04-2006
Registered User
 

Join Date: Nov 2005
Posts: 91
Sure there must be something wrong in the cron setup...Please post your cron job.
Reply With Quote
  #3 (permalink)  
Old 08-05-2006
Registered User
 

Join Date: Jul 2006
Posts: 55
Hi

Here is the cron entry of the process/sh file

25 09 * * * /opt/bea/wls61/config/dev05/batch_automation
/MBPSBatch/vendorfeed_concentra.sh > /opt/bea/wls61/config/dev05/batc
h_automation/MBPSBatch/logs/concentra_feed.log


Now when this file (vendorfeed_concentra.sh ) is run from command prompt , than a mail notification goes to the the users whose email is entered in a xml file. This xml file is envoked by the script at runtime. I am stuck here....

Thanks
Pankaj
Reply With Quote
  #4 (permalink)  
Old 08-05-2006
vgersh99's Avatar
Moderator
 

Join Date: Feb 2005
Location: Boston, MA
Posts: 2,999
have you tried looking in the usual place first?
Reply With Quote
  #5 (permalink)  
Old 08-09-2006
Registered User
 

Join Date: Jul 2006
Posts: 55
Hi

I tried to look at the link but could not find anything significant.

Please suggest

Regards
Pankaj
Reply With Quote
  #6 (permalink)  
Old 08-09-2006
aigles's Avatar
Registered User
 

Join Date: Apr 2004
Location: Bordeaux, France
Posts: 1,198
The .profile is not executed when scripts run from cron.
Try :
Code:
25 09 * * * . $HOME/.profile; /opt/bea/wls61/config/dev05/batch_automation
/MBPSBatch/vendorfeed_concentra.sh > /opt/bea/wls61/config/dev05/batc
h_automation/MBPSBatch/logs/concentra_feed.log

Jean-Pierre.
Reply With Quote
  #7 (permalink)  
Old 08-09-2006
Registered User
 

Join Date: Jul 2006
Posts: 55
Hi

Tried , but even that did not worked...... now I am sinking.........

Regards
pankaj
Reply With Quote
Google UNIX.COM
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 12:55 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0