Saturday, August 27, 2011

GLBP with GNS3

It's time to start GLBP using the same topology that I uploaded in my previous posts.

Here is the lab topology diagram.

Download the completed GNS3 file from https://docs.google.com/viewer?a=v&pid=explorer&chrome=true&srcid=0B889ogd4ltI2ZjdkYTg4YjMtMDU1My00MjI1LWFiYmUtOTYyMWVmYzAxNmM3&hl=en





Let's see the how it works.

- R1 and R2 will be running GLBP in interface fa0/0
- R3 will be PC as usual with gateway to virtual IP of 192.168.1.10
- R4 is the destination PC enabled with loopback IP 4.4.4.4. 
- Goal is to reach the loopback 4.4.4.4 from Router3 (PC).
- Network is running EIGRP routing to reach to other networks, 192.168.1.0, 172.16.1.0 and 172.16.2.0.
- To test, I have created two loopback interfaces; lo0, lo1 in R1 to track two interfaces with different weighting values.
- Shutting down lo0 in R1 will not release AVF role because of upper and lower value "glbp 1 weighting 110 lower 95 upper 103"
- To have authentication, use MD5 with string name "test123"

Configure in R1 as follow;

 glbp 1 ip 192.168.1.10
 glbp 1 priority 200
 glbp 1 preempt
---------------
 glbp 1 weighting 110 lower 95 upper 103
 glbp 1 authentication md5 key-string test123
 glbp 1 weighting track 1 decrement 10
 glbp 1 weighting track 2 decrement 10
 glbp 1 forwarder preempt delay minimum 2

The first three lines configure the AVG status whether it will be AVG or not. It depends upon the priority. As like HSRP and VVRP, it will release AVG to other routers.

The second part of the lines are weighting and tracking interfaces for AVF status. Changes in these lines effect the status of AVF.

In R2, configure as follow;


 glbp 1 ip 192.168.1.10
 glbp 1 preempt
 glbp 1 authentication md5 key-string test123
---------------
 glbp 1 forwarder preempt delay minimum 2

As nothing mention about priority and weighting value, R2 will get the default value of priority 100 and weighting "lower 1, upper 100" automatically.
---------------------------------------------------
Let's check GLBP status in both routers.
In R1,

FastEthernet0/0 - Group 1
  State is Active
    8 state changes, last state change 00:04:10
  Virtual IP address is 192.168.1.10
  Hello time 3 sec, hold time 10 sec
    Next hello sent in 1.192 secs
  Redirect time 600 sec, forwarder timeout 14400 sec
  Authentication MD5, key-string "test123"
  Preemption enabled, min delay 0 sec
  Active is local
  Standby is 192.168.1.2, priority 100 (expires in 8.448 sec)
  Priority 200 (configured)
  Weighting 110 (configured 110), thresholds: lower 95, upper 103
    Track object 1 state Up decrement 10
    Track object 2 state Up decrement 10
  Load balancing: round-robin
  Group members:
    c201.07e8.0000 (192.168.1.1) local
    c202.07e8.0000 (192.168.1.2) authenticated
  There are 2 forwarders (1 active)
  Forwarder 1
    State is Active
      9 state changes, last state change 00:17:12
    MAC address is 0007.b400.0101 (default)
    Owner ID is c201.07e8.0000
    Redirection enabled
    Preemption enabled, min delay 2 sec
    Active is local, weighting 110
    Client selection count: 3
  Forwarder 2
    State is Listen
    MAC address is 0007.b400.0102 (learnt)
    Owner ID is c202.07e8.0000
    Redirection enabled, 597.368 sec remaining (maximum 600 sec)
    Time to live: 14397.364 sec (maximum 14400 sec)
    Preemption enabled, min delay 2 sec
    Active is 192.168.1.2 (primary), weighting 100 (expires in 7.360 sec)
    Client selection count: 2

As you seen, Local router is active for Group1 and it's also "Forwarder1" .
One thing to note is default forwarder min delay is 30 sec and I have change to 2 sec" using "glbp 1 forwarder preempt delay minimum 2" to change the forwarder status as soon as there is status change in forwarder states.

What are the two MAC addresses in Forwarder 1 and 2. Noticed that R1 is local, it's MAC address is marked as "(default)" and Forwarder 2 MAC address is noted as "(learnt)", because it's learnt from R2.

Let's check in R2

