After installing clamav on a server, it was showing up the error ”/usr/sbin/clamd: error while loading shared libraries: cannot open shared object file: No such file or directory” while running clamscan.


Find the path of

libiconv: /usr/local/lib/ /usr/local/lib/

Then to check for the shared library dependencies of exim & clamd,

ldd /usr/sbin/exim & ldd /usr/sbin/clamd where I noticed that the library path ”/usr/local/lib” was not included.

For rectifying this,include the path /usr/local/lib in, then run ldconfig which should create/refresh links to the shared libraries mentioned in

And also add the following  entry

LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib in the exim startup file (this is not needed though , if the previous step works)

This should fix it!

Contact Us On WhatsApp