End Device Tracking Add-On for Cacti

Support questions about the MAC Track plugin

Moderators: Developers, Moderators

Post Reply
spoonman
Cacti User
Posts: 305
Joined: Tue May 03, 2005 8:54 am
Location: GA

Post by spoonman »

knobdy>>>
See attachted pics....I looked at my device list for one of my cisco 4000's and looked at the snmp info at the top in the sysdescription. Grabbed the relevant data and created a new device type in the mactrack section.

Hope this helps some??
Attachments
switch info to get snmp sysdescription...
switch info to get snmp sysdescription...
switch.PNG (6.86 KiB) Viewed 6784 times
adding a new device type worked..
adding a new device type worked..
newdevicetype.PNG (17.88 KiB) Viewed 6784 times
Here the device list
Here the device list
devices.PNG (11.47 KiB) Viewed 6784 times
knobdy
Cacti User
Posts: 495
Joined: Wed Sep 28, 2005 1:39 pm

Post by knobdy »

Yep, that's what I've got, with the exception of this being a 4006 (WS-C4006). It sees the device fine:

s1 is the 4006, s2 and s3 are hanging off of it (all are full).
Attachments
s1_mac.JPG
s1_mac.JPG (39.72 KiB) Viewed 6780 times
Ciscocow
Posts: 5
Joined: Wed Nov 30, 2005 11:20 am

Post by Ciscocow »

I am having an issue where the devices show up in the device list fine but i cannot do a search at all for any MAC ports. I do have an L3 device added to my site. But no matter what i do i cannot search for macs. Any help would be greatly appriacted.

Server Stats
cacti 0.8.6g > w/ mactrack plugin
mysql-server-4.1.15
php-4.4.1_2
sobacha
Posts: 7
Joined: Fri Jan 13, 2006 12:56 am

Post by sobacha »

knobdy wrote:
Have you figured this out? Soba, did a call get it fixed?

We're running 2 1100s, 2 1200s and an older/smaller AP - none of which return data.
knobdy,

In my force10 case, there are two factors. One is my misunderstanding and the other is a bug.
So, It might not help your aironet case.

Regards,
soba

[1. my misunderstanding]
I captured snmp-response packets for dot1qTpFdbPort. There WERE MAC address and port number.
Here is a sample captured data.

-----------------------------------
Simple Network Management Protocol
Version: 2C (1)
Community: public
PDU type: RESPONSE (2)
Request Id: 0x00007dae
Error Status: NO ERROR (0)
Error Index: 0
Object identifier 1: 1.3.6.1.2.1.17.7.1.2.2.1.2.20.0.0.226.45.23.151
(SNMPv2-SMI::mib-2.17.7.1.2.2.1.2.20.0.0.226.45.23.151)
Value: INTEGER: 1
-----------------------------------

So, I tried to snmpwalk with "-OX" option.

-----------------------------------
$ snmpwalk -v 2c -c public -OX 192.168.1.1 dot1qTpFdbPort
Q-BRIDGE-MIB::dot1qTpFdbPort[20][STRING: 0:0:e2:2d:17:97] = INTEGER: 1
Q-BRIDGE-MIB::dot1qTpFdbPort[20][STRING: 0:2:a5:e8:bf:56] = INTEGER: 209
:
(snip)
:
-----------------------------------

dot1qTpFdbPort
.20 -->VLANid
.0.0.226.45.23.151 -->MAC address (decimal)
=
INTEGER: 1 -->port number

[2. a bug]
There is an issue with dot1dBasePortIfIndex in my version that doesn't return the entire table correctly.(A little bit older firmware, I use.)
So, if I could get the VLAN, MAC address and port number informations from dot1qTpFdbPort, there is no way to translate the port number into IfIndex, now.

$ snmpwalk -v 2c -c public 192.168.1.1 dot1dBasePortIfIndex
BRIDGE-MIB::dot1dBasePortIfIndex.0 = INTEGER: 33865785

It prints this one line only. This is a bug.

