XWLinux

ip

Zarządzanie interfejsem sieciowym (iproute2).

Opis

ip (iproute2) — interfejsy, adresy, routy, linki, neighboury. addr (adresy), route (routy), link (interfejsy), neigh (ARP table). Zastępuje ifconfig + route + arp. ip a = adresy, ip r = routy, ip link show = interfejsy.

Przykłady

$ ip a
Adresy IP wszystkich interfejsów
$ ip r
Routing table
$ ip link show
Interfejsy (MAC, status)
$ ip neigh
ARP table
$ ip route add 192.168.1.0/24 via 192.168.0.1
Dodaj trasę
$ ip addr add 10.0.0.2/24 dev eth0
Dodaj IP do interfejsu

Flagi

FlagaOpis
ip a Adresy (skrót: ip addr)
ip r Routing table (skrót: ip route)
ip link Interfejsy
ip neigh ARP table
ip s Socket (skrót: ip socket)
ip netns Network namespaces
-s Statistics (per interfejs)
-V Verbose
-4/-6 IPv4/IPv6 only