Re: Mail is not working (any way to send message when daemon is down)

2003-10-13 Thread Dali Islam
Anthony,

I did not have a .bash_login for the root user. So,
added that and add the line "service sendmail status".

When I sshe to box and login as root, it doesn't show
me the status.

I thought it needed to refresh the environment, so I
added ". /etc/profile" on the first line. Noop didn't
work!

Thanks
Dali
--- "Anthony E. Greene" <[EMAIL PROTECTED]> wrote:
> On 09-Oct-2003/13:32 -0700, Dali Islam
> <[EMAIL PROTECTED]> wrote:
> >the sendmail was corrupted after reloading the
> daemon
> >it was fixed.
> >
> >Anyway, anyone knows how to send/relay a message
> only
> >on the root login session when a service/daemon is
> >down. Like in this case my sendmail was down. or is
> >there a way that when root login, then it will see
> the
> >message.
> 
> If root logs in at a console, add this to
> /root/.bash_login:
> 
>   service sendmail status
> 
> That will tell you the status every time root logs
> in. If you only want to
> know if sendmail is not running, then use this:
> 
>   if ! service sendmail status > /dev/null; then
> echo sendmail is not running
>   fi
> 
> You can deliver an email message to the local root
> account using procmail
> (this is untested):
> 
> 
> # Build the message in a temp file
> tmpfile=/tmp/$0.$$
> echo 'From: [EMAIL PROTECTED]' > $tmpfile
> echo 'To: [EMAIL PROTECTED]' >> $tmpfile
> echo -n 'Date: ' >> $tmpfile
> date --rfc-822 >> $tmpfile
> echo 'Subject: sendmail not running' >> $tmpfile
> echo '' >> $tmpfile
> service sendmail status >> $tmpfile
> 
> # Deliver the message and delete the temp file.
> cat $tmpfile | procmail -d root
> rm $tmpfile
> 
> 
> 
> 
> Tony
> -- 
> Anthony E. Greene
>

> OpenPGP Key: 0x6C94239D/7B3D BD7D 7D91 1B44 BA26 
> C484 A42A 60DD 6C94 239D
> AOL/Yahoo Messenger: TonyG05HomePage:
> 
> Linux. The choice of a GNU generation
> 
> 
> 
> -- 
> redhat-list mailing list
> unsubscribe
>
mailto:[EMAIL PROTECTED]
> https://www.redhat.com/mailman/listinfo/redhat-list


__
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list


Re: Mail is not working (any way to send message when daemon is down)

2003-10-10 Thread Anthony E. Greene
On 09-Oct-2003/13:32 -0700, Dali Islam <[EMAIL PROTECTED]> wrote:
>the sendmail was corrupted after reloading the daemon
>it was fixed.
>
>Anyway, anyone knows how to send/relay a message only
>on the root login session when a service/daemon is
>down. Like in this case my sendmail was down. or is
>there a way that when root login, then it will see the
>message.

If root logs in at a console, add this to /root/.bash_login:

  service sendmail status

That will tell you the status every time root logs in. If you only want to
know if sendmail is not running, then use this:

  if ! service sendmail status > /dev/null; then
echo sendmail is not running
  fi

You can deliver an email message to the local root account using procmail
(this is untested):


# Build the message in a temp file
tmpfile=/tmp/$0.$$
echo 'From: [EMAIL PROTECTED]' > $tmpfile
echo 'To: [EMAIL PROTECTED]' >> $tmpfile
echo -n 'Date: ' >> $tmpfile
date --rfc-822 >> $tmpfile
echo 'Subject: sendmail not running' >> $tmpfile
echo '' >> $tmpfile
service sendmail status >> $tmpfile

# Deliver the message and delete the temp file.
cat $tmpfile | procmail -d root
rm $tmpfile




Tony
-- 
Anthony E. Greene 
OpenPGP Key: 0x6C94239D/7B3D BD7D 7D91 1B44 BA26  C484 A42A 60DD 6C94 239D
AOL/Yahoo Messenger: TonyG05HomePage: 
Linux. The choice of a GNU generation 


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list


Re: Mail is not working (any way to send message when daemon is down)

2003-10-09 Thread Hal Burgiss
On Thu, Oct 09, 2003 at 03:18:05PM -0700, Chris W. Parker wrote:
> 
> p.s. someone correct me if i am wrong!! thanks!


# Do a mail header, then add body.

( printf "\
>From [EMAIL PROTECTED] `date`\n\
Return-Path: <[EMAIL PROTECTED]>\n\
To: Master of the Domain and all that Lies Herein\n\
Subject: Init Status Report\n\
Date: `date`\n\
From: `basename [EMAIL PROTECTED] -s`\n\
Message-Id: <`date '+%s'[EMAIL PROTECTED]>\n\n\n\
  Status Report\n\n"

cat_or_some_other_cmd_goes_here_to_flesh_out_the_bod ) \
 |procmail -d $mailto_dude   # < delivery is here, bypassing smtp

Crude paste from one of my scripts, with minor mods that might need
some testing first, but works as I use it all the time to bypass spam
checks from stmpd.

-- 
Hal Burgiss
 


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list


RE: Mail is not working (any way to send message when daemon is down)

2003-10-09 Thread Chris W. Parker
Mark Cohen 
on Thursday, October 09, 2003 3:17 PM said:

> Actually, You are wrong.. You can send mail w/o the sendmail
> daemon running.

