Bug 818110 - mrtg doesn't work with --ifref=name configuration
mrtg doesn't work with --ifref=name configuration
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: mrtg (Show other bugs)
16
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Vitezslav Crhonek
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-05-02 04:55 EDT by David Woodhouse
Modified: 2013-02-13 21:29 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-02-13 21:28:59 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
mrtg.cfg (8.82 KB, text/plain)
2012-05-02 04:58 EDT, David Woodhouse
no flags Details

  None (edit)
Description David Woodhouse 2012-05-02 04:55:20 EDT
I'm trying to monitor the ADSL lines that provide my connectivity to the outside world. These are PPP connections, so they get a new ifIndex every time a line drops and reconnects. So obviously I need to use ifName to match them.

However, mrtg really doesn't seem to be very good at this. When the ifIndex changes, it usually just loses track of the device and can no longer find it.

Right now, for example...

[root@obelisk ~]# LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg --lock-file /var/lock/mrtg/mrtg_l --confcache-file /var/lib/mrtg/mrtg.ok 
2012-05-02 09:48:55: WARNING: Can not determine ifNumber for public@81.2.98.173: 	ref: 'Name' 	key: 'pppoa-ppp1'
2012-05-02 09:48:55: WARNING: Can not determine ifNumber for public@81.2.98.173: 	ref: 'Name' 	key: 'pppoa-ppp0'
2012-05-02 09:48:55: ERROR: Target[81.2.98.173_pppoa-ppp1][_IN_] ' $target->[3]{$mode} ' did not eval into defined data
2012-05-02 09:48:55: ERROR: Target[81.2.98.173_pppoa-ppp1][_OUT_] ' $target->[3]{$mode} ' did not eval into defined data
Use of uninitialized value $inlast in pattern match (m//) at /usr/bin/mrtg line 1045.
Use of uninitialized value $outlast in pattern match (m//) at /usr/bin/mrtg line 1048.
2012-05-02 09:48:55: ERROR: Target[81.2.98.173_pppoa-ppp0][_IN_] ' $target->[4]{$mode} ' did not eval into defined data
2012-05-02 09:48:55: ERROR: Target[81.2.98.173_pppoa-ppp0][_OUT_] ' $target->[4]{$mode} ' did not eval into defined data
Use of uninitialized value $inlast in pattern match (m//) at /usr/bin/mrtg line 1045.
Use of uninitialized value $outlast in pattern match (m//) at /usr/bin/mrtg line 1048.
[root@obelisk ~]# snmpwalk -v2c -c public 81.2.98.173  | grep pppoa-ppp
IF-MIB::ifDescr.11 = STRING: pppoa-ppp1
IF-MIB::ifDescr.12 = STRING: pppoa-ppp0
HOST-RESOURCES-MIB::hrDeviceDescr.1035 = STRING: network interface pppoa-ppp1
HOST-RESOURCES-MIB::hrDeviceDescr.1036 = STRING: network interface pppoa-ppp0
IF-MIB::ifName.11 = STRING: pppoa-ppp1
IF-MIB::ifName.12 = STRING: pppoa-ppp0
[root@obelisk ~]# grep pppoa-ppp /var/lib/mrtg/mrtg.ok 
public@81.2.98.173_	Descr	pppoa-ppp0	37
public@81.2.98.173_	Descr	pppoa-ppp1	16
public@81.2.98.173_	Name	pppoa-ppp0	
public@81.2.98.173_	Name	pppoa-ppp1	
public@81.2.98.173__2	Descr	pppoa-ppp0	8
public@81.2.98.173__2	Descr	pppoa-ppp1	9
public@81.2.98.173__2	Name	pppoa-ppp0	8
public@81.2.98.173__2	Name	pppoa-ppp1	9
[root@obelisk ~]# rm /var/lib/mrtg/mrtg.ok 
rm: remove regular file `/var/lib/mrtg/mrtg.ok'? y
[root@obelisk ~]# LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg --lock-file /var/lock/mrtg/mrtg_l --confcache-file /var/lib/mrtg/mrtg.ok 
2012-05-02 09:50:19: WARNING: Could not match host:'public@81.2.98.173:' ref:'Name' key:'pppoa-ppp1'
2012-05-02 09:50:19: WARNING: Could not match host:'public@81.2.98.173:' ref:'Name' key:'pppoa-ppp0'
2012-05-02 09:50:19: ERROR: Target[81.2.98.173_pppoa-ppp1][_IN_] ' $target->[3]{$mode} ' did not eval into defined data
2012-05-02 09:50:19: ERROR: Target[81.2.98.173_pppoa-ppp1][_OUT_] ' $target->[3]{$mode} ' did not eval into defined data
Use of uninitialized value $inlast in pattern match (m//) at /usr/bin/mrtg line 1045.
Use of uninitialized value $outlast in pattern match (m//) at /usr/bin/mrtg line 1048.
2012-05-02 09:50:19: ERROR: Target[81.2.98.173_pppoa-ppp0][_IN_] ' $target->[4]{$mode} ' did not eval into defined data
2012-05-02 09:50:19: ERROR: Target[81.2.98.173_pppoa-ppp0][_OUT_] ' $target->[4]{$mode} ' did not eval into defined data
Use of uninitialized value $inlast in pattern match (m//) at /usr/bin/mrtg line 1045.
Use of uninitialized value $outlast in pattern match (m//) at /usr/bin/mrtg line 1048.
[root@obelisk ~]# LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg --lock-file /var/lock/mrtg/mrtg_l --confcache-file /var/lib/mrtg/mrtg.ok 
[root@obelisk ~]# grep pppoa /var/lib/mrtg/mrtg.ok 
public@81.2.98.173_	Descr	pppoa-ppp0	12
public@81.2.98.173_	Descr	pppoa-ppp1	11
public@81.2.98.173_	Name	pppoa-ppp0	12
public@81.2.98.173_	Name	pppoa-ppp1	11
public@81.2.98.173__2	Descr	pppoa-ppp0	12
public@81.2.98.173__2	Descr	pppoa-ppp1	11
public@81.2.98.173__2	Name	pppoa-ppp0	12
public@81.2.98.173__2	Name	pppoa-ppp1	11


*Sometimes* it seems to work OK and find the new interface, but not always.
Comment 1 David Woodhouse 2012-05-02 04:58:27 EDT
Created attachment 581546 [details]
mrtg.cfg

It's using SNMPv1 for the PPP interfaces. There were other strange issues when I used SNMPv2, which I don't recall right now.
Comment 2 Fedora End Of Life 2013-01-16 19:42:56 EST
This message is a reminder that Fedora 16 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 16. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '16'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 16's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 16 is end of life. If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora, you are encouraged to click on 
"Clone This Bug" and open it against that version of Fedora.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 3 Fedora End Of Life 2013-02-13 21:29:03 EST
Fedora 16 changed to end-of-life (EOL) status on 2013-02-12. Fedora 16 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.