[mrtg] Connected Users - Cisco Aironet 1200

Richard Gliebe richard.gliebe at fhv.at
Thu May 20 09:36:40 CEST 2010


On 5/18/10 11:57 AM Niall O'Reilly wrote:

Hi Niall,

> 	Yes, but the detail you mentioned seemed to include
> 	everything you need.
> 
> 	FWIW, the interface template fragment below "works for us".
> 	YMMV ...

sorry for my stupid question, but where do I have to include this 
template fragment?

Append it to the cfg File or somewhere in the html file for each AP?

> 
> # -*- Mode: perl -*-
> 
> if($if_ok and $if_type == 71 and $sysdescr =~ /^Cisco /mi) {
>      my ($custom_sysname) = split(/\./, $sysname);
>      my @frags = split(/\//, $if_snmp_name);
>      my ($conventional_if_suffix, $custom_if_suffix) =  map {
> 	join($_, @frags) } ( '_', '.' );
>      my $custom_target_name = 
> "$custom_sysname\-wlclients-$custom_if_suffix";
>      $target_lines = "
> # $custom_sysname cDot11ActiveWirelessClients
> Target[$custom_target_name]: 
> 1.3.6.1.4.1.9.9.273.1.1.2.1.1$if_ref&1.3.6.1.4.1.9.9.273.1.1.2.1.1$if_ref:$router_connect
> Directory[$custom_target_name]: $custom_sysname
> Title[$custom_target_name]: Active wireless clients on $custom_sysname 
> $html_if_snmp_name
> PageTop[$custom_target_name]: $custom_sysname $html_if_snmp_name</H1>
>     <TABLE>
>       <TR><TD>System:</TD><TD>$sysname</TD></TR>
>       <TR><TD>&nbsp;</TD><TD>Active Wireless Clients</TD></TR>
>      </TABLE>
> 
> ### END Interface
> ";
> 
> } else {
>      my $custom_sysdescr = join("\n###   ", (split(/\n/, $sysdescr)));
> 
>      $head_lines="";
>      $problem_lines="";
>      $target_lines="
> 
> ### DEBUG $if_snmp_name
> ###  skipped because selection criteria were not matched
> ###     if_ok:  '$if_ok'
> ###   if_type:  '$if_type'
> ###  sysDescr:
> ###   $custom_sysdescr
> ### END DEBUG
> 
> ";
>      $separator_lines="";
> }
> 


many thanks
Richard



More information about the mrtg mailing list