Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
postfix problems when myhostname != computer hostname
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
tomek32
Tux's lil' helper
Tux's lil' helper


Joined: 30 May 2004
Posts: 139

PostPosted: Sun Sep 05, 2004 3:27 am    Post subject: postfix problems when myhostname != computer hostname Reply with quote

I have the following in /etc/postfix/main.cf
Code:
myhostname = mail.tomek.ca
mydestination =
        $myhostname,
        localhost.$mydomain,
        eigen.$mydomain,
        $mydomain,
        localhost
alias_maps = hash:/etc/mail/aliases
alias_database = hash:/etc/mail/aliases
mail_spool_directory = /var/spool/mail/
local_destination_concurrency_limit = 1
message_size_limit = 0
masquerade_domains = $mydomain
masquerade_exceptions = root
relay_domains =


For some reason, if I change the myhostname variable to mail.tomek.ca, where the real computer name is eigen.tomek.ca, sending mail fails. It doesn"t bounce, just doesn't appear anywhere.

For example, here's the output of /var/log/mail.info when I send an email from user tom to tomek32@gmail.com
Code:
Sep  4 23:19:25 eigen postfix/pickup[22645]: 1937913AAC: uid=1000 from=<tom>
Sep  4 23:19:25 eigen postfix/cleanup[22841]: 1937913AAC: message-id=<20040905031924.GA22833@eigen>
Sep  4 23:19:25 eigen postfix/qmgr[22646]: 1937913AAC: from=<tom@tomek.ca>, size=376, nrcpt=1 (queue active)
Sep  4 23:19:25 eigen postfix/smtp[22843]: 1937913AAC: to=<tomek32@gmail.com>, relay=none, delay=0, status=deferred (Host or domain name not found. Name service erro
r for name=gmail.com type=MX: Host not found, try again)


but if I change i comment out the myhostname variable, sending mail works, and here's what I get in the logs
Code:
Sep  4 23:22:36 eigen postfix/pickup[22982]: 07D7D13A7E: uid=1000 from=<tom>
Sep  4 23:22:36 eigen postfix/cleanup[22997]: 07D7D13A7E: message-id=<20040905032235.GA23013@eigen>
Sep  4 23:22:36 eigen postfix/qmgr[22983]: 07D7D13A7E: from=<tom@tomek.ca>, size=377, nrcpt=1 (queue active)
Sep  4 23:22:36 eigen postfix/smtp[22986]: 07D7D13A7E: to=<tomek32@gmail.com>, relay=gsmtp171.google.com[64.233.171.27], delay=0, status=sent (250 OK 1094354547)
Sep  4 23:22:36 eigen postfix/qmgr[22983]: 07D7D13A7E: removed


Why would changing myhostname to a different name from the actual computer name cause postfix to not be able to resolve gmail.com?

Don't know if it matters, I run a dns server aswell, where the MX record points to mail.tomek.ca
Back to top
View user's profile Send private message
tomek32
Tux's lil' helper
Tux's lil' helper


Joined: 30 May 2004
Posts: 139

PostPosted: Sun Sep 05, 2004 10:49 pm    Post subject: Reply with quote

Well, it seems like the tried and true reboot works again. All's good now.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum