Postfix and hostname

I am running Joomla on a server with virtualmin. When someone uses the contactform the mail gets bounced at the receiving end because postfix ads a X-Postfix-Sender: rfc822; xxxxx@h1382018.localdomain.
I’ve tried to change the hostname with hostname to the name of one of the sites. From that moment on, mail to people on that site got bounced, so i changed back to localhost.localdomain

What can i do to get everything working?<br><br>Post edited by:, at: 2008/11/25 08:35

So, having a server named anything.localdomain is a terrible idea and will never work right. You seem to have now figured that out. :wink:

You need to properly set the hostname of your system, and insure it is a hostname that resolves for the rest of the world. Then, restart the postfix service so it knows its own name.

If you’d used the script, it should have refused to install at all until you’d set a proper fully qualified domain name for the system. But maybe if the hostname is something weird, it might not have detected that it was a bogus name.

Problem solved. I had to use as FQDN.

But never had troubles before. Only this one script did not work.