R2#sh glbp
FastEthernet0/0 - Group 1
  State is Standby
    7 state changes, last state change 00:11:48
  Virtual IP address is 192.168.1.10
  Hello time 3 sec, hold time 10 sec
    Next hello sent in 2.164 secs
  Redirect time 600 sec, forwarder timeout 14400 sec
  Authentication MD5, key-string "test123"
  Preemption enabled, min delay 0 sec
  Active is 192.168.1.1, priority 200 (expires in 8.840 sec)
  Standby is local
  Priority 100 (default)
  Weighting 100 (default 100), thresholds: lower 1, upper 100
  Load balancing: round-robin
  Group members:
    c201.07e8.0000 (192.168.1.1) authenticated
    c202.07e8.0000 (192.168.1.2) local
  There are 2 forwarders (1 active)
  Forwarder 1
    State is Listen
      8 state changes, last state change 00:25:00
    MAC address is 0007.b400.0101 (learnt)
    Owner ID is c201.07e8.0000
    Time to live: 14398.160 sec (maximum 14400 sec)
    Preemption enabled, min delay 2 sec
    Active is 192.168.1.1 (primary), weighting 110 (expires in 8.152 sec)
  Forwarder 2
    State is Active
      1 state change, last state change 02:45:20
    MAC address is 0007.b400.0102 (default)
    Owner ID is c202.07e8.0000
    Preemption enabled, min delay 2 sec
    Active is local, weighting 100
    Client selection count: 1

Notice that it's in "Standby" and Forwarder 1 is in "listen" state but Forwarder2 of R2 is active and it's itself.
-------------------------------------------------------------------------------
Let's start change the loopback0 of the R1 down. Even though you shutdown loopback 0, nothing changed but interface track status console message appear as follow.
R1(config-if)#
*Mar  1 02:50:24.463: %TRACKING-5-STATE: 2 interface Lo0 line-protocol Up->Down

Check GLBP status in R1.

  Priority 200 (configured)
  Weighting 100 (configured 110), thresholds: lower 95, upper 103
    Track object 1 state Up decrement 10
    Track object 2 state Down decrement 10
----------
Noted that weighting change from 110 to 100 because of the decrements value of "Track object 1" is 10.
But, AVF status of the router won't be changed because of the lower value is "95".

Let's shutdown loopback 1 again. Look the console message.

R1(config-if)#
*Mar  1 02:56:31.787: %TRACKING-5-STATE: 1 interface Lo1 line-protocol Up->Down
R1(config-if)#
*Mar  1 02:56:33.787: %LINK-5-CHANGED: Interface Loopback1, changed state to administratively down
*Mar  1 02:56:34.787: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback1, changed state to down
R1(config-if)#
*Mar  1 02:56:37.543: %GLBP-6-FWDSTATECHANGE: FastEthernet0/0 Grp 1 Fwd 1 state Active -> Listen

AVF 1 will release it's active state to LISTEN because of the weighting value will now be 90. As the lower value is configured as "95", 90 is less than 95 and it' release AVF and R2 will be the active AVF. Check in both routers.
In R2's console, you will see as follow.
R2#
*Mar  1 02:56:25.455: %GLBP-6-FWDSTATECHANGE: FastEthernet0/0 Grp 1 Fwd 1 state Listen -> Active

Here is latest status of GLBP in R1,

FastEthernet0/0 - Group 1
  State is Active
    8 state changes, last state change 00:25:21
  Virtual IP address is 192.168.1.10
  Hello time 3 sec, hold time 10 sec
    Next hello sent in 2.420 secs
  Redirect time 600 sec, forwarder timeout 14400 sec
  Authentication MD5, key-string "test123"
  Preemption enabled, min delay 0 sec
  Active is local
  Standby is 192.168.1.2, priority 100 (expires in 9.848 sec)
  Priority 200 (configured)
  Weighting 90, low (configured 110), thresholds: lower 95, upper 103
    Track object 1 state Down decrement 10
    Track object 2 state Down decrement 10
  Load balancing: round-robin
  Group members:
    c201.07e8.0000 (192.168.1.1) local
    c202.07e8.0000 (192.168.1.2) authenticated
  There are 2 forwarders (0 active)
  Forwarder 1
    State is Listen
      10 state changes, last state change 00:03:00
    MAC address is 0007.b400.0101 (default)
    Owner ID is c201.07e8.0000
    Redirection enabled
    Preemption enabled, min delay 2 sec
    Active is 192.168.1.2 (secondary), weighting 100 (expires in 8.912 sec)
    Client selection count: 3
  Forwarder 2
    State is Listen
    MAC address is 0007.b400.0102 (learnt)
    Owner ID is c202.07e8.0000
    Redirection enabled, 598.912 sec remaining (maximum 600 sec)
    Time to live: 14398.908 sec (maximum 14400 sec)
    Preemption enabled, min delay 2 sec
    Active is 192.168.1.2 (primary), weighting 100 (expires in 8.908 sec)
    Client selection count: 2
