星期三, 1月 09, 2008

Debian set up a bridge

My setting of /etc/network/interfaces
==================================
allow-auto lo br0 br1
allow-hotplug br0 br1

iface lo inet loopback

# The primary network interface

iface tap0 inet manual
up ifconfig $IFACE 0.0.0.0 promisc
down ifconfig $IFACE down
tunctl_user richman

iface eth0 inet manual
up ifconfig $IFACE 0.0.0.0 promisc
down ifconfig $IFACE down

iface br0 inet static
address 192.168.2.248
netmask 255.255.255.0
network 192.168.2.0
broadcast 192.168.2.255
bridge_ports eth0 tap0
bridge_maxwait 0
gateway 192.168.2.2
# dns-* options are implemented by the resolvconf package, if installed
dns-nameservers 192.168.2.2

iface tap1 inet manual
up ifconfig $IFACE 0.0.0.0 promisc
down ifconfig $IFACE down
tunctl_user richman

iface eth1 inet manual
up ifconfig $IFACE 0.0.0.0 promisc
down ifconfig $IFACE down

iface br1 inet static
address 192.168.1.100
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
bridge_ports eth1 tap1
bridge_maxwait 0

沒有留言: