Anecdotes from a Linux Systems Administrator. /root

Home About Books Blog Portfolio Archive
13 February 2013

Logging iptables rules

by Alpha01

When debugging certain custom firewall rules, it can sometimes be extremely useful log the rule’s activity. For example, the following rule logs all input firewall activity. The logs will be available via dmesg or syslog.

iptables -A INPUT -j LOG --log-prefix " iptables INPUT "
Tags: [ iptables networking ]