Help - Search - Members - Calendar
Full Version: HOWTO: Gpan's MRTG for RH 8 w/ CPanel!
The Planet Forums > Control Panels > cPanel/WHM > Cpanel/WHM HOWTOs
Brandonk
FIXES! FIXES! FIXES!

Ok, after spending a lot of time looking for answers, I finally got MRTG to work! This is for REDHAT 8.0!!!!!!!!

Let's make sure we're on the same page by updating the MRTG RPM:

# rpm -e mrtg-2.9.17-4ct
# rpm http://download.cheetaweb.com/mrtg-2.9.17-...cpanel.i386.rpm -Uvh

Get rid of the ugly UTF error:

# pico /etc/sysconfig/i18n

change LANG to LANG="en_US"

# reboot

you need to reboot the machine for these changes to take place

# set | grep LANG

verify the changes took place

Clean up the libpng issues

# rpm -e gnome-libs-1.4.1.2.90-22

we have to remove this in order to remove the others (we'll put it back on, don't worry)

# rpm -e libpng10-1.0.13
# rpm -e libpng10-devel-1.0.13-6

Now we put the things we just removed back on, but we use the correct versions.

Login to WHM
Click on Install RPMs
Force install these:
libpng
libpng-devel
gnome-libs

Now we clean up another error that would surface

# cd /usr/lib
# ln -s libpng.so.3 libpng.so.2

Now let's restart MRTG and go look at those graphs!

# /etc/rc.d/init.d/mrtg restart
cpanelrich
did everything ya said

then tried to restart mrtg

got

WARNING: rateup died from Signal 11
with Exit Value 0 when doing router 'uptime'
Signal was 11, Returncode was 0
libpng warning: Application was compiled with png.h from libpng-1.2.2
libpng warning: Application is running with png.c from libpng-1.0.13
gd-png: fatal libpng error: Incompatible libpng version in application and

library
WARNING: rateup died from Signal 11
with Exit Value 0 when doing router 'cpu'
Signal was 11, Returncode was 0
libpng warning: Application was compiled with png.h from libpng-1.2.2
libpng warning: Application is running with png.c from libpng-1.0.13
gd-png: fatal libpng error: Incompatible libpng version in application and

library
WARNING: rateup died from Signal 11
with Exit Value 0 when doing router 'localhost.mem'
Signal was 11, Returncode was 0
libpng warning: Application was compiled with png.h from libpng-1.2.2
libpng warning: Application is running with png.c from libpng-1.0.13
gd-png: fatal libpng error: Incompatible libpng version in application and

library
WARNING: rateup died from Signal 11
with Exit Value 0 when doing router 'mail-host-email-totals'


i checked rpm -qa on libpng, and libpng-1.0.13 isnt even install.... i did a rpm -e --nodeps libpng and got rid of it, and tried to force install libpng again

didnt help


any ideas?
phenx
NICE!

I'll point out that on my Redhat 9 boxes, this did NOT require a restart, and it also worked perfectly!

Thanks! icon_biggrin.gif
Brandonk
cpanel rich, you need to do these steps again:

QUOTE
Clean up the libpng issues

# rpm -e gnome-libs-1.4.1.2.90-22

we have to remove this in order to remove the others (we'll put it back on, don't worry)

# rpm -e libpng10-1.0.13
# rpm -e libpng10-devel-1.0.13-6

Now we put the things we just removed back on, but we use the correct versions.

Login to WHM
Click on Install RPMs
Force install these:
libpng
libpng-devel
gnome-libs

Now we clean up another error that would surface

# cd /usr/lib
# ln -s libpng.so.3 libpng.so.2

cpanelrich
i did i did!