---------------
Here is R2's GLBP status.

R2#sh glbp
FastEthernet0/0 - Group 1
  State is Standby
    7 state changes, last state change 00:26:46
  Virtual IP address is 192.168.1.10
  Hello time 3 sec, hold time 10 sec
    Next hello sent in 0.552 secs
  Redirect time 600 sec, forwarder timeout 14400 sec
  Authentication MD5, key-string "test123"
  Preemption enabled, min delay 0 sec
  Active is 192.168.1.1, priority 200 (expires in 7.128 sec)
  Standby is local
  Priority 100 (default)
  Weighting 100 (default 100), thresholds: lower 1, upper 100
  Load balancing: round-robin
  Group members:
    c201.07e8.0000 (192.168.1.1) authenticated
    c202.07e8.0000 (192.168.1.2) local
  There are 2 forwarders (2 active)
  Forwarder 1
    State is Active
      9 state changes, last state change 00:04:35
    MAC address is 0007.b400.0101 (learnt)
    Owner ID is c201.07e8.0000
    Time to live: 14122.908 sec (maximum 14400 sec)
    Preemption enabled, min delay 2 sec
    Active is local, weighting 100
  Forwarder 2
    State is Active
      1 state change, last state change 03:00:19
    MAC address is 0007.b400.0102 (default)
    Owner ID is c202.07e8.0000
    Preemption enabled, min delay 2 sec
    Active is local, weighting 100
    Client selection count: 1

Group status is still "Active" but, when you tracerroute from PC1 to 4.4.4.4, it will select 192.168.1.2 path.
Check in PC as follow.

First, clear APR cache in PC 
PC#clear arp-cache
Ping to 4.4.4.4 to update the latest gateway
PC#ping 4.4.4.4

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 4.4.4.4, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 8/237/1092 ms
PC#
--------
Then, traceroute to 4.4.4.4 and check APR table.

PC#traceroute 4.4.4.4

Type escape sequence to abort.
Tracing the route to 4.4.4.4

  1 192.168.1.2 68 msec 28 msec 8 msec
  2 172.16.2.4 36 msec *  100 msec

PC is using 192.168.1.2 (R2) is next hop instead of going from 192.168.1.1. Confirm the APR table whether it's using AVF of R2's MAC address as follow.

PC#sh arp
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  192.168.1.3             -   c203.07e8.0000  ARPA   FastEthernet0/0
Internet  192.168.1.10            1   0007.b400.0102  ARPA   FastEthernet0/0

As you seen, MAC address of 192.168.1.10 is changed from 0007.b400.0101 to 0007.b400.0102

Let's check the status of each router's GLBP status in brief.
You can see all router's glbp status, forwarding and MAC addresses as well.

R1#sh glbp brief
Interface   Grp  Fwd Pri State    Address         Active router   Standby router
Fa0/0       1    -   200 Active   192.168.1.10    local           192.168.1.2
Fa0/0       1    1   -   Listen   0007.b400.0101  192.168.1.2     -
Fa0/0       1    2   -   Listen   0007.b400.0102  192.168.1.2     -

R2#sh glbp brief
Interface   Grp  Fwd Pri State    Address         Active router   Standby router
Fa0/0       1    -   100 Standby  192.168.1.10    192.168.1.1     local
Fa0/0       1    1   -   Active   0007.b400.0101  local           -
Fa0/0       1    2   -   Active   0007.b400.0102  local           -

In above test, noted that group's state "Active/Standby" will not be change as R1's priority is 200 higher than the R2's default priority 100.

You can test by changing the priority to 230 or R2 and see what happened.
----------------
Finally, change loopback0 and 1 from R1 up again. Monitor the console message in R1


