New Field at IP addresses view

Support questions about the MAC Track plugin

Moderators: Moderators, Developers

Post Reply
Author
Message
wpoveda
Posts: 2
Joined: Tue Aug 22, 2017 6:45 am

New Field at IP addresses view

#1 Post by wpoveda » Tue Aug 22, 2017 6:54 am

Hi,

Could be possible the addition of the field "Name" at this view as is showed at the "Interfaces" one?

Thanks

wpoveda
Posts: 2
Joined: Tue Aug 22, 2017 6:45 am

Re: New Field at IP addresses view

#2 Post by wpoveda » Wed Aug 23, 2017 2:02 am

Hi people,

This is my workaround

551 -- > $query_string = "SELECT mac_track_ips.*, mac_track_sites.site_name, mac_track_oui_database.*, mac_track_interfaces.ifName
FROM mac_track_ips
LEFT JOIN mac_track_sites
ON (mac_track_ips.site_id = mac_track_sites.site_id)
LEFT JOIN mac_track_oui_database
ON (mac_track_oui_database.vendor_mac=SUBSTRING(mac_track_ips.mac_address, 1, 8))
LEFT JOIN mac_track_interfaces ON (mac_track_interfaces.device_id=mac_track_ips.device_id AND mac_track_interfaces.ifIndex=mac_track_ips.port_number)
$sql_where
$sql_order
$sql_limit";



mac_track_view_ips{ ...
echo '<td>' . $port_result['port_number'] .'::'. $port_result['ifName'] . '</td>';
...}

User avatar
Osiris
Cacti Pro User
Posts: 863
Joined: Mon Jan 05, 2015 10:10 am

Re: New Field at IP addresses view

#3 Post by Osiris » Wed Aug 23, 2017 8:08 pm

Github pulling request is a better place for this.
Before history, there was a paradise, now dust.

User avatar
Pucho
Cacti User
Posts: 180
Joined: Wed Jul 20, 2016 8:00 pm

Re: New Field at IP addresses view

#4 Post by Pucho » Sun Feb 18, 2018 3:39 pm

This has been done and it's already on github version (develop branch).
Cacti - 1.1.37
Poller Type - Spine
Weathermap 0.98a
Server Info - Linux 3.10.0 - Centos 7
Web Server - Apache/2.4.6 PHP 5.4.16
MySQL - 5.5 ;RRDTool - 1.4.8 ;SNMP - 5.7.2
Religion - Anti forum pets

Code: Select all

SYSTEM STATS: Time:17.7383 Method:spine Processes:1 Threads:10 Hosts:279 HostsPerProcess:279 DataSources:7309 RRDsProcessed:3718

Code: Select all

WEATHERMAP STATS: Weathermap 0.98 run complete - Thu, 16 Nov 17 08:42:56 +1300: 39 maps were run in 23.22 seconds with 0 warnings.

Post Reply