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

This is my setup:

ArchLinux box
Postfix, setup with smtp relay as described here / gmailrelay@gmail.com (example, not actual. read on) Dynamic DSL IP from my ISP
DynDNS account / ddclient to refresh my IP

This setup works fine. I can send mail from my local accounts from my ArchLinux box to the outside world.

However: I would like the "From" email address to show localuser@myaccount.dyndns.org instead of gmailrelay@gmail.com so I can reply directly to my box, instead to that Gmail account I don't even check.
Is this possible with postfix?

P.S. I don't want to forward mails from Gmail :)
P.P.S. I have already tried sending directly to localuser@myaccount.dyndns.org using my personal Gmail account, and that works too.

share|improve this question

1 Answer 1

I think tour Postfix is already sending your mails with the right from address. GMail is probably rewriting the from address to your GMail address.

It might work if you add the desired from address as a "send mail as" email address in your GMail account settings. https://support.google.com/mail/bin/answer.py?hl=en&ctx=mail&answer=22370

share|improve this answer
    
But i have several users on that computer... user1, user2, user3, and I can only set one address as "sand as" –  Kaurin Mar 7 '12 at 22:49
    
Ok, now i'm pretty sure postfix is doing this. I have set "send mail as" and i still get the gmail address as the reply address. –  Kaurin Mar 8 '12 at 16:42
    
Strange, I assume you verified the send as and all? You should check what's going on in the log, probably /var/mail.log. To see the complete smtp conversation between postfix and smtp.gmail.com, increase postfix smtp verbosity by adding a -v behind the smtp unix - - - - - smtp line in /etc/postfix/master.cf. (Doc) –  J3L2404 Mar 8 '12 at 18:11
    
i have added the -v. here is the pastebin pastebin.com/7spSDj58 –  Kaurin Mar 8 '12 at 19:26

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.