R1(config)#int lo0
R1(config-if)#no shut
R1(config-if)#int lo1
*Mar  1 03:14:57.199: %TRACKING-5-STATE: 2 interface Lo0 line-protocol Down->Up
R1(config-if)#int lo1
R1(config-if)#no shut
R1(config-if)#
*Mar  1 03:14:59.199: %LINK-3-UPDOWN: Interface Loopback0, changed state to up
*Mar  1 03:15:00.199: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to up
R1(config-if)#
*Mar  1 03:15:00.371: %TRACKING-5-STATE: 1 interface Lo1 line-protocol Down->Up
R1(config-if)#
*Mar  1 03:15:02.367: %LINK-3-UPDOWN: Interface Loopback1, changed state to up
*Mar  1 03:15:03.367: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback1, changed state to up
R1(config-if)#
*Mar  1 03:15:05.167: %GLBP-6-FWDSTATECHANGE: FastEthernet0/0 Grp 1 Fwd 1 state Listen -> Active

Let's traceroute again from PC to 4.4.4.4. Make sure to clean apr-cache and ping 4.4.4.4 first.

PC#traceroute 4.4.4.4

Type escape sequence to abort.
Tracing the route to 4.4.4.4

  1 192.168.1.1 68 msec 20 msec 12 msec
  2 172.16.1.4 44 msec *  72 msec

PC will be use the original path using R1 as above to reach to 4.4.4.4.

Sunday, August 14, 2011

HSRP with GNS3

Actually, I have to post HSRP first. But, before I post, I fond out that I have configured only with one HSRP group. As HSRP is available for load-balancing, I have amended my post with two HSRP groups.

Download GNS3 lab file from https://docs.google.com/leaf?id=0B889ogd4ltI2YmY3YTFmOGQtYmI1OC00ZTVmLTk4YTktMzU3NDBjNzg4MzZh&hl

OK, below is lab topology diagram.



