Information Gatheringnetworkingarpifconfignetstatroutelinux

net-tools

NET-3 networking toolkit providing essential tools for controlling the Linux kernel's network subsystem. Includes utilities like arp, ifconfig, netstat, and route for network configuration and monitoring.

Description

The net-tools package delivers critical utilities for managing Linux network interfaces, ARP cache, routing tables, and related hardware configurations. It supports tasks such as displaying and modifying ARP entries, configuring interfaces, viewing network statistics, and handling IP tunnels or multicast addresses. These tools are fundamental for network troubleshooting, configuration, and diagnostics in Linux environments.

Use cases include inspecting network connections with netstat, setting up static ARP mappings with arp, configuring interfaces via ifconfig, and managing routing tables with route. Additional specialized tools like mii-tool for media interface status, iptunnel for IP tunnels, and slattach for serial line attachments cater to specific hardware and advanced IP configurations. Note that hostname utilities are provided in a separate package.

While some modern tools like ip and ss have superseded net-tools components, they remain widely used for compatibility and specific legacy requirements.

How It Works

Net-tools interacts directly with the Linux kernel's network subsystem via system calls and ioctls to query and manipulate configurations. Tools like arp modify the kernel ARP cache, ifconfig uses SIOCGIF* ioctls for interface settings, netstat reads /proc/net files and socket statistics, and route manipulates the kernel forwarding information base (FIB). Hardware-specific utilities like mii-tool access MII registers over network drivers, while iptunnel creates virtual tunnel devices using kernel GRE/IPIP modules.

Installation

bash
sudo apt install net-tools

Flags

arp -adisplay (all) hosts in alternative (BSD) style
arp -edisplay (all) hosts in default (Linux) style
arp -s, --setset a new ARP entry
arp -d, --deletedelete a specified entry
ifconfig -adisplay all interfaces
netstat -r, --routedisplay routing table
netstat -i, --interfacesdisplay interface table
mii-tool -v, --verbosemore verbose output
iptunnel addadd IP tunnel

Examples

Display arp usage help
arp -h
Display ifconfig usage help
ifconfig -h
Display netstat usage help
netstat -h
Display ipmaddr usage help for multicast addresses
ipmaddr -h
Display iptunnel usage help for IP tunnels
iptunnel -h
Display mii-tool usage help for interface status
mii-tool -h
Display nameif usage help for naming interfaces by MAC
nameif -h
Display route usage help for routing table manipulation
route -h
Updated 2026-04-16kali.org ↗