Monday 20 August 2012

Change Network settings for Public Interface in 11g R2 RAC

To change the network adaptor name from eth1 to bond1 for public interface, this is what needs to happen:

1. Stop Oracle Clusterware on all the Nodes
# ./crsctl stop crs

2. Start the bond1 Network interface on all the nodes.
# ifup bond1

3. If the eth1 interface is no longer available, the below command will not be starting the VIPs and SCAN Listeners
# crsctl start crs

4. Now lets change the network adaptor name in the gpnp profile so that the CRS will know which network adaptor to use to initiate the private interconnect traffic

# ./gpnptool edit -p=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -o=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -ovr -prf_sq=3 -net1:net_use=public -net1:net_ip=172.20.11.0 -net1:net_ada=bond1

# ./gpnptool sign -p=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -o=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -ovr -w=cw-fs:peer

# ./gpnptool put -p=/u01/app/11.2.0.3/grid/gpnp/uatwlgdb001/profiles/peer/profile.xml.16082012.new

5. Put the changes in the OCR as well
# ./oifcfg setif -global bond1/172.20.11.0:public

6. Stop VIP on the node and make the changes
# ./srvctl stop vip -n testserver
# ./srvctl modify nodeapps -n testserver -A 172.20.11.182/255.255.255.0/bond1

8. Stop the start the clusterware
# ./crsctl stop crs
# ./crsctl start crs

9. Start the clusterware on all the other nodes as well
# ./crsctl start crs

Change Network settings for Private Interconnect in 11g R2 RAC

To change the network adaptor name from eth0 to bond0 for private interconnect, this is what needs to happen:

1. Stop Oracle Clusterware on all the Nodes
# ./crsctl stop crs

2. Start the bond0 Network interface on all the nodes.
# ifup bond0

3. If the eth0 interface is no longer available, the below command will only start the Oracle High Availability Services and other service will still be down.
# crsctl start crs

4. Now lets change the network adaptor name in the gpnp profile so that the CRS will know which network adaptor to use to initiate the private interconnect traffic

# ./gpnptool edit -p=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -o=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -ovr -prf_sq=2 -net2:net_use=cluster_interconnect -net2:net_ip=172.20.15.0 -net2:net_ada=bond0

# ./gpnptool sign -p=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -o=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -ovr -w=cw-fs:peer

# ./gpnptool put -p=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new

 
5. Put the changes in the OCR as well
# ./oifcfg setif -global bond0/172.20.15.0:cluster_interconnect

6. Stop the start the clusterware
# ./crsctl stop crs
# ./crsctl start crs

7. Start the clusterware on all the other nodes as well
# ./crsctl start crs

Error CLSGPNP_DUPLICATE trying put profile

This errors is generated when you are trying to put a profile using gpnptool.

To fix it, firstly open the profile.xml file. The location of this file is at:
$ORA_CRS_HOME/gpnp/<server name>/profiles/peer/

There is a line for ProfileSequence and the value of it defines the current settings. This error heppens when the current setting of ProfileSequence in the profile.xml file is same as the setting in the new file you are trying to put.

Hence to fix it, increase the setting of -prf_sq input in gpnptool command to be higher.
For example:
I am putting a file called /u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new. My current value for ProfileSequence in profile.xml is 3. Hence, the value for -prf_sq parameter should be 4
# ./gpnptool edit -p=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -o=/u01/app/11.2.0.3/grid/gpnp/testserver/profiles/peer/profile.xml.new -ovr -prf_sq=4
# ./gpnptool sign -p=/u01/app/11.2.0.3/grid/gpnp/uatwlgdb001/profiles/peer/profile.xml.new -o=/u01/app/11.2.0.3/grid/gpnp/uatwlgdb001/profiles/peer/profile.xml.new -ovr -w=cw-fs:peer
# ./gpnptool put -p=/u01/app/11.2.0.3/grid/gpnp/uatwlgdb001/profiles/peer/profile.xml.new

The error should not happen now.

Sunday 29 July 2012

NFS Mount Causes ORA-27086: unable to lock file – already in use

The following error can occur with other errors if you have a database on NFS mount point:
ORA-27086: unable to lock file – already in use

To fix it, you can simply do the following as root user:

Check if 'nfslock' service is running:
# service nfslock status
rpc.statd is stopped


Start the 'nfslock' service:
# /etc/init.d/nfslock start
Starting NFS statd:                                        [  OK  ]


Check if 'nfslock' service is running:
# service nfslock status
rpc.statd (pid  XXXX) is running...


Ensure the 'nfslock' service start up automatically when the server reboots:
# chkconfig nfslock on

Once the 'nfslock' service is up and running, you should be able to start your database without those locking errors.