ispconfig postfix dns

Discussion in 'Installation/Configuration' started by stanman, Jul 4, 2009.

  1. stanman

    stanman New Member

    Hi in here.
    I've moved the ispconfig from one site to another. On one domain i forwarded to a different internal mailserver. Now i need to change that ip of empty ispconfig's/postfix' cache, because the mail forward still points to the old ip.

    Tried to alter is in the site manager/site/co domains/forward, but in the logfiles i still see postfix is trying to send to the old ip address. How can I change this?


  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Make sure that you chnag ethe DNS record for the domain so that it points to the new IP address.
  3. stanman

    stanman New Member


    Hmm... something is strange. I did that before, but it didn't work out. Now I've removed the A record an added a CNAME pointing to the new ip address. Stil in /var/log/mail.log postfix tries to send the mail to the old ip address... Is there a place in the mysql which I should alter, or is there some kind of cache inside ispconfig which points to the wrong direction?

    Thanks for you help here!
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    This can not work as cnames can not point to an IP address. cname records point to a domain and not an IP. Please remove the cname and add a A Record instead.

    This has nothing to do with mysql or ispconfig. Just amke sure that you have the correct IP address in the primary dns server of the domain. This is not nescessarily your ISPConfig server! Lao make sure that you dont have a wrong IP in the /etc/hosts file.
  5. stanman

    stanman New Member

    i've deleted the cname and added an a record to point to the right ip.
    The hostname doesn't appear in my /etc/hosts (so no wrong ip in there)

    when i send an email the the subdomain, i can see in tail /var/log/mail.log postfix tries to send it to the old ip address instead of the new one.
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    After you change the dns record, it can take up to 48 hours unteil the dns change is propagated. Also you can check the dns record with the dig command to ensure that it is correct. And you should make sure that you really changed the record on the correct server, most likely the server were you changed it now is not authoritive for the domain.
  7. stanman

    stanman New Member

    dig gives me the right ip for the subdomain. Mayb i can explain some more, so you could hopefully help me out of this.
    first i had ispconfig running at my home location, forwarding mail to a subdomain (an other mail server internal). Now i've got the ispconfig box running in a datacenter, still trying to forward the mail the internal ip address of the other mail server. This ip address I changed to the correct ip address in the dns entry of ispconfig (added the correct A record). From a ssh session i can ping and dig the corresponding ip address, so my ubuntu sees that the subdomain is at the correct ip. But.... when i try to send an email to the subdomain, postfix tries to send it to the wrong ip (the old internal mail server's ip).

    Would there be some kind of cache which postfix uses? Because the ubuntu box knows the correct ip, so does the nameserver my ubuntu box uses.

    Where does postfix gets its ip's from on ispconfig? (the mysql database or some host file)?
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    Postfix dont get any IP addresses from ISPConfig. Postfix uses the nameserver that are in /etc/resolv.conf to resolve a domain name to ist corresponding IP address.

    I guess you will have to post a part of your mail log with the real domain name so we can look this up to check wats wrong in your setup.

    Also post the output of the command:

  9. stanman

    stanman New Member


    Thanks for your help, i finally found out what was wrong. In /etc/postfix/transport I had to point to the internal server when the box was in my lan. Now it's in the data center I had to remove the subdomain from /etc/postfix/transport. Then ran:

    postmap /etc/postfix/transport
    postfix reload
    postqueue -f

    then the mails were going the right way!


Share This Page