[snip]

thanks for setting me straight.


chris.

-- 
Don't like reformatting your Outlook replies? Now there's relief!
http://home.in.tum.de/~jain/software/outlook-quotefix/


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list


RE: Mail is not working (any way to send message when daemon is down)

2003-10-09 Thread Kenneth Goodwin
Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Mark Cohen
Sent: Thursday, October 09, 2003 6:17 PM
To: '[EMAIL PROTECTED]'
Subject: RE: Mail is not working (any way to send message
when daemon is down)




Actually,
You are wrong.. You can send mail w/o the sendmail daemon
running.
Your mail client calls sendmail to deliver the mail, it
doesn't need to connect to a daemon..
You run the daemon to accept incoming mail. ie. Keep the
smtp port open to accept mail.
Depending on the client ofcourse..
Mutt for instance isn't a mta, its just a client that calls
sendmail
Pine has its own mta in it.
As for smtp, there are a number of light smtp programs out
there, just search for them.
-Mark

===
HTML FOrmat deleted - please dont post in HTML
==

Then pine or a MUA with a configurable interface to a
lightweight SMTP MTA  is what he should use,
the problem here is why is sendmail crashing in the first
place.
It is always possible that if he uses a  MUA that calls
sendmail for outbound and there is something
wrong with his setup
then he may also fail to send mail if the MUA side of
sendmail also has the same
problem and crashes as well.

hence, he should use something other than sendmail as a MTA
and have it connect
to a sendmail hub/relay daemon on a different server.


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list


RE: Mail is not working (any way to send message when daemon is down)

2003-10-09 Thread Kenneth Goodwin
>  -Original Message-
>  From: [EMAIL PROTECTED]
>  [mailto:[EMAIL PROTECTED] Behalf Of Chris
W. Parker
>  Sent: Thursday, October 09, 2003 6:18 PM
>  To: [EMAIL PROTECTED]
>  Subject: RE: Mail is not working (any way to send message

>  when daemon is
>  down)
>  
>  
>  Dali Islam <mailto:[EMAIL PROTECTED]>
>  on Thursday, October 09, 2003 1:33 PM said:
>  
>  > Anyway, anyone knows how to send/relay a message only
>  > on the root login session when a service/daemon is
>  > down. Like in this case my sendmail was down.
>  
>  Can a car be driven if the motor isn't on? Can you make
Pepsi without
>  the ingredients?
>  
>  You may be able to send mail with something OTHER than 
>  sendmail, but I
>  don't know how. And to answer your question directly, no
you 
>  cannot send
>  mail via sendmail if the sendmail daemon is not running.
>  
>  
>  chris.
>  
>  p.s. someone correct me if i am wrong!! thanks!


It would take a Mail user Agent with a built in SMTP
interface (perhaps one of the SMTP enabled PERL modules)
and then you point it at a sendmail server on another
machine.
The client does not have to point at a LOCAL sendmail server
to send mail,
you just need a client that can be configured to  SMTP
off-host. 

Just need a MUA where you configure the ip address of the
SMTP server, like MS mail/Outlook. 
<>

RE: Mail is not working (any way to send message when daemon is down)

2003-10-09 Thread Chris W. Parker
Dali Islam 
on Thursday, October 09, 2003 1:33 PM said:

> Anyway, anyone knows how to send/relay a message only
> on the root login session when a service/daemon is
> down. Like in this case my sendmail was down.

Can a car be driven if the motor isn't on? Can you make Pepsi without
the ingredients?

You may be able to send mail with something OTHER than sendmail, but I
don't know how. And to answer your question directly, no you cannot send
mail via sendmail if the sendmail daemon is not running.


chris.

p.s. someone correct me if i am wrong!! thanks!


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list


Re: Mail is not working (any way to send message when daemon is down)

2003-10-09 Thread Dali Islam
the sendmail was corrupted after reloading the daemon
it was fixed.

Anyway, anyone knows how to send/relay a message only
on the root login session when a service/daemon is
down. Like in this case my sendmail was down. or is
there a way that when root login, then it will see the
message.

Any help will be aprrecite!



--- Joe Polk <[EMAIL PROTECTED]> wrote:
> Did you check to see if your smtp daemon is running?
> 
> ps -ef | grep sendmail
> 
> <>
> 
> -- Original Message ---
> From: Dali Islam <[EMAIL PROTECTED]>
> To: redhat list <[EMAIL PROTECTED]>
> Sent: Tue, 7 Oct 2003 07:30:14 -0700 (PDT)
> Subject: Mail is not working
> 
> > I have crontab setup to send e-mail automatically!
> > Since last two days it's not working. I tried to
> send
> > e-mail using mutt and mail command they did not
> work
> > either. I looked at the /var/log/messages and no
> error
> > message.
> > 
> > What can go wrong, please advise!
> > 
> > __
> > Do you Yahoo!?
> > The New Yahoo! Shopping - with improved product
> search
> > http://shopping.yahoo.com
> > 
> > -- 
> > redhat-list mailing list
> > unsubscribe
>
mailto:[EMAIL PROTECTED]
> >
> https://www.redhat.com/mailman/listinfo/redhat-list
> --- End of Original Message ---
> 
> 
> -- 
> redhat-list mailing list
> unsubscribe
>
mailto:[EMAIL PROTECTED]
> https://www.redhat.com/mailman/listinfo/redhat-list


__
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list