How to use the ip command to bring up/down the network interface on Linux

The ip command is replacing ifconfig, which is getting deprecated and some distros have already removed it.

To bring a network interface down, simply run the following:

sudo ip link set enp0s25 down

To bring it back up:

sudo ip link set enp0s25 up

where enp0s25 is my network adapter. By the way, its TAB auto-completion is fantastic!

Enjoy!

About SoCRaT

Systems Engineer, OSS & Linux Geek
This entry was posted in Linux and tagged , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s