Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I want to write a script that sends an e-mail with attachments (different sizes, different recipients). I wish prior to sending e-mail, somehow detect if recipient's mail server can handle the size of it. Is there a way to do this?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

You can try to telnet to the recipients email server on port 25 and issue the EHLO command. The server should respond with the EHLO commands that it supports and should list the size limit that it supports. This is not a guaranteee that the recipient mailbox will accept an email of the same size though.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.