How To Install ifupdown2 on Debian 10

Learn how to install ifupdown2 on Debian 10 with this tutorial. ifupdown2 is Network Interface Management tool similar to ifupdown

Introduction

In this tutorial we learn how to install ifupdown2 on Debian 10.

What is ifupdown2

ifupdown2 is:

ifupdown2 is ifupdown re-written in Python. It replaces ifupdown and provides the same user interface as ifupdown for network interface configuration. Like ifupdown, ifupdown2 is a high level tool to configure (or, respectively deconfigure) network interfaces based on interface definitions in /etc/network/interfaces. It is capable of detecting network interface dependencies and comes with several new features which are available as new command options to ifup/ifdown/ifquery commands. It also comes with a new command ifreload to reload interface configuration with minimum disruption. Most commands are also capable of input and output in JSON format. It is backward compatible with ifupdown /etc/network/interfaces format and supports newer simplified format. It also supports interface templates with python-mako for large scale interface deployments. See /usr/share/doc/ifupdown2/README.rst for details about ifupdown2. Examples are available under /usr/share/doc/ifupdown2/examples.

There are three methods to install ifupdown2 on Debian 10. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install ifupdown2 Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install ifupdown2 using apt-get by running the following command:

sudo apt-get -y install ifupdown2

Install ifupdown2 Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install ifupdown2 using apt by running the following command:

sudo apt -y install ifupdown2

Install ifupdown2 Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Debian. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install ifupdown2 using aptitude by running the following command:

sudo aptitude -y install ifupdown2

How To Uninstall ifupdown2 on Debian 10

To uninstall only the ifupdown2 package we can use the following command:

sudo apt-get remove ifupdown2

Uninstall ifupdown2 And Its Dependencies

To uninstall ifupdown2 and its dependencies that are no longer needed by Debian 10, we can use the command below:

sudo apt-get -y autoremove ifupdown2

Remove ifupdown2 Configurations and Data

To remove ifupdown2 configuration and data from Debian 10 we can use the following command:

sudo apt-get -y purge ifupdown2

Remove ifupdown2 configuration, data, and all of its dependencies

We can use the following command to remove ifupdown2 configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge ifupdown2

Dependencies

ifupdown2 have the following dependencies:

References

Summary

In this tutorial we learn how to install ifupdown2 package on Debian 10 using different package management tools: apt, apt-get and aptitude.