Linux Basic Network Command

explainshell.com - match command-line arguments to their help textarrow-up-right

ifconfig

  • Show different interface types and the IP address associated with them.

iwconfig

  • iwconfig is a command-line tool in Linux used to configure wireless network interfaces. It operates similarly to ifconfig, but it's specifically for wireless interfaces. It allows you to view and change wireless network settings, such as:

    • SSID (Network Name): The name of the wireless network.

    • Mode: Whether the wireless device is in ad-hoc mode, managed mode (connected to an access point), etc.

    • Frequency/Channel: The frequency on which the network operates.

    • Encryption: This shows if the network uses encryption, such as WEP or WPA.

    • Power Management: Control power saving options for wireless devices.

ping

  • send ICMP ECHO_REQUEST packets to network hosts

arp -a

arp -a is a command used in Windows, Linux, and other operating systems to display the ARP (Address Resolution Protocol) table. The ARP table maps IP addresses to their corresponding MAC addresses on a local network. This is essential for communication between devices on the same subnet, as devices need the MAC address of another device to send packets over Ethernet.

When you type arp -a, it shows the following:

  • IP address: The IP address ofdevice's the device in the network.

  • MAC address: The physical address of the network interface card (NIC).

  • Type: Whether the entry is dynamic (added automatically as devices communicate) or static (manually added).

arp-scan -l

  • Used to discover devices on a network by sending ARP requests. It helps to find all the active IP addresses within a local network.

netdiscover -r

  • Using ARP protocal to detect all machines on the network

netstat -ano

  • Show active connection are running on machine

route

  • The route command is used to view and manipulate the IP routing table.

ip

  • show / manipulate routing, devices, policy routing and tunnels

Last updated