ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Installation/Configuration Support » Sendmail

Post new topic  Reply to topic
 Sendmail « View previous topic :: View next topic » 
Author Message
mreddington
PostPosted: Fri Nov 10, 2006 10:00 am    Post subject: Sendmail Reply with quote

Voyager

Joined: 14 Aug 2006
Posts: 78

Hi all,
In my unix script, i want to use the email command to send an email to our group once my script is done processing.
I tried the following commands:

mail -s "from@address.com"

sendmail -bm "from@address.com"

mail -c "from@address.com"

But the program just waits there at the command prompt without doing anything and after waiting for 5 minutes i have to manually kill it (CTRL-C) and no mail is sent. Can i know the right method to send an email to myself first (test it) and then send it to the rest of the group.

I need the syntax of the mail command in Unix. Can I also test it from the command prompt before inserting the command in my script?

I am new to the scripts and i need this help.
I appreciate your response. Thanks a lot in advance.
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Fri Nov 10, 2006 10:04 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Maybe you should ask in a unix forum.

Maybe you should understand when commands read from standard input, and what that means.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
malammik
PostPosted: Fri Nov 10, 2006 11:13 am    Post subject: Reply with quote

Partisan

Joined: 27 Jan 2005
Posts: 397
Location: Philadelphia, PA

You are way off topic here buddy but here is a sample script.

mailfile=$RANDOM
touch $mailfile

echo "Parameter #1 is $1" >> $mailfile
echo "Parameter #2 is $2" >> $mailfile
echo "Parameter #3 is $3" >> $mailfile
echo "Parameter #4 is $4" >> $mailfile
echo "Parameter #5 is $5" >> $mailfile

cat $mailfile | mail -s "Mail Subject" mmalamud@netflexity.com

rm $mailfile

to add more email addresses google for
man mail
_________________
Mikhail Malamud
http://www.netflexity.com
http://groups.google.com/group/qflex
Back to top
View user's profile Send private message Visit poster's website AIM Address
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Installation/Configuration Support » Sendmail
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.