How to setup and configure network bridge on Debian Linux
To set up and configure a network bridge on Debian Linux, follow these steps:
- Install the required packages:
sudo apt-get update sudo apt-get install bridge-utils -y - Create a backup of your network interfaces configuration file:
sudo cp /etc/network/interfaces /etc/network/interfaces.bak - Edit the network interfaces configuration file:
sudo nano /etc/network/interfaces - Define the network bridge, replace
eth0with the name of your Ethernet interface:auto br0 iface br0 inet dhcprn bridge_ports eth0 bridge_stp off bridge_fd 0 bridge_maxwait 0 - Restart the networking service to apply the changes:
sudo systemctl restart networking - Verify the network bridge is up and running:
sudo brctl show - Verify the IP address of the bridge interface:
ip addr show br0
