Operating System - HP-UX
1833813 Members
2940 Online
110063 Solutions
New Discussion

Hostname chagnes for the nodes in the Serviceguard cluster environment.

 
PrasannaKumari
Contributor

Hostname chagnes for the nodes in the Serviceguard cluster environment.

I have a HP-UX service guard cluster setup. For some reason, I had to change the hostname of one of the nodes. The SG cluster commands are not responding after changing the hostname of the node. Can you please let me know how the hostname of a node can be changed in this kind of setup.
7 REPLIES 7
Sandeep_Chaudhary
Trusted Contributor

Re: Hostname chagnes for the nodes in the Serviceguard cluster environment.

After changing hostname u have to make changes in ASCII configuration file and recompile and restart cluster
Ivan Krastev
Honored Contributor

Re: Hostname chagnes for the nodes in the Serviceguard cluster environment.

See reconfigurations for cluster and what can be made online - http://docs.hp.com/en/B3936-90122/ch07s04.html#ceggjfbd

regards,
ivan
Deepak Kr
Respected Contributor

Re: Hostname chagnes for the nodes in the Serviceguard cluster environment.

Hi,

Follow the steps:
steps to change hostname of nodes in serviceguard cluster environment:
========================================================================


In order to change the hostname,number of system and cluster files must be edited, the server must be rebooted, and the cluster configuration

file must be re-applied.Use the following steps to complete the changeover.


1. If the present cluster configuration does not match the present
hardware configuration, further cluster modifications may compound
unresolved issues. Determine if the present cluster binary is still
compatible with the cluster hardware and resolve the issues as deemed
necessary before proceeding with this document:

# cd /etc/cmcluster
# cmgetconf CONF # create a cluster ASCII from the binary
# cmcheckconf -C CONF # verify the binary against the hardware

If cmcheckconf fails, it may be necessary to dissolve the present
cluster and create a new ASCII file. This requires that the cluster
be halted:

# cmhaltcl
# cmdeleteconf

(The creation of the new cluster configuration file comes in step 10.)

2. Perform cmhaltnode on the node receiving the new hostname.

3. Execute the set_parms hostname command. This will change the
hostname reference in the following files:

/etc/rc.config.d/netconf
/etc/hosts

4. On each node where they exist, change the NODE_NAME references in both
the cluster and package configuration files on:

/etc/cmcluster/cmclconfig.ascii (cluster ASCII file)
NODE_NAME

/etc/cmcluster// (package config file)
NODE_NAME

5. Update these files on both hosts with the new hostname:
~root/.rhosts or /etc/cmcluster/cmclnodelist
/etc/hosts.equiv
/etc/hosts

Update any DNS name servers as well.

6. If any, update references to the old hostname in package control
scripts. References to floating or relocatable IP addresses or names
should not be affected.

7. On the server being renamed, edit the /etc/rc.config.d/cmcluster
file to disable it's ability to join the cluster on reboot:
AUTOSTART_CMCLD=0

8. Reboot the server with the new hostname.

9. Verify hostname change:
# uname -a ; hostname

10. If the cluster was dissolved in step 1, create a new cluster ASCII file:

# cmquerycl -C /etc/cmcluster/CONF -n nodeA -n nodeB

11. Verify the configuration files and update the cluster binary file.
Example:

# cd /etc/cmcluster
# cmcheckconf -C cluster.ascii -P pkg1/pkg1.conf -P pkg2/pkg2.conf ...
# cmapplyconf -C cluster.ascii -P pkg1/pkg1.conf -P pkg2/pkg2.conf ...

12. Use the cmrunnode command to bring the
node into the cluster. Move packages to it as necessary.

13. Edit the /etc/rc.config.d/cmcluster file on each node
to enable automatic cluster startup upon system boot.
AUTOSTART_CMCLD=1

regds,
Deepak
"There is always some scope for improvement"
Sandeep_Chaudhary
Trusted Contributor

Re: Hostname chagnes for the nodes in the Serviceguard cluster environment.

halt the cluster
cmhaltcl {clustername}

change hostname on node{change /etc/rc.config.d/netconf also}

add new hostsnames and userids (like root) to /etc/cmcluster/cmnodelist

change hostname in /etc/cmcluster/{clusterasciifile}

cmscancl -n nodeB -o /tmp/file

cmquerycl -C config.ascii -n node A -n nodeB

cmcheckconf -v -C cluster.ascii

cmapplyconf -v -C cluster.ascii

replicate this file to alternam enode.

start the cluster
cmruncl {clustername}
Sandeep_Chaudhary
Trusted Contributor

Re: Hostname chagnes for the nodes in the Serviceguard cluster environment.

do not forget to update /.rhosts
Prashanth Waugh
Esteemed Contributor

Re: Hostname chagnes for the nodes in the Serviceguard cluster environment.

Hi Prasanna,

if ur not using .rhost then put the entry in /etc/cmcluser/nodelist

Regards
Prashant
For success, attitude is equally as important as ability
Dax
New Member

Re: Hostname chagnes for the nodes in the Serviceguard cluster environment.

Hi,

I am new for HP-UX and Service Guide.

I had followed procedure according to Deepak for changing host name.

But after rebooting server according to step 8 when I fire "cmviewcl" on node it's show "Permission denied to 127.0.0.1".

I had double check "/etc/hosts,/etc/cmcluster/cmclnodelist,~/.rhosts" but problem is same.

If I revert back host name change procedure then I am able to access my cluster.

Currently My Service Guard is working fine with my old host name.
Thnx