其他分享
首页 > 其他分享> > How to rename the hostname in RAC

How to rename the hostname in RAC

作者:互联网

To BottomTo Bottom

In this Document

  Goal
  Solution
  References

 

APPLIES TO:

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.

  1. (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
  2. (N1, root) Run the command:
    • $GI_HOME/crs/install/rootcrs.sh -deconfig -force
  3. (N2, GI User) Run the command:
    • $GI_HOME/bin/crsctl delete node -n <N1>
  4. (N1, root) Rename the host to <new_host_name> in the host OS using the host name change procedure for the particular OS.
  5. (N2, GI User) Run the command :
    • $GI_HOME/addnode/addnode.sh -silent -noCopy "CLUSTER_NEW_NODES=<N1>" "CLUSTER_NEW_VIRTUAL_HOSTNAMES=<N1-vip>" "CLUSTER_NEW_NODE_ROLES=hub"
  6. (N1, root) Run the command:
    • $GI_HOME/root.sh ==>5 minutes
  7. (N1, RAC User) Create the DB instance on the node renamed.
    • srvctl add instance -db <db_unique_name> -instance <inst_name> -node <new_node_name>

 
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

标签:rename,node,RAC,instance,hostname,change,How,User,GI
来源: https://www.cnblogs.com/yaoyangding/p/15777359.html