Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have configured two machines to do a warm standby so that machine 2 can take the ip of machine 1 if that should fail and become its replacement. sadly, thats not enough, i need to change the hostname/fqdn too because some software relies on the local hostname and crashes if the hostname is different after the failover. so the question is: how do i change my hostname and change it back once machine 1 is back on track?

share|improve this question

Generally speaking, you can write a script which performs the necessary hostname changes to the system - both ways - and use that as a service that your failover configuration uses. If you are using the heartbeat software the /etc/ha.d/resource.d/MailTo script is a fine place to start looking for an example.

There are quite a few example resource scripts here:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.