Thursday, August 4, 2011

Fatal error in a UNIX box


Have you ever come across a fatal error like the one below on a seemingly perfect running environment ? well, I did face this error when trying to locate the IDs of  shared memory and semaphores of a problematic Oracle instance.

ld.so.1: sysresv: fatal: libclntsh.so.9.0: open failed: No such file or directory Killed

As usual, First GOOGLEd around but found a lot of irrelevant hits. Muttering about the situation and the lack of online help prompted me to backtrack a while and go through each and every word of the error to understand the issue. I then realized that it has got something to do with the linking of Oracle libraries.

Then I quickly queried the value of LD_LIBRARY_PATH environmental variable to see that appropriate $ORACLE_HOME/lib value was missing. I tried a vain attempt to resolve the issue by adding the missing library location to LD_LIBRARY_PATH and ran the command again, Voila!!! it worked. I was able to achieve the objective.

Conclusion :
I learnt two morals from this one, most importantly, for errors like "ld.so.1:.... fatal:" it is always good to look at the value of LD_LIBRARY_PATH as the first step towards trobleshooting it. Least importantly !!! I did not say GOOGLE when I first started babbling.....LOL

No comments: