Getting cacti to gather network traffic stats

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

fsd
Posts: 21
Joined: Sat Jul 23, 2005 12:26 am

Getting cacti to gather network traffic stats

Post by fsd »

I am running cacti 0.8.6f on ubuntu (breezy badger), and running it on localhost to gather assorted system stats (mem usage, hdd usage etc) and was wanting to use it to get graphs on the bandwidth usage for eth0.

The problem is involved in actually retrieving the data, when i try to add the data query to the host, it works ok, however receives no data. When i run a verbose query, i get the following:

Code: Select all

Data Query Debug Information
+ Running data query [1].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/usr/share/cacti/site/resource/snmp_queries/interface.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.2.1.2.2.1.1'
+ No SNMP data returned
+ Found data query XML file at '/usr/share/cacti/site/resource/snmp_queries/interface.xml'
+ Found data query XML file at '/usr/share/cacti/site/resource/snmp_queries/interface.xml'
+ Found data query XML file at '/usr/share/cacti/site/resource/snmp_queries/interface.xml'
Any ideas?
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

Yah, you need to be running snmpd on the box, so that you can graph interface statistics.

Also, moved to Linux
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
fsd
Posts: 21
Joined: Sat Jul 23, 2005 12:26 am

Post by fsd »

snmpd is running, all other info is retrieved without any issues so snmpd itself is working. have tried stopping/restarting snmpd with no luck
fsd
Posts: 21
Joined: Sat Jul 23, 2005 12:26 am

Post by fsd »

Brand new manual install of 0.8.6g does the exact same thing. Have tried different snmp versions/rrdtool etc, to no effect.
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

Have you set the community correctly?

When you view the device, does it give you any snmp information at the top?
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
fata51
Posts: 17
Joined: Wed Nov 16, 2005 8:34 am

Post by fata51 »

Hello,

I have the same problem for graphing network stats of a computer with a debian sarge. SNMP informations are well displayed. Informations about processes, users, memory, disk space are well graphed. But no informations about network interface are collected...

is it a bug?

thanks
tonyurban
Posts: 6
Joined: Wed Nov 16, 2005 1:44 pm

Post by tonyurban »

Same thing with 0.8.6g install on Solaris 9. All other default snmp graphs appear to be functioning. Snmp is installed and running on the box (mrtg is working, snmpwalk functions correctly at the command line). Full paths for snmpwalk/snmpget are referenced in the settings.

Thoughts?
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

fsd wrote:Brand new manual install of 0.8.6g does the exact same thing. Have tried different snmp versions/rrdtool etc, to no effect.
Please select Verbose Query from the Device Screen and post the results. Do a snmpwalk from command line for that host and post the results as well (e.g. snmpwalk -c xxx -v 1 <host> interface)
Reinhard
tonyurban
Posts: 6
Joined: Wed Nov 16, 2005 1:44 pm

Post by tonyurban »

Here's some more info (verbose query and snmpwalk) from my solaris install:

Code: Select all

+ Running data query [1].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/var/http/htdocs/cacti-0.8.6g/resource/snmp_queries/interface.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.2.1.2.2.1.1'
+ No SNMP data returned
+ Found data query XML file at '/var/http/htdocs/cacti-0.8.6g/resource/snmp_queries/interface.xml'
+ Found data query XML file at '/var/http/htdocs/cacti-0.8.6g/resource/snmp_queries/interface.xml'
+ Found data query XML file at '/var/http/htdocs/cacti-0.8.6g/resource/snmp_queries/interface.xml'

Code: Select all

