VRF lite

VRF bedeutet Virtual Router and Forwarding

Dieses wird dazu verwendet um IP bereiche im eigenen virtuellen Router laufen zu lassen.
Somit kann man auch die Gleichen Adressräume auf ein und dem gleichen Netzwerkgerät laufen lassen

Die Konfiguration besteht aus den VRFs Costumer_A und Costumer_B

R1
vrf definition Customer_A  <– definition des VRF 1
address-family ipv4
exit-address-family
!
vrf definition Customer_B  <– definition des VRF 2
address-family ipv4
exit-address-family
!
interface Ethernet0/0
vrf forwarding Customer_A <– VRF dem Interface zuweisen
ip address 10.1.2.1 255.255.255.0
!
interface Ethernet0/1.5
encapsulation dot1Q 5
vrf forwarding Customer_B <– VRF dem Interface zuweisen
ip address 10.1.2.1 255.255.255.0
!
interface Ethernet0/1.8
encapsulation dot1Q 8
vrf forwarding Customer_B <– VRF dem Interface zuweisen
ip address 10.1.3.1 255.255.255.0
!
interface Serial4/0
vrf forwarding Customer_A <– VRF dem Interface zuweisen
ip address 10.1.3.1 255.255.255.0
serial restart-delay 0
! —Routing für die VRFs anlegen—
ip route vrf Customer_A 192.168.2.0 255.255.255.0 Ethernet0/0 10.1.2.2
ip route vrf Customer_A 192.168.3.0 255.255.255.0 Serial4/0 10.1.3.2
ip route vrf Customer_B 192.168.2.0 255.255.255.0 Ethernet0/1.5 10.1.2.2
ip route vrf Customer_B 192.168.3.0 255.255.255.0 Ethernet0/1.8 10.1.3.2
!

R2
!
interface Loopback0
ip address 192.168.2.1 255.255.255.0
!
interface FastEthernet0/0
ip address 10.1.2.2 255.255.255.0
duplex auto
speed auto
!
ip route 0.0.0.0 0.0.0.0 FastEthernet0/0 10.1.2.1
!

R3
!
interface Loopback0
ip address 192.168.3.1 255.255.255.0
!
interface Serial1/0
ip address 10.1.3.2 255.255.255.0
serial restart-delay 0
!

A1
!
interface Ethernet0/1
switchport access vlan 5
switchport mode access
!
interface Ethernet0/3
switchport access vlan 8
switchport mode access
!
interface Ethernet1/1
switchport trunk encapsulation dot1q
switchport mode trunk
switchport nonegotiate
!

D1
!
interface Ethernet0/0
no switchport
ip address 10.1.2.2 255.255.255.0
duplex auto
!
interface Ethernet3/3
switchport access vlan 11
switchport mode access
!
interface Vlan11
ip address 192.168.2.1 255.255.255.0
!
ip route 0.0.0.0 0.0.0.0 Ethernet0/0 10.1.2.1
!

D2
!
interface Ethernet0/0
no switchport
ip address 10.1.3.2 255.255.255.0
duplex auto
!
!
interface Ethernet3/3
switchport access vlan 11
switchport mode access
!
interface Vlan11
ip address 192.168.3.1 255.255.255.0
!
ip route 0.0.0.0 0.0.0.0 Ethernet0/0 10.1.3.1
!
!