Find the answer to your Linux question:
Results 1 to 3 of 3
Ok...so, the iptables counter can overflow if left to long and to zero the counters you can use the simple iptables -Z command. This would be very good information if ...
  1. #1
    Just Joined!
    Join Date
    Jun 2005
    Posts
    13

    iptables counters?



    Ok...so, the iptables counter can overflow if left to long and to zero the counters you can use the simple iptables -Z command. This would be very good information if I actually knew what the counters did!

    Ive done a lot of reading on the iptables framework, not once has anything explained what the counters do. Im just wondering........

    Anyone?

  2. #2
    Linux User
    Join Date
    Aug 2005
    Location
    Italy
    Posts
    401
    Count packets!
    When using Windows, have you ever told "Ehi... do your business?"
    Linux user #396597 (http://counter.li.org)

  3. #3
    Just Joined!
    Join Date
    Feb 2005
    Posts
    9
    When you do an iptables -L -v the left most counter is the number of packets that have matched that particular rule and the 2nd counter is the number of bytes that have matched that particular rule.

    An admin would want to see this for various reasons:
    - how often you get a connection to a specific port
    - to see if a a specific action matched the rule (when testing your firewall)
    - to see if a rule is ever matched
    - to see how much bandwidth was used by a particular service
    - for debugging (if you see counter on the INPUT but not on the OUTPUT)

    I am sure that most people could find more use of these.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •