Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm experiencing a lot of bounced emails after a recent change in hosts. What is happening, and may very well be correct, is that I will send mail from my MTA at home through my server and the server authenticates via STARTTLS and relays the mail using my home IP address.

I don't recall this behavior from our old server. What I recall is that the server's IP address would be used in the from header.

Is there a way to use the server's IP address in place of my home IP? What I find is that most dynamic IPs are blacklisted, causing many of my mails to bounce. I'm not sure what I need to do this. Is this masquerading I want? I do not want to use a smarthost for this.

Thanks.

EDIT:

I have two bounced messages I'd like to post.

The original message was received at Fri, 2 Mar 2012 10:45:35 -0800 (PST)
from cpe-170-31-105-69.res.rr.com [170.31.105.69]

   ----- The following addresses had permanent fatal errors -----
<xxxxxxxxxx@messaging.sprintpcs.com>
    (reason: 554 lnxipc002-in.nmcc.sprintspectrum.com)

   ----- Transcript of session follows -----
... while talking to mx.messaging.sprintpcs.com.:
<<< 554 lnxipc002-in.nmcc.sprintspectrum.com
554 5.0.0 Service unavailable

The last one is:

The original message was received at Thu, 1 Mar 2012 11:02:35 -0800 (PST)
from cpe-170-31-105-69.res.rr.com [170.31.105.69]

   ----- The following addresses had permanent fatal errors -----
<johndoe@corp.com>
    (reason: 554 Transaction Failed Spam Message not queued.)

   ----- Transcript of session follows -----
... while talking to mail2.corp.com.:
>>> DATA
<<< 554 Transaction Failed Spam Message not queued.
554 5.0.0 Service unavailable
share|improve this question

migrated from serverfault.com Mar 2 '12 at 19:58

This question came from our site for professional system and network administrators.

    
This Question is Off-Topic per Server Fault's FAQ: "and it is not about…Anything in a home setting". Super User covers such topics however, this Question has been migrated there. –  Chris S Mar 2 '12 at 19:59
    
Thanks for putting this post where it belongs, Chris. I wasn't sure which site to post this on. –  Muzz Mar 2 '12 at 22:53

3 Answers 3

up vote 0 down vote accepted
  1. An MTA should never change exiting headers unless it has some extraordinarily good reason, this is not one.
  2. That the e-mail originated from a dynamic IP has almost nothing to do with the next hope accepting the e-mail.

    I run a mail server at my house. It relays e-mail to a VPS I have, which forward e-mail appropriately. I've never had a single e-mail bounce because of the home server with a dynamic IP (which is listed in any PBLs I've looked through). Also the home server writes in a Received header for the internal IP of the MUA that originated the e-mail, or in the case of webmail is yet another IP address (and the webmail software writes it's own Received header in concerning the web browser which logged in; and if there's a proxy in the middle it's information gets in there too)

share|improve this answer
    
Chris, I'm not following you completely. Maybe what I'm asking is not possible but I'm going to ask in simple terms since I don't have all that much experience with sendmail. What I would like is for the email headers to show that the email I sent from my client, originated from my server and not my client; as if the server itself sent the mail. Is this possible? –  Muzz Mar 2 '12 at 23:12
    
@Muzz - in the DSN, except DSN-text quoted, you have (most probably) original message, which produce bounce. Read it's headers! –  Lazy Badger Mar 3 '12 at 9:28
    
@LazyBadger, I'm not following you. Can you be more specific? I'm not privy to sendmail at all. –  Muzz Mar 4 '12 at 7:48
    
@Muzz - in received bounce e-mail, with you read in your MUA (no relation to sendmail at all), you have attachment - your original mail. Save it, open, read headers of e-mail –  Lazy Badger Mar 4 '12 at 7:53
    
@Muzz, while it's technically possible yes; no you should not do that. I thought #1 was completely clear: but to reiderate, an MTA should never lie. The origin of your e-mail does not effect next-hop delivery; the "problem" you think exist, does not. If you're having problems they are elsewhere. Try putting the IP of your server into whatismyipaddress.com/blacklist-check; see what it finds. If that's clean you'll need to ask the postmaster for the domain you're trying to send to, they should have details of the problem. –  Chris S Mar 4 '12 at 15:55

The receiving MTA will look at the connecting MTA's ip accept/reject based on that, not the ip address of the originator. Otherwise no one's email would get anywhere. This is all in the headers.

Do you have a DSN of a bounced message ? If you are indeed using sendmail it should give you all relevant info as to why the message bounced.

Most likely the ip of your new server is in some RBLs and that is why but without the actual DSN one can only speculate. If it is greek to you, post it.

share|improve this answer
    
Thanks kls, sendmail was never one of my strong points. I've already verified that my IP is clean and is not listed in any RBLs. I'm going to post one of the DSNs in an edit, up top. Thanks for looking and the help. –  Muzz Mar 2 '12 at 22:59

Are you relaying through your ISP or another provider? If you local MTA is delivering mail directly to the internet, then you would be subjected to common spam checks (e.g., SPF records, reverse DNS lookups).

In postfix for example, you would set the relayhost directive to the IP address of your provider. A google example: https://www.wormly.com/blog/2008/11/05/relay-gmail-google-smtp-postfix/

share|improve this answer
    
I have this server in a data center and I'm not using a smarthost if that's what you mean. I have TLS configured in sendmail so when I use my ISP at home, I authenticate to the server and send the mail. It seems however, I am being blacklisted by Sprint and another organization. Both bounce the mail back to me with a 554 status code. See: reason: 554 lnxipc002-in.nmcc.sprintspectrum.com –  Muzz Mar 2 '12 at 22:57
    
@Muzz They could be rejecting you for a number of reasons: virus detection, poor domain ratings, spf records, etc. and that specific reject reason is too vague to know. Are there any other 554's in your logs with a more descriptive reason? Out of curiosity, have you verified your SPF records? This tool can be helpful if you have not kitterman.com/spf/validate.html –  InChargeOfIT Mar 2 '12 at 23:16
    
Thanks for the link. Since the host has offered to host my DNS, I didn't have access to write an SPF however, thanks to the link you've provided, it appears that there are no SPF records found. No type SPF records found. I know if I ask them to add it, they will. Thanks for this tip. –  Muzz Mar 2 '12 at 23:50
    
I just requested that my host add an SPF record for me. I'm sure that will be done within the hour. –  Muzz Mar 3 '12 at 0:04
    
I would guess that this is your problem. Also make sure you have reverse DNS entries for your domain as well. –  InChargeOfIT Mar 3 '12 at 0:14

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.