ip

What is ip

ip is a commandline tool used to assign an address to a network interface or configure network interface parameters.

ip usage

The most simple usage is to execute the command with a subcommand, which stands for ‘address’. It will output the statuses of all currently active interfaces:

ip a

In order to assign a static IP address to a network interface:

ip a add 192.168.1.10 dev eth0

In roder to remove the static IP address from a network interface:

ip a del 192.168.1.10 dev eth0

In order to conduct MAC spoofing (change MAC address):

ip link set dev eth0 address 00:11:22:33:44:55

In order to allow all traffic to the network (not only the traffic destined to the own MAC address, which is by default):

ip link set dev eth0 promisc on

In order to disable a network interface:

ip link set eth0 down

In order to enable a network interface:

ip link set eth0 up