[mrtg] cfgmaker generates wrong config for OpenBSD

gnpf posturne at gmail.com
Wed Sep 22 14:03:46 CEST 2010


Hi,
I try to query my OpbenBSD firewalls with cfgmaker.
The generated config shows me wrong interface names/coun/addresses:

# ./cfgmaker --ifref=ip --global WorkDir:/var/www/mrtg/ public at fw1

WorkDir:/var/www/mrtg/

### Interface 1 >> Descr: 'lo0' | Name: '' | Ip: '10.100.102.98' | Eth: ''
###
### The following interface is commented out because:
### * it is a Software Loopback interface
### * has a speed of 0 which makes no sense
#
# Target[fw1_10.100.102.98]: /10.100.102.98:public at fw1:
# SetEnv[fw1_10.100.102.98]: MRTG_INT_IP="10.100.102.98"
MRTG_INT_DESCR="lo0"
# MaxBytes[fw1_10.100.102.98]: 0
# Title[fw1_10.100.102.98]: Traffic Analysis for 10.100.102.98 --
fw1.aaa.local
# PageTop[fw1_10.100.102.98]: <H1>Traffic Analysis for 10.100.102.98 --
fw1.aaa.local</H1>
#  <TABLE>
#    <TR><TD>System:</TD>     <TD>fw1.aaa.local in Right here, right
now.</TD></TR>
#    <TR><TD>Maintainer:</TD> <TD>aaa at aaa.de</TD></TR>
#    <TR><TD>Description:</TD><TD>lo0  </TD></TR>
#    <TR><TD>ifType:</TD>     <TD>softwareLoopback (24)</TD></TR>
#    <TR><TD>ifName:</TD>     <TD></TD></TR>
#    <TR><TD>Max Speed:</TD>  <TD>0.0 Bytes/s</TD></TR>
#    <TR><TD>Ip:</TD>         <TD>10.100.102.98 (fw1.aaa.local)</TD></TR>
#  </TABLE>


### Interface 2 >> Descr: 'em0' | Name: '' | Ip: '192.168.199.1' | Eth:
'00-15-17-d3-04-1d' ###

Target[fw1_192.168.199.1]: /192.168.199.1:public at fw1:
SetEnv[fw1_192.168.199.1]: MRTG_INT_IP="192.168.199.1" MRTG_INT_DESCR="em0"
MaxBytes[fw1_192.168.199.1]: 12500000
Title[fw1_192.168.199.1]: Traffic Analysis for 192.168.199.1 --
fw1.aaa.local
PageTop[fw1_192.168.199.1]: <H1>Traffic Analysis for 192.168.199.1 --
fw1.aaa.local</H1>
 <TABLE>
   <TR><TD>System:</TD>     <TD>fw1.aaa.local in Right here, right
now.</TD></TR>
   <TR><TD>Maintainer:</TD> <TD>aaa at aaa.de</TD></TR>
   <TR><TD>Description:</TD><TD>em0  </TD></TR>
   <TR><TD>ifType:</TD>     <TD>ethernetCsmacd (6)</TD></TR>
   <TR><TD>ifName:</TD>     <TD></TD></TR>
   <TR><TD>Max Speed:</TD>  <TD>12.5 MBytes/s</TD></TR>
   <TR><TD>Ip:</TD>         <TD>192.168.199.1 ()</TD></TR>
 </TABLE>


### Interface 3 >> Descr: 'em1' | Name: '' | Ip: '10.68.102.247' | Eth:
'00-15-17-d3-04-1c' ###

Target[fw1_10.68.102.247]: /10.68.102.247:public at fw1:
SetEnv[fw1_10.68.102.247]: MRTG_INT_IP="10.68.102.247" MRTG_INT_DESCR="em1"
MaxBytes[fw1_10.68.102.247]: 125000000
Title[fw1_10.68.102.247]: Traffic Analysis for 10.68.102.247 --
fw1.aaa.local
PageTop[fw1_10.68.102.247]: <H1>Traffic Analysis for 10.68.102.247 --
fw1.aaa.local</H1>
 <TABLE>
   <TR><TD>System:</TD>     <TD>fw1.aaa.local in Right here, right
now.</TD></TR>
   <TR><TD>Maintainer:</TD> <TD>aaa at aaa.de</TD></TR>
   <TR><TD>Description:</TD><TD>em1  </TD></TR>
   <TR><TD>ifType:</TD>     <TD>ethernetCsmacd (6)</TD></TR>
   <TR><TD>ifName:</TD>     <TD></TD></TR>
   <TR><TD>Max Speed:</TD>  <TD>125.0 MBytes/s</TD></TR>
   <TR><TD>Ip:</TD>         <TD>10.68.102.247 ()</TD></TR>
 </TABLE>


This is not the complete config, only the first 3 interfaces. ifconfig on
fw1 looks like:

lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 33160
        priority: 0
        groups: lo
        inet 127.0.0.1 netmask 0xff000000
        inet6 ::1 prefixlen 128
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x10
em0: flags=8b43<UP,BROADCAST,RUNNING,PROMISC,ALLMULTI,SIMPLEX,MULTICAST> mtu
1500
        lladdr 00:15:17:d3:04:1d
        priority: 0
        media: Ethernet autoselect (100baseTX full-duplex)
        status: active
        inet 10.100.102.98 netmask 0xffff0000 broadcast 10.100.255.255
        inet6 fe80::215:17ff:fed3:41d%em0 prefixlen 64 scopeid 0x1
em1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        lladdr 00:15:17:d3:04:1c
        priority: 0
        media: Ethernet autoselect (1000baseT full-duplex)
        status: active
        inet 192.168.199.1 netmask 0xffffff00 broadcast 192.168.199.255
        inet6 fe80::215:17ff:fed3:41c%em1 prefixlen 64 scopeid 0x2

whats wrong here, where is my mistake? I try it with and without --ifref=ip,
everytime the same result.
I belive its a problem with openbsd, because I get the config from cisco and
linux devices without trouble.

thanks in advance,
tom

-- 
View this message in context: http://mrtg-mailinglists.795376.n2.nabble.com/cfgmaker-generates-wrong-config-for-OpenBSD-tp5558762p5558762.html
Sent from the MRTG Users Mailinglist mailing list archive at Nabble.com.



More information about the mrtg mailing list