#This Force10 hub has many ports:
#
#IF-MIB::ifIndex.33865785 = INTEGER: 33865785
#IF-MIB::ifIndex.34127929 = INTEGER: 34127929
#:
#:
#IF-MIB::ifDescr.33865785 = STRING: GigabitEthernet 0/0
#IF-MIB::ifDescr.34127929 = STRING: GigabitEthernet 0/1
#:
#:
williem
Cacti User
Posts: 69
Joined: Tue Feb 08, 2005 10:36 am

mactrack_ip_range

Post by williem »

Larry,

This one should be a quick fix (I hope). I get the following error when i run the poller:
02/17/2006 01:44:27 PM - CMDPHP: Poller[0] ERROR: SQL Exec Failed "REPLACE INTO `mac_track_ip_ranges` (ip_range, site_id, ips_current, ips_current_date) VALUES (96.10.4,1,6,2006-02-17 13:44:11)"

The issue is that you are passing in 4 fields, but there are 5 fields defined in the DB (ip_range, site_id,ips_max, ips_current, ips_max_date). The ips_max is defined as not NULL. here is the fix. Being that we know that the range-record == 0 to get to this piece of code. add the column to the replace into: This is in poller_mactrack.ph around line 424.

if (sizeof($range_record) == 0) {
db_execute("REPLACE INTO `mac_track_ip_ranges`
(ip_range, site_id, ips_max, ips_current, ips_current_date)
VALUES (" .
$ip_range["ip_range"] . "," .
$ip_range["site_id"] . "," .
$ip_range["ips_current"] . "," .
$ip_range["ips_current"] . "," .
$ip_range["ips_current_date"] . ")");
}else{
db_execute("UPDATE `mac_track_ip_ranges`
SET ips_current='" . $ip_range["ips_current"] . "', " .
"ips_current_date='" . $ip_range["ips_current_date"] . "'" .
"WHERE ip_range='" . $range_record["ip_range"] . "' AND " .
"site_id='" . $range_record["site_id"] . "'");
}

We will set the ips_max and the ips-current to the same record as this is the first time it has been added.


Regards,

Willie
Cacti 0.8.6h | Cactid 0.8.6g | 64k devices | W2k3 IIS | PHP 5.3 | RRDtool 1.0.49 | Perl 5.8.5 | Dell Servers 8 gig ram
williem
Cacti User
Posts: 69
Joined: Tue Feb 08, 2005 10:36 am

poller_mactrack

Post by williem »

Larry,

I posted the above fix a little too soon. the poller-mactrack references ips_current_date but the create table in the database_update names it ips_max-date. There is not ips-current_date. Here is the corrected function that fills in the data.

Regards,

Willie
ps this is starting at line 419


if (is_array($ip_ranges)) {
foreach($ip_ranges as $ip_range) {
$range_record = db_fetch_row("SELECT * FROM mac_track_ip_ranges WHERE ip_range='" . $ip_range["ip_range"] .
"' AND site_id='" . $ip_range["site_id"] . "'");

if (sizeof($range_record) == 0) {
db_execute("REPLACE INTO `mac_track_ip_ranges`
(ip_range, site_id, ips_max, ips_current, ips_max_date)
VALUES ('" .
$ip_range["ip_range"] . "','" .
$ip_range["site_id"] . "','" .
$ip_range["ips_current"] . "','" .
$ip_range["ips_current"] . "','" .
$ip_range["ips_current_date"] . "')");
}else{
db_execute("UPDATE `mac_track_ip_ranges`
SET ips_current='" . $ip_range["ips_current"] . "', " .
"ips_max_date='" . $ip_range["ips_current_date"] . "'" .
"WHERE ip_range='" . $range_record["ip_range"] . "' AND " .
"site_id='" . $range_record["site_id"] . "'");
}
}
}

/* update the max values if required */
db_execute("UPDATE `mac_track_ip_ranges`
SET ips_max=ips_current
WHERE ips_current > ips_max");
Cacti 0.8.6h | Cactid 0.8.6g | 64k devices | W2k3 IIS | PHP 5.3 | RRDtool 1.0.49 | Perl 5.8.5 | Dell Servers 8 gig ram
charles.regan
Posts: 3
Joined: Tue Nov 22, 2005 8:30 pm

canopy

Post by charles.regan »

I would like to have support for the Motorola Canopy Subscriber Modules.

Here are the MIB :
http://motorola.canopywireless.com/supp ... tools/mib/

Every Subscriber modules have a Bridge table.
Most of the time there is 3 MAC address on the table.
1st is for Wireless Interface
2nd is for Local Interface
3rd is the PC connected to the Subscriber Module.

Let me know if I can help with this.
thanks
Dr.Dritz
Posts: 44
Joined: Wed Apr 02, 2003 2:48 pm
Location: Southern Denmark

Enterasys (Cabletron) and VLANs

Post by Dr.Dritz »

Dear TheWitness,
I am having trouble with my Enterasys VH stacked switches. I don't know wether it is because of the minimum 4 VLANs running on them (there are no active ports on VLAN1). Did you have any VLANs on your Cabletrons?

Here's my output:
----------------------------------
C:\Inetpub\wwwroot\Cacti\plugins\mactrack>php -q mactrack_scanner.php -d -id=3 |
more
C:/usr/etc/snmp/snmp.conf: line 2: Warning: Unknown token: persistentDir.
C:/usr/etc/snmp/snmp.conf: line 3: Warning: Unknown token: tempFilePattern.
DEBUG: HOST: 192.168.153.45 is alive, processing has begun.
DEBUG: Scanning function is 'get_cabletron_switch_ports'
DEBUG: ifIndexes data collection complete
DEBUG: ifTypes data collection complete.
DEBUG: ifNames data collection complete.
DEBUG: ifInterfaces assembly complete.
DEBUG: Cabletron securefast marker obtained
INFO: HOST: 192.168.153.45, TYPE: Vertical Horizon Stack, TOTAL PORTS: 0, OPER PORTS: 0
DEBUG: No user ports on this network.
DEBUG: SQL: UPDATE mac_track_devices SET ports_total='0',device_type_id='44',sca
n_type = '1',vlans_total='0',ports_active='0',ports_trunk='0',macs_active='0',sn
mp_readstring='public',snmp_sysName='Stack SB B5',snmp_sysLocation='xxx SB B5',snmp_sysContact='Onslow',snmp_sysObjectID='.1.3.6.1.4.1.5624.2.1.11',snmp_s
ysDescr='Vertical Horizon Stack',snmp_sysUptime='187091688',snmp_status='3',last
_runmessage='Data collection completed ok',last_rundate='2006-02-20 15:37:04',la
st_runduration='11.8268' WHERE device_id ='3'
--------------------------------------

Greetings
- Dritz
williem
Cacti User
Posts: 69
Joined: Tue Feb 08, 2005 10:36 am

Cabletron

Post by williem »

Hey,

Do you have multible spanning tree groups or is everything in spanning tree group 1?

Regards,

Willie
Cacti 0.8.6h | Cactid 0.8.6g | 64k devices | W2k3 IIS | PHP 5.3 | RRDtool 1.0.49 | Perl 5.8.5 | Dell Servers 8 gig ram
Dr.Dritz
Posts: 44
Joined: Wed Apr 02, 2003 2:48 pm
Location: Southern Denmark

Cabletron

Post by Dr.Dritz »

Hello williem,
thanks for your concern.
- no, Spanning Tree Protocol is disabled, nothing fancy here.

- Dritz

[/img]
Attachments
Nothing fancy
Nothing fancy
VH_STA.jpg (69.04 KiB) Viewed 6544 times
Dr.Dritz
Posts: 44
Joined: Wed Apr 02, 2003 2:48 pm
Location: Southern Denmark

Cabletron

Post by Dr.Dritz »

I am trying to figure out what's going on and what should go on.

From mactrack_cabletron.php:
-------------------------------------------
$securefast_marker = @cacti_snmp_get($device["hostname"], $device["snmp_readstring"],
".1.3.6.1.4.1.52.4.2.4.2.1.1.1.1.1.1.1", $device["snmp_version"],
-------------------------------------------

Larry is asking if sfp is active, and I tried to walk the same OID as above:

-------------------------------------------------
23-02-2006 11:43:38
Request: 1, Type: GetNext
0: 1.3.6.1.4.1.52.4.2.4.2.1.1.1

23-02-2006 11:43:38
Response: 1
Error Status: 2, Error Index: 1
0: 1.3.6.1.4.1.52.4.2.4.2.1.1.1, 5, Null
---------------------------------------------------

Hmmmm..... the output from mactrack_scanner.php claims:
.....
"DEBUG: Cabletron securefast marker obtained"
... is this the problem?
As I see the result of my SNMP walk, I do not have the sfp active (I'm missing the last 4 leaves .1.1.1.1 ) - allthough the poller claims it.

- Dritz
Attachments
A walk on my VH2402s
A walk on my VH2402s
SFP_SNMPwalk.jpg (93.31 KiB) Viewed 6442 times
User avatar
egarnel
Cacti Pro User
Posts: 708
Joined: Thu Nov 21, 2002 8:55 am
Location: Austin, TX

Post by egarnel »

Finally got this working. Had to create a device type for 3560 switches & 6500 720b sup blades.

This is more of a feature request: Can we get the device ID displayed under the console|macktrack fields?

Thanks,

Eric
Cacti1 OS: CentOS 5.6 | 300+ devices
Cacti2 OS: CentOS 5.6 | 300+ devices
King of the Elves
Local Anarchists Union #427
"Anarchism is founded on the observation that since few men are wise enough to rule themselves, even fewer are wise enough to rule others." -Edward Abbey
knobdy
Cacti User
Posts: 495
Joined: Wed Sep 28, 2005 1:39 pm

Post by knobdy »

egarnel wrote:Finally got this working. Had to create a device type for 3560 switches & 6500 720b sup blades.Eric
Where did you see that you needed to add a device type for the blades? How'd you go about it?

I have at least one switch where I get information from one blade but not the others - maybe I have a similar problem...
User avatar
egarnel
Cacti Pro User
Posts: 708
Joined: Thu Nov 21, 2002 8:55 am
Location: Austin, TX

Post by egarnel »

I spoke to soon. I am using the plugin version and it is only half working.
I was able to pull info form the 6506 720b via the command line, but nothing shows in Cacti.

Jimmy is still working on the plugin version from what I understand, so I will most likely disable it in the meantime.

this is the device id I used to create the device type s72033_rp-PSV-M
for the 720 sup
Cacti1 OS: CentOS 5.6 | 300+ devices
Cacti2 OS: CentOS 5.6 | 300+ devices
King of the Elves
Local Anarchists Union #427
"Anarchism is founded on the observation that since few men are wise enough to rule themselves, even fewer are wise enough to rule others." -Edward Abbey
williem
Cacti User
Posts: 69
Joined: Tue Feb 08, 2005 10:36 am

6500

Post by williem »

Here are some of the ones I am using. To catch a new revision of a switch card, just call if up in cacti and it will always list the deice type (ie c6sup2_rp_PSV-M in the description). that same screen will also give you the base OID to put in.

Regards,

Willie
6509 sup2 c6sup2_rp-PSV-M .1.3.6.1.4.1.9
6513 sup2 c6sup2_rp-DSV-M .1.3.6.1.4.1.9
BPS2000 Business Policy Swit .1.3.6.1.4.1.45
Nortel 8600 Passport-8610 .1.3.6.1.4.1.2272
Cacti 0.8.6h | Cactid 0.8.6g | 64k devices | W2k3 IIS | PHP 5.3 | RRDtool 1.0.49 | Perl 5.8.5 | Dell Servers 8 gig ram
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests