Segmentation Fault on export LD_LIBRARY_PATH
I am using both Centos & RedHat distributions.
In my RedHat one, I tried echo $LD_LIBRARY_PATH which returns a blank line. I added my lib dir as export LD_LIBRARY_PATH=/mylibdir. Now after I done this, even my ls throws me segmentation fault. I even tired export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/mylibdir. I couldn't run my application too. It too shows Segmentation fault.
I am doing this all under a user who is not root. I need this because my application comes in a RPM package which can be relocated and installed in the user directory instead of a default one. Now in the installed path all the libraries will be present and I have to add them to LD_LIBRARY_PATH.
But for some reason, it shows segmentation fault afterwards. I tried this in CentOS as well, even as a non root user which works fine as expected. My RedHat that shows segmentation fault is Red Hat Enterprise Linux Client release 5.7 (Tikanga).
What am I missing here?