<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2655.35">
<TITLE>RE: [Nagios-users] libgd linking errors</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=2>You should check the version of the GD library you've installed</FONT>
<BR><FONT SIZE=2>go to <A HREF="http://www.boutell.com/gd/" TARGET="_blank">http://www.boutell.com/gd/</A></FONT>
<BR><FONT SIZE=2>version 1.8.4 and 2.0.15 are available</FONT>
<BR><FONT SIZE=2>1.8.4 is known to be stable, don't know for the other</FONT>
</P>

<P><FONT SIZE=2>hope it helps</FONT>
<BR><FONT SIZE=2>Regards,</FONT>
</P>

<P><FONT SIZE=2>Guilhain Rouyer</FONT>
<BR><FONT SIZE=2>Network Engineer</FONT>
<BR><FONT SIZE=2>+33(1)49213834</FONT>
<BR><FONT SIZE=2>guilhain.rouyer@cetelem.fr</FONT>
</P>
<BR>

<P><FONT SIZE=2>-----Message d'origine-----</FONT>
<BR><FONT SIZE=2>De : Tielman De Villiers [<A HREF="mailto:tvilliers@Lastminute.com">mailto:tvilliers@Lastminute.com</A>]</FONT>
<BR><FONT SIZE=2>Envoyé : mardi 8 juillet 2003 15:58</FONT>
<BR><FONT SIZE=2>À : 'nagios-users@lists.sourceforge.net'</FONT>
<BR><FONT SIZE=2>Objet : [Nagios-users] libgd linking errors</FONT>
</P>
<BR>

<P><FONT SIZE=2>hi,</FONT>
</P>

<P><FONT SIZE=2>nagios version: 1.1</FONT>
<BR><FONT SIZE=2>platform : suse-linux (2.4.10)</FONT>
<BR><FONT SIZE=2>This is a non-root install, ie in /home/user</FONT>
<BR><FONT SIZE=2>because of some other program compatibilies, a couple of custom libries have</FONT>
<BR><FONT SIZE=2>been installed, relevant to nagios:</FONT>
<BR><FONT SIZE=2>/home/lib/libgd.so</FONT>
</P>

<P><FONT SIZE=2>Here are the configure options:</FONT>
</P>

<P><FONT SIZE=2>--with-cgiurl=/nagios/cgi-bin --with-htmurl=/nagios \</FONT>
<BR><FONT SIZE=2>--with-nagios-user=xxx --with-nagios-grp=xxx \</FONT>
<BR><FONT SIZE=2>--with-command-user=xxx --with-command-grp=xxx \</FONT>
<BR><FONT SIZE=2>--with-init-dir=/home/user/bin/ \</FONT>
<BR><FONT SIZE=2>--with-lockfile=/home/user/nagios/var/nagios.lock \</FONT>
<BR><FONT SIZE=2>--with-gd-lib=/home/user/lib --with-gd-inc=/home/user/include \</FONT>
<BR><FONT SIZE=2>--with-pgsql-lib=/home/user/lib --with-pgsql-inc=/home/user/include \</FONT>
<BR><FONT SIZE=2>--with-template-objects --with-template-extinfo \</FONT>
<BR><FONT SIZE=2>--enable-embedded-perl</FONT>
</P>

<P><FONT SIZE=2>It compiles okay and </FONT>
<BR><FONT SIZE=2>ldd /home/user/nagios/sbin/trends.cgi gives:</FONT>
<BR><FONT SIZE=2>        libgd.so.2 => /home/user/lib/libgd.so.2 (0x40016000)</FONT>
<BR><FONT SIZE=2>        libz.so.1 => /lib/libz.so.1 (0x40060000)</FONT>
<BR><FONT SIZE=2>        libm.so.6 => /lib/libm.so.6 (0x4006f000)</FONT>
<BR><FONT SIZE=2>        libpng.so.2 => /usr/lib/libpng.so.2 (0x40091000)</FONT>
<BR><FONT SIZE=2>        libjpeg.so.62 => /home/user/lib/libjpeg.so.62 (0x400c3000)</FONT>
<BR><FONT SIZE=2>        libc.so.6 => /lib/libc.so.6 (0x400e2000)</FONT>
<BR><FONT SIZE=2>        libXpm.so.4 => /usr/X11R6/lib/libXpm.so.4 (0x40209000)</FONT>
<BR><FONT SIZE=2>        libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x40218000)</FONT>
<BR><FONT SIZE=2>        libfreetype.so.6 => /home/user/lib/libfreetype.so.6 (0x402fb000)</FONT>
<BR><FONT SIZE=2>        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)</FONT>
</P>

<P><FONT SIZE=2>But when I use the browser interface on trends.cgi, I get a cgi error with</FONT>
<BR><FONT SIZE=2>this in the log file:</FONT>
<BR><FONT SIZE=2>trends.cgi: error while loading shared libraries: libgd.so.2: cannot open</FONT>
<BR><FONT SIZE=2>shared object file: No such file or directory</FONT>
<BR><FONT SIZE=2>[Tue Jul  8 13:50:26 2003] [error] [client xxx] Premature end of script</FONT>
<BR><FONT SIZE=2>headers: /home/user/nagios/sbin/trends.cgi</FONT>
</P>

<P><FONT SIZE=2>When I do a simple get call from the command line (after export</FONT>
<BR><FONT SIZE=2>REQUEST_METHOD=GET) I get a correct reply.</FONT>
</P>

<P><FONT SIZE=2>What am i missing here?</FONT>
</P>

<P><FONT SIZE=2>(The same kind of errors show when I try to use PostgreSQl to log the data,</FONT>
<BR><FONT SIZE=2>ie the CGI scripts cannot find libpq ...)</FONT>
</P>
<BR>
<BR>

<P><FONT SIZE=2>Thanks</FONT>
</P>

<P><FONT SIZE=2>Tielman de Villiers</FONT>
<BR><FONT SIZE=2>Back Office Developer</FONT>
<BR><FONT SIZE=2>Address: 4 Buckingham Gate, London SW1E 6JP </FONT>
<BR><FONT SIZE=2>Tel: +44(0)20.7802.4343</FONT>
<BR><FONT SIZE=2>Fax: +44(0)20.7802.9302 </FONT>
<BR><FONT SIZE=2>email: tvilliers@lastminute.com</FONT>
</P>

<P><FONT SIZE=2>do something lastminute.com</FONT>
</P>
<BR>
<BR>

<P><FONT SIZE=2>-------------------------------------------------------</FONT>
<BR><FONT SIZE=2>This SF.Net email sponsored by: Free pre-built ASP.NET sites including</FONT>
<BR><FONT SIZE=2>Data Reports, E-commerce, Portals, and Forums are available now.</FONT>
<BR><FONT SIZE=2>Download today and enter to win an XBOX or Visual Studio .NET.</FONT>
<BR><FONT SIZE=2><A HREF="http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01" TARGET="_blank">http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01</A></FONT>
<BR><FONT SIZE=2>_______________________________________________</FONT>
<BR><FONT SIZE=2>Nagios-users mailing list</FONT>
<BR><FONT SIZE=2>Nagios-users@lists.sourceforge.net</FONT>
<BR><FONT SIZE=2><A HREF="https://lists.sourceforge.net/lists/listinfo/nagios-users" TARGET="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</A></FONT>
<BR><FONT SIZE=2>::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. </FONT>
<BR><FONT SIZE=2>::: Messages without supporting info will risk being sent to /dev/null</FONT>
</P>

</BODY>
</HTML>