Hi.
I can't get Mactrack to work, when i run mactrack_scanner.php -d i get:
ns:/usr/share/cacti/plugins/mactrack# php /usr/share/cacti/plugins/mactrack/mactrack_scanner.php -d
Notice: Undefined variable: device_id in /usr/share/cacti/plugins/mactrack/mactrack_scanner.php on line 108
Notice: Undefined variable: device_id in /usr/share/cacti/plugins/mactrack/mactrack_scanner.php on line 112
Notice: Undefined variable: device_id in /usr/share/cacti/plugins/mactrack/mactrack_scanner.php on line 114
Notice: Undefined variable: device_id in /usr/share/cacti/plugins/mactrack/mactrack_scanner.php on line 115
DEBUG: ERROR: Device with Id of '' not found in database. Can not continue.
So having problem with device_ID, i check my database;
mysql> select device_id,device_name,device_type_id, hostname from mac_track_devices limit 1;
+-----------+-------------------------------------------+----------------+------------+
| device_id | device_name | device_type_id | hostname |
+-----------+-------------------------------------------+----------------+------------+
| 1 | 3Com SuperStack 4 Switch 5500-EI 52-Port | 2 | 10.0.5.217 |
+-----------+-------------------------------------------+----------------+------------+
mysql> select device_type_id, description, device_type from mac_track_device_types limit 1;
+----------------+-----------------------------------------------------------------------------------------------------+-------------+
| device_type_id | description | device_type |
+----------------+-----------------------------------------------------------------------------------------------------+-------------+
| 1 | Cisco IOS Software, C3560 Software (C3560-IPBASEK9-M), Version 12.2(25)SEE3, RELEASE SOFTWARE (fc2) | 1 |
+----------------+-----------------------------------------------------------------------------------------------------+-------------+
it look ok here? Should work (the two above is not not have the right device-types, i know, have checked all my 11 devices, all have the right device-type thou). I have just installed the latest cacti, 0.8.7.a, 1.4 plugin-arc and Mactrack 1.1. When i run database_upgrade.php i get:
ns:/usr/share/cacti/plugins/mactrack# php database_upgrade.php
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> snmp_timeout, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> snmp_retries, Ok
SUCCESS: Add Column, Table -> mac_track_ports, Column -> dns_hostname, Already Exists!
SUCCESS: Add Column, Table -> mac_track_temp_ports, Column -> dns_hostname, Already Exists!
SUCCESS: Add Column, Table -> mac_track_ips, Column -> dns_hostname, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> snmp_port, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> macs_active, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> snmp_sysName, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> snmp_sysLocation, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> snmp_sysContact, Already Exists!
SUCCESS: Create Table, Table -> mac_track_scanning_functions, Already Exists!
SUCCESS: Execute SQL, Change Primary Key For 'mac_track_devices', Ok
SUCCESS: Add Index, Table -> mac_track_devices, Index -> device_id, Already Exists!
SUCCESS: Add Column, Table -> mac_track_sites, Column -> total_oper_ports, Already Exists!
SUCCESS: Execute SQL, Change Primary Key For 'mac_track_device_types', Ok
SUCCESS: Add Index, Table -> mac_track_device_types, Index -> device_type_id, Already Exists!
SUCCESS: Modify Column, Table -> mac_track_scanning_functions, Column -> scanning_function, Ok
SUCCESS: Modify Column, Table -> mac_track_scanning_functions, Column -> description, Ok
SUCCESS: Create Table, Table -> mac_track_scan_dates, Already Exists!
SUCCESS: Execute SQL, Addition of Scan Dates, Ok
SUCCESS: Add Index, Table -> mac_track_devices, Index -> snmp_sysDescr, Already Exists!
SUCCESS: Add Index, Table -> mac_track_devices, Index -> snmp_sysObjectID, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> device_type_id, Already Exists!
SUCCESS: Add Index, Table -> mac_track_devices, Index -> device_type_id, Already Exists!
SUCCESS: Add Index, Table -> mac_track_ports, Index -> port_name, Already Exists!
SUCCESS: Add Index, Table -> mac_track_ports, Index -> dns_hostname, Already Exists!
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> ips_total, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> vlans_total, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> ports_total, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> ports_active, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> ports_trunk, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> macs_active, Ok
SUCCESS: Add Column, Table -> mac_track_temp_ports, Column -> updated, Already Exists!
SUCCESS: Add Index, Table -> mac_track_temp_ports, Index -> updated, Already Exists!
SUCCESS: Add Index, Table -> mac_track_temp_ports, Index -> ip_address, Already Exists!
SUCCESS: Create Table, Table -> mac_track_ip_ranges, Already Exists!
SUCCESS: Add Column, Table -> mac_track_ip_ranges, Column -> ips_max_date, Already Exists!
SUCCESS: Add Column, Table -> mac_track_ip_ranges, Column -> ips_current_date, Already Exists!
SUCCESS: Add Column, Table -> mac_track_processes, Column -> device_id, Already Exists!
SUCCESS: Add Column, Table -> mac_track_processes, Column -> process_id, Already Exists!
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> snmp_readstring, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> snmp_readstrings, Ok
SUCCESS: Execute SQL, Change mac_track_temp_ports to Memory Table, Ok
SUCCESS: Execute SQL, Change mac_track_ips to Memory Table, Ok
SUCCESS: Create Table, Table -> mac_track_approved_macs, Already Exists!
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> ignorePorts, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> snmp_readstring, Ok
SUCCESS: Modify Column, Table -> mac_track_devices, Column -> snmp_readstrings, Ok
SUCCESS: Create Table, Table -> mac_track_oui_database, Already Exists!
SUCCESS: Add Column, Table -> mac_track_ports, Column -> vendor_mac, Already Exists!
SUCCESS: Add Index, Table -> mac_track_ports, Index -> vendor_mac, Already Exists!
SUCCESS: Add Column, Table -> mac_track_temp_ports, Column -> vendor_mac, Already Exists!
SUCCESS: Add Index, Table -> mac_track_temp_ports, Index -> vendor_mac, Already Exists!
SUCCESS: Execute SQL, Add Vendor Macs To 'mac_track_ports', Ok
SUCCESS: Execute SQL, Add Vendor Macs To 'mac_track_temp_ports', Ok
SUCCESS: Add Column, Table -> mac_track_temp_ports, Column -> authorized, Already Exists!
SUCCESS: Add Index, Table -> mac_track_temp_ports, Index -> authorized, Already Exists!
SUCCESS: Add Column, Table -> mac_track_ports, Column -> authorized, Already Exists!
SUCCESS: Add Index, Table -> mac_track_ports, Index -> authorized, Already Exists!
SUCCESS: Create Table, Table -> mac_track_macwatch, Already Exists!
SUCCESS: Create Table, Table -> mac_track_macauth, Already Exists!
SUCCESS: Create Table, Table -> mac_track_vlans, Already Exists!
SUCCESS: Execute SQL, Add VLANS to VLAN Table, Ok
ERROR: Modify Column, Table -> mac_track_devices, Column -> description, Column Does NOT Exist!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> device_name, Already Exists!
SUCCESS: Add Index, Table -> mac_track_devices, Index -> device_name, Already Exists!
SUCCESS: Add Column, Table -> mac_track_sites, Column -> customer_contact, Already Exists!
SUCCESS: Add Column, Table -> mac_track_sites, Column -> netops_contact, Already Exists!
SUCCESS: Add Column, Table -> mac_track_sites, Column -> facilities_contact, Already Exists!
SUCCESS: Add Column, Table -> mac_track_sites, Column -> site_info, Already Exists!
SUCCESS: Add Column, Table -> mac_track_device_types, Column -> serial_number_oid, Already Exists!
ERROR: Execute SQL, Move Device Names from the 'description' field to the 'device_name' field., Failed!
ERROR: Execute SQL, Blank out the 'description' field as it will now be used for something else, Failed!
SUCCESS: Add Column, Table -> mac_track_macwatch, Column -> email_addresses, Already Exists!
SUCCESS: Add Column, Table -> mac_track_macwatch, Column -> mac_id, Already Exists!
SUCCESS: Add Column, Table -> mac_track_macwatch, Column -> date_last_seen, Already Exists!
SUCCESS: Add Column, Table -> mac_track_macauth, Column -> mac_id, Already Exists!
SUCCESS: Add Column, Table -> mac_track_ports, Column -> device_name, Already Exists!
SUCCESS: Add Column, Table -> mac_track_temp_ports, Column -> device_name, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> notes, Already Exists!
ERROR: Modify Column, Table -> mac_track_ips, Column -> description, Column Does NOT Exist!
SUCCESS: Delete Column, Table -> mac_track_devices, Column -> serial_number, Column Does NOT Exist!
SUCCESS: Delete Column, Table -> mac_track_devices, Column -> asset_id, Column Does NOT Exist!
SUCCESS: Create Table, Table -> mac_track_interfaces, Already Exists!
SUCCESS: Add Column, Table -> mac_track_scanning_functions, Column -> type, Already Exists!
SUCCESS: Add Column, Table -> mac_track_device_types, Column -> ip_scanning_function, Already Exists!
SUCCESS: Execute SQL, Update the Scanning Function Type to 'Mac' for undefined types, Ok
SUCCESS: Execute SQL, Set the IP Scanning function to N/A for Device Type 1, Ok
SUCCESS: Execute SQL, Set the IP Scanning function to 'get_standard_arp_table' for Routers and L3 Switches, Ok
SUCCESS: Add Column, Table -> mac_track_interfaces, Column -> vlan_trunk, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> user_name, Already Exists!
SUCCESS: Add Column, Table -> mac_track_devices, Column -> user_password, Already Exists!
Updating Device Types in Devices Table. Please be patient.
.
Device Types Updated, You have '0' Good Device Type Mapping and '14' Bad Device Type Mapping.
If the Bad Device type mapping is greater than '0', you should inspect your devices for unmapped device types.
I can't figure out why it wont link!
thx
g
Mactrack won't scan, device_id-problem.
Moderators: Developers, Moderators
Who is online
Users browsing this forum: No registered users and 0 guests