Here are lab objectives;
  • R1 and R2 will be running as HSRP using two VIPs (192.168.1.10 and 192.168.1.20)
  • PC1 will be using R2 (with default gateway 192.168.1.10) to reach 4.4.4.4 (R4's loopback).
  • PC2 will be using R1 (with default gateway 192.168.1.20) to reach 4.4.4.4
  • Both of the links 172.16.1.0/24 and 172.16.2.0/24 will be using by two PCs at the same time without wasting another link's bandwidth.
  • Finally, create one loopback interface in R1 (1.1.1.1) to track interface up /down which will lower the priority of R1 and R2 will take over as standby router. In that case, both R2 will be used by two PCs.


OK, let's create R1 as follow. Set decrements value to 102 to release R1's active status when loopbackup interface down.

interface FastEthernet0/0
 ip address 192.168.1.2 255.255.255.0
 duplex auto
 speed auto
 standby 1 ip 192.168.1.10
 standby 1 priority 200
 standby 1 preempt
 standby 1 track Loopback0 102
 standby 2 ip 192.168.1.20
 standby 2 preempt

interface Loopback0
 ip address 1.1.1.1 255.255.255.255

interface FastEthernet0/1
 ip address 172.16.1.1 255.255.255.0
 duplex auto
 speed auto
!
router eigrp 1
 network 0.0.0.0
 no auto-summary
--------------------------------------------------
In R2, configure as follow using default priorities 100 for group 1 and 150 for group 2 as R2 will be active for second group.

interface FastEthernet0/0
 ip address 192.168.1.1 255.255.255.0
 duplex auto
 speed auto
 standby 1 ip 192.168.1.10
 standby 1 preempt
 standby 2 ip 192.168.1.20
 standby 2 priority 150
 standby 2 preempt

interface FastEthernet0/1
 ip address 172.16.2.2 255.255.255.0
 duplex auto
 speed auto
!
router eigrp 1
 network 0.0.0.0
 no auto-summary

---------------------------
Check HSRP status in R1 and R2 as follow.

R1#sh standby brief

Interface   Grp  Pri P State   Active          Standby         Virtual IP
Fa0/0       1    200 P Active  local           192.168.1.1     192.168.1.10
Fa0/0       2    100 P Standby 192.168.1.1     local           192.168.1.20
----------------------
R2#sh standby brief

Interface   Grp  Pri P State   Active          Standby         Virtual IP
Fa0/0       1    100 P Standby 192.168.1.2     local           192.168.1.10
Fa0/0       2    150 P Active  local           192.168.1.2     192.168.1.20

As you can see that, group 1's active router is R1 (due to high priority 200 while R2 is default 100) and group 2's active router is R2 (due to R2's priority is 150 while R1 is setting default 100).

As EIGRP routing is running in R1, R2 and R4, try to run traceroute 4.4.4.4 from PC1 and PC2.

Set PC1's default gateway to 192.168.1.10 (HSRP Group 1's VIP) and PC2 to 192.168.1.20 (HSRP Group 2's VIP)

Here is the traceroute output from PC1 to 4.4.4.4. It's using R2 to reach 4.4.4.4

PC1#traceroute 4.4.4.4

Type escape sequence to abort.
Tracing the route to 4.4.4.4

  1 192.168.1.2 48 msec 88 msec 24 msec
  2 172.16.1.4 16 msec 84 msec *

From PC2, as expected, it's using R1 to reach to 4.4.4.4

PC2#traceroute 4.4.4.4

Type escape sequence to abort.
Tracing the route to 4.4.4.4

  1 192.168.1.1 60 msec 72 msec 8 msec
  2 172.16.2.4 52 msec *  72 msec


Because of this both links are load balanced to reach to another end 4.4.4.4 by setting different gateway IPs in each PC.

Try shutting down loopback 0 interface from R1 manually. Both of the PC will use R2 as default gateway as R2 will be active routers for both HSRP groups.


R1#sh standby brief


Interface   Grp  Pri P State   Active          Standby         Virtual IP
Fa0/0       1    98  P Standby 192.168.1.1     local           192.168.1.10
Fa0/0       2    100 P Standby 192.168.1.1     local           192.168.1.20
-----------------



R2#sh standby brief


Interface   Grp  Pri P State   Active          Standby         Virtual IP
Fa0/0       1    100 P Active  local           192.168.1.2     192.168.1.10
Fa0/0       2    150 P Active  local           192.168.1.2     192.168.1.20

PC1 will be used R2  as shown below as R2 is the active router.

PC1#traceroute 4.4.4.4

Type escape sequence to abort.
Tracing the route to 4.4.4.4

  1 192.168.1.1 44 msec 68 msec 44 msec
  2 172.16.2.4 48 msec 96 msec *

VRRP with GNS3

Looking for practising VRRP with Packet tracer is impossible and I have tried with GNS3 as follow to understand more about VRRP.

Download completed lab file https://docs.google.com/viewer?a=v&pid=explorer&chrome=true&srcid=0B889ogd4ltI2YTcxODhkMzktNWRmYS00M2JlLTg2ZjQtYmVmODExNjI2MzRh&hl=en_US

If you want to know more about VRRP for CCNP switching exam, follow the post. Here is lab diagram.


R1 will be master and R2 will act as backup VRRP. MD5 authenication setup using key-string "test" and R1 will track preconfigured loopback lo0 with priority 200. When loopback lo0 down, it will decrease the value to 101 and configured value will be 99 left. Then, R2 will be acting as Master.

R3 will be working as PC and trying to achieve the testing by ping R4's loopback IP (4.4.4.4).

R1, R2 , R4 will be configure as 172.16.1.0/24, 172.16.2.0/24 networks and configure EIGRP for routing. Configure routing for all network including loopback using "network 0.0.0.0"

Configure R1 and R2 as follow.

In R1,

 vrrp 1 ip 192.168.1.10
 vrrp 1 priority 200
 vrrp 1 authentication md5 key-string test
 vrrp 1 track 1 decrement 101


In R2,
 vrrp 1 ip 192.168.1.10
 vrrp 1 authentication md5 key-string test

-----------------------------------------

In  R3, configure as PC follow;

interface FastEthernet0/0
ip address 192.168.1.3 255.255.255.0

In global config mode,  add two extra line for default gateway to VRRP IP and turn off ip routing as follow.

no ip routing
ip default-gateway 192.168.1.10

----------------------------------------
After all configured, check in R1's configuration using "sh vrrp" command and confirmed that R1 is Master.
Important note is that in VRRP, "preemption" is already enabled. So, the coup process is already enabled and no manually configuration is needed like in HSRP and GLBP.

R1#sh vrrp
FastEthernet0/0 - Group 1
  State is Master
  Virtual IP address is 192.168.1.10
  Virtual MAC address is 0000.5e00.0101
  Advertisement interval is 1.000 sec
  Preemption enabled
  Priority is 200
    Track object 1 state Up decrement 101
  Authentication MD5, key-string "test"
  Master Router is 192.168.1.1 (local), priority is 200
  Master Advertisement interval is 1.000 sec
  Master Down interval is 3.218 sec
-----------------
In R2,

R2#sh vrrp
FastEthernet0/0 - Group 1
  State is Backup
  Virtual IP address is 192.168.1.10
  Virtual MAC address is 0000.5e00.0101
  Advertisement interval is 1.000 sec
  Preemption enabled
  Priority is 100
  Authentication MD5, key-string "test"
  Master Router is 192.168.1.1, priority is 200
  Master Advertisement interval is 1.000 sec
  Master Down interval is 3.609 sec (expires in 2.657 sec)
-----------------------
Let's check in R1's log using "debug vrrp packets". Checking logs are important as you need to interpret the status of VRRP in exam. As you see that, Master VRRP is doing only advertising. 

R1#
*Mar  1 01:12:09.079: VRRP: Grp 1 sending Advertisement checksum C4E2
*Mar  1 01:12:10.075: VRRP: Grp 1 sending Advertisement checksum C4E2
R1#
*Mar  1 01:12:10.887: VRRP: Grp 1 sending Advertisement checksum C4E2
*Mar  1 01:12:11.739: VRRP: Grp 1 sending Advertisement checksum C4E2

Let's check in R2's log. R2 's backup VRRP and it's getting advertisement from R1's with priority 200

R2#
*Mar  1 01:17:09.039: VRRP: Grp 1 Advertisement priority 200, ipaddr 192.168.1.1
*Mar  1 01:17:09.039: VRRP: Grp 1 Event - Advert higher or equal priority
*Mar  1 01:17:09.987: VRRP: Grp 1 Advertisement priority 200, ipaddr 192.168.1.1
*Mar  1 01:17:09.987: VRRP: Grp 1 Event - Advert higher or equal priority
-----------------------
OK, now let's do traceroute from PC (R3) to R4's loopback 4.4.4.4. Route will use R1 to reach to 4.4.4.4

PC#traceroute 4.4.4.4

Type escape sequence to abort.
Tracing the route to 4.4.4.4

  1 192.168.1.1 132 msec 60 msec 16 msec
  2 172.16.1.4 88 msec *  140 msec

Check which MAC address is using for 192.168.1.10 in PC. It's using 0000.5e00.0101.

PC#sh arp
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  192.168.1.2            51   c201.0ff0.0000  ARPA   FastEthernet0/0
Internet  192.168.1.3             -   c202.0ff0.0000  ARPA   FastEthernet0/0
Internet  192.168.1.10            4   0000.5e00.0101  ARPA   FastEthernet0/0
----------------
Clear arp cache in PC and let's change the status of R1's loopback to lower down the priority of R1 to 99.
Before to do that, it's need to create track object in R1. Interface tracking in VRRP is different with HSRP and GLBP. In GLBP and HSRP, you have to configure in interface mode.

Actually, there is no direct interface tracking system in VRRP to allow more capable routers as master role.

In global config mode, configure as follow in R1.

track 1 interface Loopback0 line-protocol

Make sure to include "track 1" in vrrp config in Interface fa0/1 as follow.
vrrp 1 track 1 decrement 101
--------------------------------
Ok, let's shutdown loopback 0 from R1.

R1(config-if)#
*Mar  1 01:25:10.631: %TRACKING-5-STATE: 1 interface Lo0 line-protocol Up->Down
---------------------
R1(config-if)#
*Mar  1 01:25:14.079: %VRRP-6-STATECHANGE: Fa0/0 Grp 1 state Master -> Backup
------------------------------
In R2, you will notice the following console message appear that it's change to Master VRRP

R2#
*Mar  1 01:25:10.055: %VRRP-6-STATECHANGE: Fa0/0 Grp 1 state Backup -> Master
--------------------------------
Let's check traceroute again from PC to 4.4.4.4. As you seen in below, this time, PC is using R2 as next hop to reach R4.

PC#traceroute 4.4.4.4

Type escape sequence to abort.
Tracing the route to 4.4.4.4

  1 192.168.1.2 64 msec 36 msec 12 msec
  2 172.16.2.4 36 msec *  116 msec
-------------------------------------
Interesting , checking MAC address of 192.168.1.10 in PC is the same as before as VRRP is using the same IP with same MAC address (0000.5e00.0101) for master and backup where ((0000.5e00.01) is for VRRP's address and (01) is for VRRP group number.

PC#sh arp
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  192.168.1.2             1   c201.0ff0.0000  ARPA   FastEthernet0/0
Internet  192.168.1.3             -   c202.0ff0.0000  ARPA   FastEthernet0/0
Internet  192.168.1.10            1   0000.5e00.0101  ARPA   FastEthernet0/0

Friday, August 12, 2011

VOIP Lab with Packet Tracer 5.3

I have looked in Internet as usual using Google :) to test VOIP using Packet Tracer. Two or three links fond and all are interesting. But, I would like to customize my own and see below if you are also looking like me.

Here is lab diagram. Download completed Packet Tracer file from https://docs.google.com/leaf?id=0B889ogd4ltI2MTFmYzJhNjgtYjE3OC00ZmE5LWEzZWMtOGFiOTg0MDkwMmM1&hl=en_US


It's a simple lab. One Cisco router as "Configure Call Manager ExpressTM", Cisco phones, digital to analog home VOIP PT to convert from digital to analog phone. I have added two PCs using different VLAN; one is connected with Cisco IP phone to test mls. VLAN 1 is for voice VLAN and two PCs are in VLAN 10 with static IP.

First, drag all devices in Cisco Packet Tracer and configure router to work as DHCP server to lease IP addresses for IP phones.

ip dhcp pool test-vlan
 network 192.168.10.0 255.255.255.0
 default-router 192.168.10.1
 option 150 ip 192.168.10.1

Using option 150 is required to provide IP address to Cisco phone. Pool range is the whole network of 192.168.10.0/24.

More detail about how to configure for IP phones are avaliable in packet tracer website at http://www.packettracernetwork.com/voipconfiguration.html

Here is the config file of router.

telephony-service
 max-ephones 3
 max-dn 3
 ip source-address 192.168.10.1 port 2005
 auto assign 1 to 5
!
ephone-dn 1
 number 1001
!
ephone-dn 2
 number 1005
!
ephone-dn 3
 number 1010
!

I have used IP phones with power supply. So, power adapter need to plug to get IP phone online. If you don't want and need PoE, have to use multilayer switch.

Configure switch as follow; Enable trust boundary to Cisco phone using "mls qos trust device cisco-phone".

interface FastEthernet0/1
 switchport access vlan 10
 switchport mode trunk
 switchport voice vlan 1
 mls qos trust device cisco-phone
!
interface FastEthernet0/4
 switchport mode access
 switchport voice vlan 1
!
interface FastEthernet0/5
 switchport mode access
 switchport voice vlan 1



Check in switch after phone online whether it's trusted Cisco Phone or not by executing command "mls qos interface fa0/1". trust device: cisco-phone is appear in outpout.



Switch#sh mls qos interface fa0/1
FastEthernet0/1
trust state: not trusted
trusted mode: not trusted
COS override: dis
default COS: 0
pass-through: none
trust device: cisco-phone


As soon as IP phones are online, following message appear in Cisco router and confirmed that phone are registered with IP address.


Router#
%IPPHONE-6-REGISTER: ephone-1 IP:192.168.10.2 Socket:2 DeviceType:Phone has registered.
Router#
%IPPHONE-6-REGISTER: ephone-2 IP:192.168.10.3 Socket:2 DeviceType:Phone has registered.


Phone number will be appear in upper right corner of the phone GUI screen.



Check lease IP address in router using following command.

Router#sh ip dhcp binding 
IP address       Client-ID/              Lease expiration        Type
                 Hardware address
192.168.10.3     0006.2A21.B937           --                     Automatic
192.168.10.4     000B.BE52.8501           --                     Automatic
192.168.10.2     0001.9628.4786           --                     Automatic
192.168.10.6     0010.11E9.75C9           --                     Automatic


For HomeVOIP-PT device, type the Cisco router (Call Manager) ip address as follow;


Check by moving mouse over to phone device whether it's getting IP address and appearing extension number or not as follow.


Try to make call between two IP phones as well as from analog to IP phone.

Configure different IP address for two PCs as mentioned in lab diagram; 192.168.1.1 and 192.168.1.2 and assign to VLAN 10. Voice VLAN has already configured as VLAN 1.