• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

How to add aliases to main server name

JuliusT

New Pleskian
How do I add aliases to the Full hostname of the plesk server itself? I want the server to listen to 2 more names. Especially for mail, and for migratory purposes (plesk server x is a new one, the name of the old one y needs to become an alias of x later on, etc.).
I'm amazed by how hard to find this is, and there is literally nothing on it that I can find!

Of course, I can add aliases via command line, but I have no intentions of having postfix and webserver config be overwritten every time the control panel is used..
 
You can configure as many hostnames via DNS as you want, but the server
itself has only one hostname configured (/etc/hostname). And you should really
use the default plesk-configuration to send mails via the main server ip and the
server's hostname (option 1). Otherwise the chances would be high to get trouble
with sending mails out. You should also verify that your server's hostname is equal to the PTR.
 
Last edited:
What do you mean with "option 1" ? How are aliases causing 'trouble' with sending mails out? You just configure MX records properly, by setting both names in the right priority order and there will ne no problem whatsoever. My issue is: The CP does not let me add aliases for postfix or the control panel hostname to listen to. So you're basically saying: Hack the config files, add the names, and create a cronjob to re-add them everytime plesk makes changes to the config. I was trying to prevent that.
 
With option 1 I mean the first of the three available options for sending mails in the mailserver-settings.
You might get trouble sending out mails using the corresponding domain names in EHLO/HELO (the second
option for sending mails in the mailserver settings), because some Providers (like AOL) will reject mails
if the PTR does not match to the hostname used in EHLO/HELO. You can configure the PTR per domain
in the Plesk DNS settings, but usually it will be useless because the PTR (one per IP) has to be set by the
server-provider. And no, I'm not saying that you should hack the config files :)
 
Last edited:
Back
Top