Oracle GPnP Profile Explained
The Global Plug and Play (GPnP) Profile is a crucial component of Oracle Clusterware, particularly in Oracle Grid Infrastructure environments. It's a small XML file that plays a vital role in establishing the correct global personality and configuration of each node within an Oracle Cluster.
What is the GPnP Profile?
The GPnP profile is a small XML file typically located under GRID_HOME/gpnp/<node_name>/profiles/peer/profile.xml
. Each node in the cluster maintains a local copy of this profile. Its primary function is to provide essential configuration information that allows a node to correctly identify itself and integrate into the cluster.
The GPnP Profile is primarily maintained and managed by the GPnP Daemon (GPnPD), which runs on each node in the cluster.
What Does the GPnP Profile Contain?
The profile.xml
file contains critical configuration details that define the cluster's identity and resource locations:
Cluster Name: The unique name of the Oracle Cluster.
Network Classifications: Information about public and private (interconnect) network interfaces, including their roles and IP addresses.
Storage to be Used for Cluster Synchronization Services (CSS): This specifies the location of the Voting Disk, which is essential for cluster quorum and membership.
Storage to be Used for Automatic Storage Management (ASM):
SPFILE Location: The location of the ASM SPFILE (Server Parameter File).
ASM Disk String: The discovery string used by ASM to find its disks.
Other ASM-related configuration details.
Who Updates the GPnP Profile?
The GPnPD daemon is responsible for replicating changes to the GPnP profile. This replication occurs during:
Installation: Initial configuration during Grid Infrastructure setup.
System Boot: When a node starts up and joins the cluster.
When Updated: Whenever configuration changes are made to the cluster using specific Oracle Clusterware and ASM configuration tools.
The profile is automatically updated when changes are made using tools such as:
oifcfg
: Used to change network configurations (e.g., adding or modifying public/private interfaces).crsctl
: Used to change the location of the Voting Disk or other Clusterware resources.asmcmd
: Used to modify ASM parameters likeASM_DISKSTRING
or the ASM SPFILE location.
How is the GPnP Profile Used by Clusterware?
The GPnP profile is fundamental to the Clusterware startup process and overall cluster operation:
Clusterware Startup: To start Clusterware, the Voting Disk needs to be accessed. If the Voting Disk resides on ASM (which is common), the GPnP profile provides the necessary information (e.g., ASM Disk String and ASM SPFILE location) to locate and read the Voting Disk even before the ASM instance itself is fully up.
kfed
Utility: The Voting Disk can be read using thekfed
utility (Kernel File Edition utility) directly from the disk even if ASM is not running, leveraging the information from the GPnP profile.ASM SPFILE Search Order: When an ASM instance starts, it searches for its SPFILE in a specific order, with the GPnP profile being the first place it looks:
GPnP profile
$ORACLE_HOME/dbs/spfile<SID>.ora
$ORACLE_HOME/dbs/init<SID>.ora
Useful gpnptool
Commands
The gpnptool
utility allows you to interact with and query the GPnP profile.
How to read the entire GPnP profile:
[root@inssc3 bin]# ./gpnptool get
This command outputs the full XML content of the local GPnP profile.
How to find if GPnP Daemons are running on the local node:
[root@host01 peer]# gpnptool lfind Success. Local gpnpd found.
This confirms the local GPnPD is active.
How to find the location of the ASM SPFILE if ASM is down:
[root@host01 peer]# gpnptool getpval -asm_spf +DATA/cluster01/asmparameterfile/registry.253.783619911
This command extracts the value of the
asm_spf
parameter from the GPnP profile, showing the path to the ASM SPFILE.How to find all RD-discoverable resources of a given type:
[root@host01 peer]# gpnptool find Found 3 instances of service ‘gpnp’. mdns:service:gpnp._tcp.local.://host03:18015/agent=gpnpd,cname=cluster01,host=host03,pid=5066/gpnpd h:host03 c:cluster01 mdns:service:gpnp._tcp.local.://host02:17637/agent=gpnpd,cname=cluster01,host=host02,pid=5236/gpnpd h:host02 c:cluster01 mdns:service:gpnp._tcp.local.://host01:16633/agent=gpnpd,cname=cluster01,host=host01,pid=5206/gpnpd h:host01 c:cluster01
This command uses multicast DNS (mDNS) to discover GPnP services (and thus active GPnPDs) across the cluster, providing details like hostname, cluster name, and process ID.
Understanding the GPnP profile and its associated tools is essential for advanced troubleshooting and management of Oracle Clusterware environments.
No comments:
Post a Comment