Logcheck-database outdated for dnsmasq-dhcp

Bug #508142 reported by Ronald Koster
28
This bug affects 5 people
Affects Status Importance Assigned to Milestone
logcheck (Ubuntu)
Fix Released
High
Loïc Minier
Lucid
Fix Released
High
Loïc Minier

Bug Description

IMPACT: up-to one logcheck email generated every hour, makes logcheck a spam source unless config is fixed locally

PROPOSED FIX: fix regular expression to allow for "dnsmasq-dhcp" and not only "dnsmasq" in logs

TESTCASE: install logcheck and libvirt, create a VM using libvirt's virbr0 bridge, start the vm, notice that it causes logcheck emails to be generated on every DHCP lease renewal

REGRESSION POTENTIAL: low overall; conffile prompt while upgrading if any conffiles need to be merged; regular expression might also still be incomplete/incorrect after update, but that wouldn't really be a regression

Revision history for this message
Loïc Minier (lool) wrote :

Note that libvirt uses dnsmasq to provide DHCP to virtual machines, this is a quite common Ubuntu server use case IMO.

Changed in logcheck (Ubuntu):
importance: Undecided → High
status: New → Confirmed
Revision history for this message
Loïc Minier (lool) wrote :

This is fixed in Debian logcheck 1.3.8.

Changed in logcheck (Ubuntu):
status: Confirmed → Fix Committed
assignee: nobody → Loïc Minier (lool)
Changed in logcheck (Ubuntu Lucid):
assignee: nobody → Loïc Minier (lool)
status: New → Confirmed
importance: Undecided → High
Revision history for this message
Loïc Minier (lool) wrote :

Fixed in upstream commit b7077fb0b19fcf7a9130cb3563a3d0af59edc3ea slightly differently as proposed here:
diff --git a/debian/changelog b/debian/changelog
index b935043..5cb2323 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -23,6 +23,9 @@ logcheck (1.3.8) UNRELEASED; urgency=low
   * src/logcheck:
     - look for {header,footer}.txt in $RULEDIR, thanks to Kerstin Puschke
     - cd to $STATEDIR before cleaning up temp dir, thanks to Kerstin Puschke
+ * ignore.d.server/dnsmasq:
+ - adjusted rule to also match '-dhcp' suffix in dhcp subsystem messages,
+ thanks to Michał Sawicz

   [ Gerfried Fuchs ]
   * debian/logcheck.NEWS, debian/logtail.NEWS:
diff --git a/rulefiles/linux/ignore.d.server/dnsmasq b/rulefiles/linux/ignore.d.server/dnsmasq
index 3746b80..6c87bbc 100644
--- a/rulefiles/linux/ignore.d.server/dnsmasq
+++ b/rulefiles/linux/ignore.d.server/dnsmasq
@@ -1,5 +1,5 @@
 ^\w{3} [ :0-9]{11} [._[:alnum:]-]+ dnsmasq\[[[:digit:]]+\]: read /etc/hosts - [[:digit:]]+ addresses$
 ^\w{3} [ :0-9]{11} [._[:alnum:]-]+ dnsmasq\[[[:digit:]]+\]: reading (/var/run/dnsmasq/|/etc/)resolv.conf$
 ^\w{3} [ :0-9]{11} [._[:alnum:]-]+ dnsmasq\[[[:digit:]]+\]: using nameserver [.[:digit:]#]+$
-^\w{3} [ :0-9]{11} [._[:alnum:]-]+ dnsmasq\[[[:digit:]]+\]: (DHCPDISCOVER|DHCPOFFER|DHCPREQUEST|DHCPACK|DHCPRELEASE|DHCPINFORM|BOOTP)\([[:alnum:]]+\) [ :[:alnum:]._-]+$
+^\w{3} [ :0-9]{11} [._[:alnum:]-]+ dnsmasq(-dhcp)?\[[[:digit:]]+\]: (DHCPDISCOVER|DHCPOFFER|DHCPREQUEST|DHCPACK|DHCPRELEASE|DHCPINFORM|BOOTP)\([[:alnum:]]+\) [ :[:alnum:]._-]+$
 ^\w{3} [ :0-9]{11} [._[:alnum:]-]+ dnsmasq\[[[:digit:]]+\]: ignoring nameserver 127\.0\.0\.1 - local interface$

Revision history for this message
Loïc Minier (lool) wrote :
description: updated
Revision history for this message
Martin Pitt (pitti) wrote : Please test proposed package

Accepted logcheck into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in logcheck (Ubuntu Lucid):
status: Confirmed → Fix Committed
tags: added: verification-needed
Revision history for this message
Loïc Minier (lool) wrote :

Tested for a day, saw some DHCP logs but got no logcheck email; works well for me

tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package logcheck - 1.3.7ubuntu1

---------------
logcheck (1.3.7ubuntu1) lucid-proposed; urgency=low

  * ignore.d.server/dnsmasq: allow -dhcp suffix in DHCP messages; taken from
    Debian 1.3.8; LP: #508142.
 -- Loic Minier <email address hidden> Mon, 03 May 2010 15:29:06 +0200

Changed in logcheck (Ubuntu Lucid):
status: Fix Committed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

Copied lucid-proposed to maverick.

Changed in logcheck (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.