$ snmpwalk -v 1 -c xxx xxx interface              
IF-MIB::ifNumber.0 = INTEGER: 2
IF-MIB::ifIndex.1 = INTEGER: 1
IF-MIB::ifIndex.2 = INTEGER: 2
IF-MIB::ifDescr.1 = STRING: lo0
IF-MIB::ifDescr.2 = STRING: dmfe0
IF-MIB::ifType.1 = INTEGER: softwareLoopback(24)
IF-MIB::ifType.2 = INTEGER: ethernetCsmacd(6)
IF-MIB::ifMtu.1 = INTEGER: 8232
IF-MIB::ifMtu.2 = INTEGER: 1500
IF-MIB::ifSpeed.1 = Gauge32: 127000000
IF-MIB::ifSpeed.2 = Gauge32: 100000000
IF-MIB::ifPhysAddress.1 = STRING: 
IF-MIB::ifPhysAddress.2 = STRING: 0:3:ba:13:f:1b
IF-MIB::ifAdminStatus.1 = INTEGER: up(1)
IF-MIB::ifAdminStatus.2 = INTEGER: up(1)
IF-MIB::ifOperStatus.1 = INTEGER: up(1)
IF-MIB::ifOperStatus.2 = INTEGER: up(1)
IF-MIB::ifLastChange.1 = Timeticks: (0) 0:00:00.00
IF-MIB::ifLastChange.2 = Timeticks: (0) 0:00:00.00
IF-MIB::ifInOctets.1 = Counter32: 0
IF-MIB::ifInOctets.2 = Counter32: 902770111
IF-MIB::ifInUcastPkts.1 = Counter32: 2946722
IF-MIB::ifInUcastPkts.2 = Counter32: 2578297
IF-MIB::ifInNUcastPkts.1 = Counter32: 0
IF-MIB::ifInNUcastPkts.2 = Counter32: 13620
IF-MIB::ifInDiscards.1 = Counter32: 0
IF-MIB::ifInDiscards.2 = Counter32: 0
IF-MIB::ifInErrors.1 = Counter32: 0
IF-MIB::ifInErrors.2 = Counter32: 0
IF-MIB::ifInUnknownProtos.1 = Counter32: 0
IF-MIB::ifInUnknownProtos.2 = Counter32: 0
IF-MIB::ifOutOctets.1 = Counter32: 0
IF-MIB::ifOutOctets.2 = Counter32: 1173184617
IF-MIB::ifOutUcastPkts.1 = Counter32: 2946746
IF-MIB::ifOutUcastPkts.2 = Counter32: 2685707
IF-MIB::ifOutNUcastPkts.1 = Counter32: 0
IF-MIB::ifOutNUcastPkts.2 = Counter32: 17569
IF-MIB::ifOutDiscards.1 = Counter32: 0
IF-MIB::ifOutDiscards.2 = Counter32: 0
IF-MIB::ifOutErrors.1 = Counter32: 0
IF-MIB::ifOutErrors.2 = Counter32: 2
IF-MIB::ifOutQLen.1 = Gauge32: 0
IF-MIB::ifOutQLen.2 = Gauge32: 0
IF-MIB::ifSpecific.1 = OID: SNMPv2-SMI::zeroDotZero
IF-MIB::ifSpecific.2 = OID: SNMPv2-SMI::zeroDotZero
lga
Posts: 21
Joined: Mon May 23, 2005 4:39 am
Location: Belgium

Post by lga »

I've the same problem on RHEL4 and Debian with Cacti 0.8.6g and cactid 0.8.6f-1.
All works but not interface check and traffic.
By example, I see SNMP information of routers but not the interfaces of routers.

Bug ?

Lionel.
tonyurban
Posts: 6
Joined: Wed Nov 16, 2005 1:44 pm

Post by tonyurban »

Ok, I got rid of the "SNMP Error" on the top of my page by removing execute permission restrictions on the snmp binaries. I'm not sure why I was getting those errors (binaries run as apache user?).

I'm still getting the "No SNMP data returned" issue when trying to snmp queries on my interfaces within cacti.
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

Um, did you update snmpwalk's permissions?
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
tonyurban
Posts: 6
Joined: Wed Nov 16, 2005 1:44 pm

Post by tonyurban »

Yes, I did, for all of my snmp binaries. That's what cured the "SNMP Error" that was displaying at the top of the page. However, the other error is still present (verbose query is failing with error as above).
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

What are the ulimits for the apache user?

Do you have IM, I will be home in about 1 hours, we can attempt to work on this issue.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

Was an SNMP version issue.. :)
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests