From: <lists@sterenborg.info>
To: netfilter@vger.kernel.org
Subject: Re: prevent iptables LOG target from flooding dmesg
Date: Sun, 06 Jun 2010 09:09:43 +0200 [thread overview]
Message-ID: <1275808183.2492.20.camel@localhost> (raw)
In-Reply-To: <4C0AB6AD.104@asyr.hopto.org>
On Sat, 2010-06-05 at 23:42 +0300, Thanasis wrote:
> The subject says it all.
> I have set up logging like so :
> --------------------------------------------------------------------------------------------------------------------
> iptables -A INPUT -m state --state INVALID -j LOG --log-prefix "DROP
> INVALID " --log-ip-options --log-tcp-options
> iptables -A INPUT -i $INTIF ! -s $LAN -j LOG --log-prefix "SPOOFED PKT "
> iptables -A INPUT ! -i lo -j LOG --log-prefix "DROP " --log-ip-options
> --log-tcp-options
> iptables -A OUTPUT -m state --state INVALID -j LOG --log-prefix "DROP
> INVALID " --log-ip-options --log-tcp-options
> iptables -A OUTPUT ! -o lo -j LOG --log-prefix "DROP " --log-ip-options
> --log-tcp-options
> iptables -A FORWARD -m state --state INVALID -j LOG --log-prefix "DROP
> INVALID " --log-ip-options --log-tcp-options
> iptables -A FORWARD -i $INTIF ! -s $LAN -j LOG --log-prefix "SPOOFED PKT "
> iptables -A FORWARD ! -i lo -j LOG --log-prefix "DROP " --log-ip-options
> --log-tcp-options
> --------------------------------------------------------------------------------------------------------------------
> and dmesg is flooded by DROP log messages etc.
> I have NETFILTER_NETLINK_LOG [=m]
> in the kenel config, but I don't know how to use it,
> (and what the module name is).
> Any pointers/help will be much appreciated.
You can limit how much is logged with the 'limit' match. Doing this you
might lose some information but you might be okay with that. The 'limit'
match can be used like this:
$ipt [...] -m limit --limit 3/second [...]
However, I don't know if that's what you want.
--
Rob
next prev parent reply other threads:[~2010-06-06 7:09 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-05 20:42 prevent iptables LOG target from flooding dmesg Thanasis
[not found] ` <AANLkTilXnjHFMQI50wTupvFi2hIgf0tMhlu-lzPekPr7@mail.gmail.com>
2010-06-05 22:03 ` Thanasis
2010-06-06 3:03 ` Robby Workman
2010-06-06 5:26 ` Thanasis
2010-06-06 11:31 ` Jan Engelhardt
2010-06-06 13:42 ` Thanasis
2010-06-06 16:55 ` Thanasis
2010-06-06 7:09 ` lists [this message]
2010-06-06 10:52 ` Thanasis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1275808183.2492.20.camel@localhost \
--to=lists@sterenborg.info \
--cc=netfilter@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.