Forrest logo
tool overview
On this page you find all important commands for the CLI tool conntrack. If the command you are looking for is missing please ask our AI.

conntrack

Conntrack is a command line tool used in Linux operating systems for managing and viewing connection tracking information. It allows users to interact with the connection tracking system, which tracks information about network connections.

With conntrack, users can view and manipulate the state of network connections, including TCP, UDP, and ICMP connections. It provides information such as source and destination IP addresses, port numbers, connection states, and timeout values.

This tool is particularly useful for network administrators who need to monitor and troubleshoot network connections. It helps them identify active connections, track network traffic, and analyze network behavior.

Conntrack provides features like adding, updating, and deleting entries in the connection tracking table. Users can also query the conntrack table for specific information like connection counts, statistics, and timers.

Additionally, conntrack can be used to clear or flush the entire connection tracking table, which can be helpful in scenarios such as network or firewall configuration changes.

Conntrack supports various options and filters, allowing users to customize the output according to their requirements. It can filter connections based on source or destination IP addresses, port numbers, connection states, and more.

This tool relies on the Netfilter framework within the Linux kernel for connection tracking. It interacts with the connection tracking module to retrieve and modify connection tracking information.

Conntrack is often used in conjunction with other networking tools, such as iptables, to create complex firewall configurations and manage network security.

Overall, conntrack serves as a powerful command line utility for handling connection tracking in Linux, offering network administrators a versatile toolset for network monitoring and control.

List of commands for conntrack:

  • conntrack:tldr:01861 conntrack: List all currently tracked connections.
    $ conntrack --dump
    try on your machine
    explain this command
  • conntrack:tldr:7aa40 conntrack: Delete all flows for a specific source IP address.
    $ conntrack --delete --orig-src ${ip_address}
    try on your machine
    explain this command
  • conntrack:tldr:7abaa conntrack: Display a real-time event log of connection changes for a specific IP address.
    $ conntrack --event --orig-src ${ip_address}
    try on your machine
    explain this command
  • conntrack:tldr:c61a9 conntrack: Display a real-time event log of connection changes and associated timestamps.
    $ conntrack --event -o timestamp
    try on your machine
    explain this command
  • conntrack:tldr:f56dc conntrack: Display a real-time event log of connection changes.
    $ conntrack --event
    try on your machine
    explain this command
tool overview