Domain name is doubled

Tried searching for this but no luck.

Automated emails have the domain name appended twice.

Where can I fix this? I’ve tried changing the hostname to just the machine name but then it shows up as admin@server


Hi there,

Take a look in System Settings -> Module Config -> Actions upon server and user creation – there’s an option at the top called “From: address for email sent by Virtualmin” that has the email address to use, you may need to tweak it.

Thanks but it seems to be a system problem. I’ve seen the same behavior in BIND and when I run php scripts that lookup the hostname it’s displayed as

Okay, so then my questions for you are:

  • What is the output of the "hostname" command if you type that on the command line?

  • In your /etc/postfix/ file, what is the value of the "myhostname" field?

Just a thought dkcp. Have you checked your DNS records, in particular your NS record for your mail server to make sure it is properly terminated with a "." I have been caught by this a few times and the problem seems similar.

Good luck

Thanks guys and I found it eventually. It seems to go back to when I set up the server. Somehow the domain got doubled. Eventually I found and fixed that but the problem was still there. It turned out that the hostname was explicitly set in postfix and as such wasn’t updated when I fixed it at the root so to speak.