even made sure i forced em out (libpng was complaining about dependencies so i did an rpm -e --nodeps libpng

the others removed fine

and rpm -qa 'ed all 3 to make sure they were gone.

then re-installed

still get the weird png.c / png.h error (damn libpng!)

i'll keep working on it, will keep you update, if you have any other ideas, shoot em here.
Brandonk
Remove every single libpng and then when you reinstall, make sure you DO NOT install the ones with "10" next to them.
gpan
I guess I should rebuild it against current libpng icon_razz.gif
cpanelrich
i went ahead and just installed it from scratch, always fun... rpm -Uvh is just way easier icon_biggrin.gif
romer
Wonderfull, works fine.


Romero, Ricardo ( Brazil )
LighthousePoint
Any word on if/when RS is offering some RH8/9 boxes? Okay, I know Ensim is the most picky-piece-of-software ever, and will not run on it, but what about the plain boxes? I've been messing around with RH9 recently, and truly love it.
steve248
Will this work with RH 7.3?
indyjon
QUOTE
Originally posted by gpan
I guess I should rebuild it against current libpng icon_razz.gif


Did you by chance build this with libpng?

I am assuming it will work on a plain redhat 8 box....
jruyle
I got this error:

-------------------------------------------------------

Shutting down MRTG: [FAILED]
Starting MRTG: Daemonizing MRTG ...

root@water [/usr/lib]# ls: /var/spool/exim/input/*-H: No such file or directory
ls: /var/spool/exim/input/*-H: No such file or directory
ls: /var/spool/exim/input/*-H: No such file or directory

-------------------------------------------------------

What do you suggest?
Urban
Is there any Red Hat 9.0 version of this MRTG RPM available?
indyjon
I used the stock mrtg that came with RH9. I just copied and slightly modified the config files that gpan's ensim rpm created on to my rh9 box. ... all is well.
Urban
Sorry to sound like an idiot, I am rather new to this. However, how would I go about using the one that comes with RH 9? Thanks for any help in advance icon_smile.gif
phenx
QUOTE
Originally posted by jruyle
I got this error:

-------------------------------------------------------

Shutting down MRTG:                                        [FAILED]
Starting MRTG: Daemonizing MRTG ...

root@water [/usr/lib]# ls: /var/spool/exim/input/*-H: No such file or directory
ls: /var/spool/exim/input/*-H: No such file or directory
ls: /var/spool/exim/input/*-H: No such file or directory

-------------------------------------------------------

What do you suggest?


that is perfectly normal.
ramprage
QUOTE
Originally posted by steve248
Will this work with RH 7.3?


So will it?
gpan
Its built on and supposed to work on 7.3 by default.
ricu5
Installed without a problem as far as I can tell

everytime cron runs I get this error
Daemonizing MRTG ...
ERROR: I Quit! Another copy of mrtg seems to be running. Check /etc/mrtg/mrtg.pid

I only see one running..probably the one it is complaining about...
I can access the stats page..no problem

I kill the process and she still produces the error

mrtg is set to activate at boot
and cron runs at 5 min intervals

any ideas

Thanks Rich
ricu5
removed the cron entry
the error is gone
stats page seems to update as times are changing on the page

Rich
J&SHosting
I did everything you said and i get the following:

root@smoky [/]# service mrtg start
mrtg: unrecognized service

root@smoky [/]# /etc/rc.d/init.d/mrtg restart
-bash: /etc/rc.d/init.d/mrtg: No such file or directory

root@smoky [/]# service mrtg stop
mrtg: unrecognized service


I did everything you said 3 times and it still dont work :-/

Please help me out.
Thanks.
Sean
andy18
ok..i have resinstalled the libpng and it works now..but some of the graph is not showing up , such as the daily TCP... I will need to refresh the page to make the graph shows up and the strange thing is that the LOGO at the bottom of the page is not showing up this time..:confused:

I am getting the error in shell :

root@cyberia [/home/download/mrtg]# WARNING: Running '/etc/mrtg/system network eth0': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/system network eth0'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/system tcp': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/system tcp'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/system load': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/system load'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/system swap': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/system swap'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/system processes': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/system processes'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/system uptime': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/system uptime'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/email-totals1 MAIL-HOST': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/email-totals1 MAIL-HOST'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/email-queue1 MAIL-HOST': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/email-queue1 MAIL-HOST'
Maybe the external command did not even start. (No such file or directory)

WARNING: Running '/etc/mrtg/email-count1 MAIL-HOST': No such file or directory
WARNING: Could not get any data from external command '/etc/mrtg/email-count1 MAIL-HOST'
Maybe the external command did not even start. (No such file or directory)

thanks,
andy18
how can I password protect it to prevent other users from accessing it?I have tried searching around the directory but was not able to find the directory..

I tried the directory found in /etc/mrtg but the page is not password protected when I preview it in browser...
andy18
Hi,

looks strange as it does not shows any reports on the traffic menu.

http://203.115.195.115/mrtg/
hbouma
Hi everyone,

I followed the instructions here (more or less. trying to force install RPMs from the RPM package installer kept reinstalling other packages like mrtg again) on my new RedHat 9 cPanel Dual Xeon server here and it seems to work. There is a ton of crap dependant on gnome-libs though:

ORBit is needed by gnome-libs-1.4.1.2.90-32
imlib is needed by gnome-libs-1.4.1.2.90-32
libIIOP.so.0 is needed by gnome-libs-1.4.1.2.90-32
libORBit.so.0 is needed by gnome-libs-1.4.1.2.90-32
libORBitCosNaming.so.0 is needed by gnome-libs-1.4.1.2.90-32
libORBitutil.so.0 is needed by gnome-libs-1.4.1.2.90-32
libgdk_imlib.so.1 is needed by gnome-libs-1.4.1.2.90-32
libpng.so.2 is needed by gnome-libs-1.4.1.2.90-32

Which is strange because RPM didn't how gnome-libs being installed.

Anyway, hopefully nothing is broken from this.

Anyone know how to keep cPanel from updating mrtg in future rpm grabs? Thanks!

Hal
kris1351
I keep getting the following:

WARNING: rateup died from Signal 11
with Exit Value 0 when doing router 'tcp'
Signal was 11, Returncode was 0
libpng warning: Application was compiled with png.h from libpng-1.2.2
libpng warning: Application is running with png.c from libpng-1.0.13
gd-png: fatal libpng error: Incompatible libpng version in application and library


I have uninstalled libpng and gnome-libs as the guide says, but everytime you re-install gnome-libs it puts the 1.0.13 version back in. I keep getting broken graph links because of this.
kenny6855
When I am trying to install gpan's MRTG
I got this error message!!


error: Failed dependencies:
perl >= 5.004 is needed by mrtg-2.9.17-1cpanel
gd is needed by mrtg-2.9.17-1cpanel
/bin/sh is needed by mrtg-2.9.17-1cpanel
Suggested resolutions:
bash-2.05b-20.i386.rpm
gd-1.8.4-11.i386.rpm
perl-5.8.0-88.i386.rpm

---------------------------
Everytime when I am trying to update some software through WHM (Software/Update Server Software)
I will got a lot of error message!!
a lot of RPM are not installed!!
But I am very sure that I had installed it!!

What's the problem with my WHM??
hbouma
QUOTE
Originally posted by indyjon
I used the stock mrtg that came with RH9.  I just copied and slightly modified the config files that gpan's ensim rpm created on to my rh9 box. ...  all is well.


Yeah, after doing it the hard way the last time this is what I do now. I also got tired of cPanel blowing away the rpm each time I do an update. So if I just copy the modded files over and its all good. This method just worked for me on the new RedHat Enterprise server I picked up tonight as well.

Hal
adstreamer
Basically, it seems to work fine on my RH EL3 w/ cPanel, however I wonder about the following stats which I keep getting for the CPU usage...

Max user: 528.0 %CPU
Average user: 408.0 %CPU
Current user: 480.0 %CPU

Max total: 568.0 %CPU
Average total: 416.0 %CPU
Current total: 488.0 %CPU


How can those figures possibly be correct? Maybe I am blindfolded and crazy, but I thougt that more than 100% isn't possible icon_wink.gif , is it?

:confused:

Any idea?
Any explanation?

Thanks in advance.

Karen
hbouma
Hi,

CPU load is always reported 10 times higher than it should be. (i.e. 520% is really 52%). My servers usually report in the 300% range on MRTG meaning its around 30% utilized.

I wonder if a mrtg graph is out for the iowait state that top shows. Would help to show how IO bound the server is at any time.

Hal
adstreamer
QUOTE
Originally posted by hbouma
Hi,

CPU load is always reported 10 times higher than it should be. (i.e. 520% is really 52%). My servers usually report in the 300% range on MRTG meaning its around 30% utilized.
Well, Thanks for that explanation. That calms me down a bit icon_smile.gif.

Karen
Ritz
I am using RH9 with P4 Cpanel server. I installed MRTG successfully with no issues. When i restart mrtg using

# service mrtg restart

Shutting down MRTG: [ OK ]
Starting MRTG: Daemonizing MRTG ...

>>>> But after some time i got these loads of errors.

# /usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'index'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'tcp'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'load'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'swap'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'processes'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'uptime'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'cpu'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'localhost.mem'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'mail-host-email-totals'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'mail-host-email-queue'
Signal was 0, Returncode was 127
/usr/bin/rateup: error while loading shared libraries: libpng.so.2: cannot open shared object file: No such file or directory
WARNING: rateup died from Signal 0
with Exit Value 127 when doing router 'mail-host-email-count'
Signal was 0, Returncode was 127

Please help
mr_dizzle
QUOTE(J&SHosting)
I did everything you said and i get the following:

root@smoky [/]# service mrtg start
mrtg: unrecognized service

root@smoky [/]# /etc/rc.d/init.d/mrtg restart
-bash: /etc/rc.d/init.d/mrtg: No such file or directory

root@smoky [/]# service mrtg stop
mrtg: unrecognized service


I did everything you said 3 times and it still dont work :-/

Please help me out.
Thanks.
Sean


did you ever get this fixed? i'm getting the same exact errors.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.