Oracle Database Exadata Express Cloud Service - Version N/A and later Oracle Database Exadata Cloud Machine - Version N/A and later Oracle Cloud Infrastructure - Database Service - Version N/A and later Oracle Database Backup Service - Version N/A and later Oracle Database Cloud Exadata Service - Version N/A and later Information in this document applies to any platform.
GOAL
Often, the host names or node names of the nodes in a cluster need to be changed, so this document provides a supported procedure to change the host names or node names in 12.1 and higher version. Please note that the steps in here works only if the cluster has multiple nodes.
On Oracle Restart (SIHA) environment where only one node is running, please use the steps in How to change Hostname / IP for a Grid Infrastructure Oracle Restart Standalone Configuration (SIHA) Document 1552810.1
SOLUTION
To change the host name or node name, perform the following seven steps.
N1 is the node being removed and N2 is one of the surviving nodes. The user is RAC User (DB HOME Owner), GI User (GI HOME owner), or root.
For example, (N1, RAC User) means perform the step as RAC User (DB HOME owner) on the node that is being removed.
(N1, RAC User) Remove the DB instance running on the node being renamed.
a. srvctl disable instance -db <db_unique_name> -instance <inst_name>
b. srvctl stop instance -db <db_unique_name> {-node <old_node_name> | -instance <inst_name>} -stopoption NORMAL -failover
c. srvctl remove instance -db <db_unique_name> -instance <inst_name> -force
(N1, root) Run the command:
$GI_HOME/crs/install/rootcrs.sh -deconfig -force
(N2, GI User) Run the command:
$GI_HOME/bin/crsctl delete node -n <N1>
(N1, root) Rename the host to <new_host_name> in the host OS using the host name change procedure for the particular OS.
The above instruction is what is needed to change the hostname from Oracle, but that you have to change OS configuration such as ssh and DNS to reflect new hostname.
REFERENCES
NOTE:1552810.1 - How to change Hostname / IP for a Grid Infrastructure Oracle Restart Standalone Configuration (SIHA) 11.2 and Later NOTE:1377349.1 - How to Deconfigure/Reconfigure(Rebuild OCR) or Deinstall Grid Infrastructure