Skip to content

Linux Network Bridges

Mattscreative edited this page Dec 5, 2025 · 2 revisions

Linux Network Bridges Guide

Complete beginner-friendly guide to network bridges on Linux, covering Arch Linux, CachyOS, and other distributions including bridge creation, bridge configuration, and bridge management.


Table of Contents

  1. Understanding Bridges
  2. Creating Bridges
  3. Bridge Configuration
  4. Bridge Management
  5. Troubleshooting

Understanding Bridges

What is a Bridge?

Network bridge connects multiple network segments at layer 2 (data link layer).

Common uses:

  • Virtualization (connecting VMs to network)
  • Network segmentation
  • Combining multiple interfaces

How it works:

  • Acts like a switch
  • Forwards traffic between interfaces
  • Transparent to network layer

Creating Bridges

Create Bridge

Using ip command:

# Create bridge
sudo ip link add name br0 type bridge

# Bring up bridge
sudo ip link set br0 up

Using systemd-networkd:

# Create bridge config
sudo vim /etc/systemd/network/br0.netdev

Add:

[NetDev]
Name=br0
Kind=bridge

Install Bridge Utils

Install tools:

# Arch/CachyOS
sudo pacman -S bridge-utils

# Debian/Ubuntu
sudo apt install bridge-utils

# Fedora
sudo dnf install bridge-utils

Bridge Configuration

Configure Bridge

Using systemd-networkd:

# Create network config
sudo vim /etc/systemd/network/br0.network

Add:

[Match]
Name=br0

[Network]
DHCP=yes
# Or static IP
# Address=192.168.1.100/24
# Gateway=192.168.1.1

Add Interface

Add to bridge:

# Add interface
sudo ip link set eth0 master br0

# Or in config
sudo vim /etc/systemd/network/eth0.network

Add:

[Match]
Name=eth0

[Network]
Bridge=br0

Remove Interface

Remove from bridge:

# Remove interface
sudo ip link set eth0 nomaster

Bridge Management

Bridge Status

Check bridge:

# List bridges
ip link show type bridge

# Show bridge info
bridge link show

# Show bridge details
ip link show br0

Bridge Statistics

View stats:

# Show bridge stats
bridge -s link show

# Show forwarding database
bridge fdb show

Troubleshooting

Bridge Not Working

Check status:

# Check bridge
ip link show br0

# Check interfaces
ip link show master br0

# Check bridge state
bridge link show

Interface Not Added

Verify:

# Check interface
ip link show eth0

# Check bridge membership
bridge link show

# Re-add if needed
sudo ip link set eth0 master br0

Summary

This guide covered network bridges for Arch Linux, CachyOS, and other distributions, including creation, configuration, and management.


Next Steps


This guide covers Arch Linux, CachyOS, and other Linux distributions. For distribution-specific details, refer to your distribution's documentation.

Clone this wiki locally