Change emails hostname

Discussion in 'Installation/Configuration' started by zeeman, Jun 25, 2007.

  1. zeeman

    zeeman New Member

    Hi!

    I use ISPconfig 2.2.14 for some weeks.

    The hostname of my server is something like
    Code:
    # hostname
    static.<IP>.clients.your-server.de
    
    This is the name of the server given by my ISP Hetzner.

    There are some .de and .com-domains an this server and everything works great.

    Only emails from postfix itself (like sender not found etc) are a little bit ugly:
    Code:
    This is the Postfix program at host static.<ip>.clients.your-server.de.
    
    I'm sorry to have to inform you that your message 
    
    I think postfix gets its name from hostname.
    Can i change it to something like somedomain.de?

    I tried changing main.cf this way:
    Code:
    myhostname = mail.somedomain.de
    
    But this results in looping emails:
    Code:
    relay=none, delay=0, status=bounced (mail for mail.somedomain.de
     loops back to myself)
    
    I guess it's because somedomain.de is already an virtual domain on this server.

    Any ideas how to change the hostname?
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Please add mail.somedomain.de at the en of the file /etc/postfix/virtusertable after you set "myhostname = mail.somedomain.de" in main.cf and then restart postfix.
     
  3. zeeman

    zeeman New Member

    Code:
    # cat main.cf|grep ^myhostname
    myhostname = mail.somedomain.de
    
    Code:
    # tail -n2 virtusertable
    #### MAKE MANUAL ENTRIES BELOW THIS LINE! ####
    mail.somedomain.de
    
    Code:
    # postmap /etc/postfix/virtusertable
    postmap: warning: /etc/postfix/virtusertable, line 254: expected format: key whitespace value
    
    Any ideas?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Why do you run postmap? The local-host-names is not a hash database. I said that you should restart postfix and not to run postmap.
     
  5. zeeman

    zeeman New Member

    local-host-names?
    I guess you mean in your first post also local-host-names and not virtusertable.

    Works great
    Thanks!
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    You are right of course, sorry that I mixed up the filenames. I guess I need anothe cup of coffe ;)
     
  7. zeeman

    zeeman New Member

    no problem.

    but help here is so fast. thanks a lot!
     

Share This Page