Rodrigo Gurgel Rodrigo Gurgel - 4 months ago 105x
Linux Question

ldconfig error: is not a symbolic link

When running:

sudo /sbin/ldconfig

the following error appears:

/sbin/ldconfig: /usr/local/lib/ is not a symbolic link

When I run file:

file /usr/local/lib/
/usr/local/lib/: directory

there are three libraries that I use. I'll call them here as

Now, when I do an
on my binary it results: => not found => not found => /usr/local/lib/ (0x00216000)

But all of then are in the same folder as

Every time I run
, the same error appears:

/usr/local/lib/ is not a symbolic link

I thought
should be declared twice in
, but not:

sudo egrep '\/usr\/local' /etc/*
only includes
, so this
isn't processed, and it refers to

After a time tring I deleted all lib1 and lib2 (at some point I tested it on binary's folder), the same error occurs.


I ran into this issue with the Oracle 11R2 client. Not sure if the Oracle installer did this or someone did it here before i arrived. It was not 64-bit vs 32-bit, all was 64-bit.

The error was that was not a symbolic link.

It turned out that there were two identical files, and Removing the offending file and making it a symlink to the 1.5.2 version caused the error to go away.

Makes sense that you'd want the well-known name to be a symlink to the current version. If you do this, it's less likely that you'll end up with a stale library.