0

Aim:

I need to check an Exchange email server 2007 (if reachable, delivery time...) but I got some serious restriction (EWS and ping are disabled, and only outlook can access it in intern, external access are done using Outlook Web Access).

Followed track:

With those condition, I was planning to do the following - Using an external mail server to send a testing mail (with an embedded identifiant) to a designated adress on Exchange, who will then send back a response mail with the current time at reception on server and the identifiant. The identifiant, a string, could be in the subject or in the content.

Problem:

With Exchange Server, how to send back a mail with server time at receipt appended to it.

Tested:

  • The absence manager send back a reponse mail with original subject (good for identifiant), but the content is too simple (only plain text) and it doesn't seem possible to insert the time in it.
  • Using rule action 'send a mail using a model', a quickpart can be inserted in the content of the model to give the current time but i can't get data (identifiant) from the original mail (not even the original subject).(work only on outlook client(?), bad: i need the rule running on server)
  • Using rule action transfert send back the original mail without modifying it.
  • Using a VB script could do the job correctly if said script can be included in a server in a rule script but Exchange Transport Hub don't give that possibility (only on outlook client).

Note: If you can think of other ways to do what I aim, those are welcome too.

  • 4
    my head just exploded. – gravyface Aug 10 '11 at 18:41
  • Maybe an outside monitoring tool such as Quest's Spotlight on Messaging or some other exchange tool that can monitor parts of an exchange box might be a better choice. I am not sure I understand what you are trying to monitor exactly. If you wanted a simple "ping" like delivery test, you could have a script send an email to an admin mailbox, have that box use rules to forward the message to your mailbox. Testing recieve and delivery along with leaving the headers intact enough to veryify time. But I am not confident that is a good way to monitor an exchange server. – MikeAWood Aug 11 '11 at 00:57
  • @mike: for the same reason a monitoring tool can't be used. Moreover checking at what time the response is back won't help to diagnostic what is the problem (bad network, server failure, or testing host failure). Here the mail is send from gmail to adress1@server (and append server time) to adress2@server (and append server time again) to aol (and the same is done backward from aol). By adding server time on the mail each time I can isolated the problem to a specific source – Alex Aug 11 '11 at 16:31

3 Answers3

2

I'm unsure why you do it so complicated.

Just issue a manual SMTP connection to the server. If it sends the greeting, then you know that it is online. If yes then continue to send the rest of the mail. Measure the time between connection and disconnection and you have the time used for sending and delivery. Done.

On the server you can discard the mail.

mailq
  • 16,882
  • 2
  • 36
  • 66
0

I'm not entirely sure that I understand what you're asking for.

I wrote an Exchange 2003 Monitoring script last year and published it on Microsoft's Technet Script Center Repository and my GitHub account.

As I describe in the code and description, parts of this will not work in Exchange 2007 (probably the datastore checks, and the ping checks as you describe) because I didn't have access to E2k7.

With that said, the script does send emails, and it would be fairly easy to add a datestamp to the email being sent via the script.

Typically I would run this (as a scheduled task) from a non-Exchange server within the domain, but it's possible to run it on one of the mailservers as well. Read the writeups on the scripts for details.

Like I said, I have no idea how much of my code will work in your particular environment (due the server version and restrictions), but I hope that it gives you some assistance.

gWaldo
  • 11,887
  • 8
  • 41
  • 68
  • @mailq : Only Outlook can connect on server in intern, external access are done exclusively by using Outlook Web Access – Alex Aug 11 '11 at 16:31
  • I'm curious: what is restricting connection to only Outlook? – gWaldo Aug 12 '11 at 02:07
0

Without getting into the details of your question (because my head started to hurt while reading it) there are a number of monitoring applications that can send an email via SMTP and collect it via POP. It's called a loop test. That essentially covers the bases.

This would be a test of almost every component of Exchange by virtue of the fact that almost any failure (SMTP down, server down, IS dismounted, etc., etc) will cause the test to fail, which will clue you in that theirs a problem, which you can then investigate. If the test succeeds you can be assured that the all of the critical components (except web access) are operational.

I perform this very test from an off network monitoring system which will send an email via it's own SMTP engine if the loop test fails. This alerts me that there's a problem with the Exchange server, which I then go investigate.

joeqwerty
  • 108,377
  • 6
  • 80
  • 171