Network interfaces provide the paths a Linux host uses to send and receive traffic. ip link takes an existing interface down for the current runtime without deleting it or changing its persistent manager configuration.
The ip command changes the interface's administrative state in the kernel. Running ip link set dev eth0 down clears the UP and LOWER_UP flags for that device, while assigned addresses can still appear in ip addr until the interface is raised or reconfigured.
Routes that depend on the disabled interface are withdrawn from the active routing table, so applications cannot use that path even if the address record remains visible. Disabling the interface that carries an SSH or remote management session disconnects that session immediately, and higher-level managers such as NetworkManager or systemd-networkd may bring the interface back after a reconnect, service reload, or reboot unless their persistent configuration is changed separately.
Steps to temporarily disable a network interface in Linux:
- Identify the network interface to disable.
$ ip -br link lo UNKNOWN 00:00:00:00:00:00 <LOOPBACK,UP,LOWER_UP> eth0 UP 52:54:00:12:34:56 <BROADCAST,MULTICAST,UP,LOWER_UP>
The first column is the interface name, such as eth0, enp1s0, ens33, or wlp2s0. Confirm the exact device before taking it down, especially on hosts with bridges, bonds, VLANs, VPNs, or container interfaces.
- Bring the selected interface down.
$ sudo ip link set dev eth0 down
Disabling the interface that carries the active remote session immediately disconnects that session and can remove the host's route to other networks. On a remote host, make sure local-console access or a management connection that does not use this interface works first, so you can enable the interface again.
- Confirm that the interface is administratively down.
$ ip link show dev eth0 2: eth0: <BROADCAST,MULTICAST> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000 link/ether 52:54:00:12:34:56 brd ff:ff:ff:ff:ff:ffMissing UP and LOWER_UP plus state DOWN show that the kernel is no longer treating the link as active. The address can stay in ip addr while the interface is down, but routes through it are no longer active.