Directadmin

Webalizer: error while loading shared libraries: libgd.so.2

When you run the following, you get:

[root@server]# webalizer
webalizer: error while loading shared libraries: libgd.so.2: cannot open shared object file: No such file or directory

That means that the program is unable to find the gd library required to run it.  You should already have the library, so you just have to tell the binary linker where to find it.

Type the following:

echo “/usr/local/lib” >> /etc/ld.so.conf
ldconfig

And then try running webalizer again.  The error should be gone.

If you *don’t* have the gd library, install it:

yum install gd

Another solution, since custombuild will install it for you, just in a different location than webalizer is looking, is to link it, eg:

ln -s /usr/local/lib/libgd.so.2 /usr/lib/libgd.so.2

If webalizer is functioning correctly, you should see something similar to:

[root@server]# webalizer
Webalizer V2.01-10 (Linux 2.4.21-9.0.1.EL) English
Using logfile STDIN (clf)
Creating output in current directory
Hostname for reports is ‘es.jbmc-software.com’
History file not found…