Changing the server's hostname in Plesk

2004-10-20

After using your Plesk server for some time, you might want to, or have to change your server’s hostname. Assuming your server runs Fedora Core or RedHat, you’ll have to make changes in the following locations

  1. /etc/hosts
    Your current hostname should be here behind the server’s IP address, change this to the new hostname

  2. /etc/sysconfig/network
    You should have a HOSTNAME variable here, change this to your new hostname.

  3. /var/qmail/control/me
    This contains the old hostname, change it to your new hostname to make qmail identify itself as the new hostname.

  4. /etc/httpd/conf/httpd.include
    You should have a ServerName variable here, change it to your new hostname.

  5. Change the servers hostname while it’s running, normally this is set at boot.

    hostname <newhostname>
    
  6. Set the new hostname inside Plesk’s database:

    mysql -u admin -pcat /etc/psa/.psa.shadow
    use psa;
    update misc set val=’NEWHOSTNAME’ where param=’FullHostName’;
    
  7. Now restart Plesk to activate your changes:

    /etc/init.d/psa stopall
    /etc/init.d/psa stop
    /etc/init.d/psa start
    
plesklinux
Creative Commons License

fortune-mod-powerpuff

Adding SPF records in Plesk