SMTP service status messages

A SMTP service is a part of the e-mail server responsible to receiving and delivering for an e-mail messages. It communicating with an e-mail client about every action. We, as end-users, can see some of this messages.

The SMTP server and a client doesn’t need whole test. There fore, a SMTP server can just return numerical code for it’s action. In courtesy to the user, SMTP server will return also text message in every e-mail sent back.

You can see from time to time that some e-mail stuck in outgoing queue or that it can’t be delivered to recipient. Such e-mail is short and usually have some text like You e-mail sent to the some_user can not be delivered because of and then some number and short explanation.

That number is the SMTP status message. Text following that number is human readable explanation. Status messages are very common in number of Internet services. Computer systems can just use numbers, but not to much people will understand them. There fore, we will receive also textual explanation.

Some time, we will see those status codes written as three numbers separated with dots, like 4.5.1. Meaning of the code is same. It’s just matter of taste how to display the code.

All those codes are defined in section 4.2.2 of RFC 821 (https://tools.ietf.org/rfc/rfc821.txt). I found this table on Internet and saved it for my reference. It’s very useful either when I need to troubleshoot manually some server or if some end-user receive such e-mail and begun to panic.

They can be group either on functional level or by leading digit. We will show them by leading digit.

211    A system status or help reply.       
214    Help message for user.       
220    The service is ready.       
221    The service is ending the conversation (closing communication channel).       
250    The requested action is OK and it was completed.       
251    The specified user is not local, but the service will forward the e-mail to other server.

354    The service is ready to accept e-mail body. This will follows DATA command from client. Input finished with ENTER-.-ENTER sequence (without hyphen).

421    The service is not available. Try again later.        
450    The mailbox that you are trying to reach is unavailable, probably busy. You should wait and try again.       
451    The requested action was aborted due some local error in e-mail service.       
452    The requested action was aborted due lack of storage space.

500    A syntax error. The last command contained a unrecognized command or the command line was too long.       
501    A syntax error in a parameters or arguments in the last command.       
502    The last command is not implemented on this server.       
503    Bad sequence of the commands.        
504    Command parameter not implemented on this server.       
550    Destination mailbox is unavailable. Reasons can be that it doesn’t exists or sender doesn’t have access rights.       
551    Destination mailbox is not on local server, e-mail should contain some forwarding address       
552    Destination mailbox is full. Message can be aborted or stored in queue for few days.       
553    The name of destination mailbox is not correct.       
554    The e-mail transaction has failed, reason is unknown.  

Some servers have implemented code 200, which means everything OK, please proceed. That code is not according to RFC 821.

As we can see, groups beginning with 4 or 5 contains error messages. Errors begun with 4 are local server related, while errors on digit 5 are mostly remote server related.

If the error is remote related, we can’t do too much. In case of “famous” 550 error, we can check an e-mail address. My general advice is that in case of an error we always should check again our side. In most cases, everything probably will be OK, but this is our check that we didn’t overlooked anything.

Now we can use this table as assistance during e-mail server testing.

Advertisements

One thought on “SMTP service status messages

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s