Monday, May 29, 2017

lsnodes: error while loading shared libraries: libskgxn2.so: cannot open shared object file: No such file or directory

Seeing error "lsnodes: error while loading shared libraries: libskgxn2.so: cannot open shared object file: No such file or directory" when trying to extend the DB home on to the RAC 2nd node.


Seeing below Error:

INFO: /u01/app/oracle/product/12.1.0.2/db_1/oui/bin/../bin/lsnodes: error while loading shared libraries: libskgxn2.so: cannot open shared object file: No such file or directory
INFO: Vendor clusterware is not detected.
INFO: Error ocurred while retrieving node numbers of the existing nodes. Please check if clusterware home is properly configured.
SEVERE: Error ocurred while retrieving node numbers of the existing nodes. Please check if clusterware home is properly configured.
INFO: Alert Handler not registered, using Super class functionality
INFO: Alert Handler not registered, using Super class functionality
INFO: User Selected: Yes/OK


This error is due to the wrong lsnodoes in DB_HOME.

The solution is to create the following symbolic link from GI Home to DB home on Node1 before adding the 2nd node.

As the oracle db user (oradba):

$ export GRID_HOME=/u01/app/12.1.0.2/grid
$ export DB_HOME=/u01/app/oracle/product/12.1.0.2/db_1


$ cd $DB_HOME/oui/bin
$ mv lsnodes lsnodes.old
$ ln -s $GRID_HOME/bin/olsnodes $DB_HOME/oui/bin/lsnodes
$ ln -s $GRID_HOME/bin/olsnodes.bin $DB_HOME/oui/bin/lsnodes.bin

Now retry to add the oracle home on 2nd node.