Re: [Nolug] Backup MX testing...

From: Kevin Kreamer <kevin_at_kreamer.org>
Date: Wed, 11 Aug 2004 22:15:58 -0500
Message-ID: <411AE0EE.5060808@kreamer.org>

Jeremy (mailing list box) wrote:
> Hey all,
>
> I recently set up some backup mail exchangers for a domain that I
> manage. I was able to test whether or not the servers were willing to
> accept mail for the domain, but I couldn't think of any way to actually
> test them (see if they store and then forward the mail) without taking
> down the primary MX. Does anyone here have an idea on how the backup
> MX's can be tested without sacrificing uptime?

Well, you could always go the hard-core geeky approach... send a mail to
that machine directly. The lines starting with '->' is what you type
in, and you should get back the same numeric codes but the messages
could be slightly different.

$ telnet backupmx.example.com smtp
220 backupmx.example.com ESMTP
-> EHLO localname.example.com
250-backupmx.example.com
250-PIPELINING
250-SIZE 40960000
250-ETRN
250-XVERP
250 8BITMIME
-> MAIL FROM: <your_address@somewhere.com>
250 Ok
-> RCPT TO: <test_address@example.com>
250 Ok
-> DATA
354 End data with <CR><LF>.<CR><LF>
-> Subject: Test message for backup MX
->
-> Ignore.
-> .
250 Ok: queued as 3819161
-> QUIT
221 Bye

You should replace backupmx.example.com with the name of your backup mx,
localname.example.com with the name of the machine you are telnet'ing
from, your_address@somewhere.com with your address (where you are
sending the mail from), and test_address.example.com with a test address
  on the backup mx where you are sending the mail to.

Assuming that the backup mx queued the mail correctly, I would then
simply check after a while to see if the mail arrives on the primary MX
server. Of course, the mail logs on both machines are useful to look at.

Oh, and RFC 2821 is the one that documents the SMTP protocol, used
above, in case you need more detail. http://www.faqs.org/rfcs/rfc2821.html

Hope this helps,
Kevin

___________________
Nolug mailing list
nolug@nolug.org
Received on 08/11/04

This archive was generated by hypermail 2.2.0 : 12/19/08 EST