VPS hostname reverted back to default valueVPS hostname reverted back to default value

Posted November 20th, 2007 in Linux/Unix/BSD

Last week I posted about how to change the hostname on CentOS. Running the hostname command worked nicely and did change the hostname, and restarting the postfix service meant it started using the new hostname. I then rebooted the VPS later on in the day, and unfortunately the hostname had defaulted back to the VPS default name, along the lines of vps347.foo.bar.example.com

I checked the /etc/sysconfig/network file and sure enough, that had reverted back to what it had been before I had edited it. So either the VPS or the Virtuozzo system which handles the virtualisation had reset it back to its previous state, or I didn't actually save my changes last time and just thought I did.

So anyway, I changed the hostname in the /etc/sysconfig/network file again, and have just confirmed now that I did indeed save it this time. The next time we reboot that VPS server I'll check if it has again reverted the network config back to its previous default VPS state.

This post is basically a reference point for me to remind me that I'm not imagining things, and that I did set the hostname correctly this time :) . If it reverts back again after the next reboot then I know I need to fix it.

Comments

blog comments powered by Disqus