Open In App

ifup command in Linux with Examples

Improve
Improve
Like Article
Like
Save
Share
Report

The ifup command basically brings the network interface up, allowing it to transmit and receive data. Technically ifup command is used to configure network interfaces based on interface definitions in the file /etc/network/interfaces.

Syntax:

ifup [-nv] [--no-act] [--verbose] [-i FILE|--interfaces=FILE] [--allow CLASS] -a|IFACE...

Example: Let us see an example when our interface is down and how the browser reacts to it.

In this case, the interface was not up and configured. To get the network interface up and work we use

sudo ifup -av

Here, sudo is used for permissions, -a to work on all devices and v for verbose the output.

After using ifup command, the network is working:

Options:

  • -a(–all): If used this option it affects all the interfaces marked as auto. Brings up interfaces in order they are defined /etc/network/interfaces. Combined with –allow, acts on all interfaces of a specified class instead.
  • –force: Force configuration or deconfiguration of the interface.
  • -V: Prints the version information.
  • -v: Verbose the output as they are executed.

Last Updated : 22 May, 2019
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads