TOTAL
Since dec 2006
1'942'871 Visitors
4'218'042 Pages

Nov 2010 Stats
82'909 Visitors
146'476 Pages
196 countries
Full statistics



Help us translate
our tutorials!

JOIN the
OpenManiak Team.
OM TEAM
Director:
Blaise Carrera
Tutorials creation:
Blaise Carrera
Translaters:
Giovanni Fredducci
Angel Chraniotis
Moham. H. Karvan
Alexandro Silva
Blaise Carrera
Andrei Chertolyas
Sergiy Uvarov
Nickola Kolev
Łukasz Nowatkowski
Ivo Raisr
Catalin Bivolaru
Bogdan A. Costea
Kirill Simonov
Oliver Mucafir
JaeYoung Jeon
Seungyoon Lee
Jie Yu & Si Cheng
Tao Wei
YukiAlex
Fumihito Yoshida
Muhammad Takdir
Çağdaş Tülek
Auditors
Leslie Luthi
Joe Anderson
Jennifer Ockwell
Nigel Titley
Alison Rees
Sabrina Barbey
Webmaster:
Blaise Carrera
VYATTA - The Easy Tutorial - Case Study 10 - Bridging

Vyatta Case 10 - Bridging
Last Change : Dec 26 2007


Tool
Install
Ergonomy
Forum



Details What is Vyatta?
Screenshots
Prerequisites
Tutorial Vyatta
Vyatta & Cisco Commands
Vyatta/Cisco/Quagga Comparison (Quagga section)
Case Study 1 - Static routes (VC 2.0)
Case Study 2 - OSPF simple (VC 2.0)
Case Study 3 - OSPF advanced (VC 2.0)
Case Study 4 - BGP (VC 3.0)
Case Study 5 - VRRP (VC 2.2)
Case Study 6 - NAT (VC 2.0)
Case Study 7 - DHCP (VC 2.2)
Case Study 8 - IPSec (VC 2.2)
Case Study 9 - Packages (VC 3.0)
Case Study 10 - Bridging (VC 3.0)
Case Study 11 - CDP VC 3.0




If you like our tutorials, don't hesitate to support us and visit our sponsors!
Si vous aimez nos tutoriaux, n'hésitez pas à nous supporter et visiter nos sponsors!



1. CASE PRINCIPLE 2. PICTURE 3. CONFIGURATIONS 4. SHOW COMMANDS



Vyatta version used: VC 3.0 Oct 29, 2007
1. CASE PRINCIPLE

Network bridges connects multiple network segments or local area networks at the data link layer (layer 2) of the OSI model.
The behavior of bridges are very similar to hubs or switches, they all let layer two broadcasts pass through them.
As a comparison, routers work at the layer three of the OSI model and will stop these broadcasts.

In our case study, we will bridge two network interfaces on three different components: a Vyatta router, a Cisco router and a Linux machine. (The windows XP bridging howto will come very soon).

An IP address is set on the bridges to be able to manage them:
On Vyatta, as this is not possible to do it from the router interface, you must do it at the Linux level.
On Cisco, you must activate the integrated routing and bridging (IRB) mode.


2. PICTURE

Functionalities tested:

(click on the web links to have more details about a protocol)

Interface settings
bridging

case study bridge vyatta   case study bridge cisco   case study bridge linux


3. CONFIGURATIONS

VYATTA ROUTER VC3.0 Oct 29, 2007
CISCO ROUTER 2621 IOS: 12.2(23a)
edit interfaces ethernet eth0
  set bridge-group bridge br0
interface FastEthernet0/0
  bridge-group 1
edit interfaces ethernet eth1
  set bridge-group bridge br0
interface FastEthernet0/1
  bridge-group 1
set system host-name Vyatta-Router hostname Cisco-router
set service telnet
 
line vty 0 4
  no login
 
 
bridge irb
bridge 1 protocol ieee
bridge 1 route ip
 
 
interface BVI 1
  ip address 10.0.2.1
 
Configurations done at the
Debian/Linux level
:
Login with the root user.
Set the bridge IP address:

#ifconfig br0 10.0.2.1 netmask 255.255.255.0
To keep your settings permanently:

#vim /etc/network/interfaces
auto br0
iface br0 inet static
address 10.0.2.1
netmask 255.255.255.0



LINUX Debian or Ubuntu

- Install the tools need to build a bridge:

#apt-get install bridge-utils
- Load the bridge kernel module:

#modprobe bridge
- Check that the bridge module is loaded:

#lsmod | grep bridge
- Activate the Ethernet interfaces:

#ifconfig eth0 up
#ifconfig eth1 up
- Create the bridge:

#brctl addbr br0
- Add members to the bridge:

#brctl addif br0 eth0
#brctl addif br0 eth1
- Set the bridge IP address:

#ifconfig br0 10.0.2.1 netmask 255.255.255.0
To keep your settings after a reboot, create the following script stored in the "/root/bridge.sh" file:

#!bin/bash
# Load the bridge kernel module
modprobe bridge
# Activate the Ethernet interfaces
ifconfig eth0 up
ifconfig eth1 up

# Create the bridge
brctl addbr br0
# Add members to the bridge
brctl addif br0 eth0
brctl addif br0 eth1
# Set the bridge IP address:
ifconfig br0 10.0.2.1 netmask 255.255.255.0
Then you have to add the following lines in the "/etc/crontab" file:

#vim /etc/crontab
@reboot root /root/bridge.sh


4. SHOW COMMANDS:

Vyatta Router

- Check the bridge status:

Vyatta-Router#show bridge
bridge name bridge id STP enabled interfaces
br0 8000.0000ab12cd34 no eth0
      eth1
The bridge ID begins with "8000" and is followed by the lowest MAC address of one of its members.

- Check the bridge members:

Vyatta-Router#show bridge br0 macs
port no mac addr is local? ageing timer
2   00:00:ab:12:cd:34 yes 0.00
1   00:04:11:22:33:44 yes 0.00
- Check the bridge interface:

vyatta:~#ifconfig br0
Cisco Router

- Check the bridge members:

#show interface irb
- Check the bridge interface:

#show interface BVI1
Linux Router

- Check the bridge status:

Linux#brctl show
bridge name bridge id STP enabled interfaces
br0 8000.0000ab12cd34 no eth0
      eth1
The bridge ID begins with "8000" and is followed by the lowest MAC address of one of its members.

- Check the bridge members:

Linux#brctl showmacs br0
port no mac addr is local? ageing timer
2   00:00:ab:12:cd:34 yes 0.00
1   00:04:11:22:33:44 yes 0.00
- Check the bridge interface:

Linux#ifconfig br0





If you liked our tutorials, don't hesitate to support us and visit our sponsors!
Si vous aimez nos tutoriaux, n'hésitez pas à nous supporter et visiter nos sponsors!