Jun
25

With the growing popularity of our CCIE Service Provider Version 3.0 Rack Rentals, which include IOS XR, our support staff has been receiving an increasing number of trouble tickets where users are reporting physical connectivity problems of the IOS XR routers to their attached Ethernet switches.  In 99% of these cases the problem doesn’t stem from physical layer 1 issues, but instead from a misunderstanding of how IOS XR link negotiation works, since it is different than most other platforms.  While the fix for this problem is very simple, it’s one of those issues that can be incredibly frustrating for candidates learning IOS XR for the first time, since it’s really demotivating to not even be able to ping your directly connected layer 2 neighbor! :)  First, let’s examine the problem.

XR1 is connected to SW1 via GigabitEthernet as follows:

Both XR1 and SW1 have default configurations. Next, XR1 is configured with an IPv4 address on its link connecting to SW1, and SW1 is configured with a VLAN interface in the same subnet.

RP/0/0/CPU0:XR1#config t
Mon Jun 25 14:45:32.900 UTC
RP/0/0/CPU0:XR1(config)#int gig0/1/0/0
RP/0/0/CPU0:XR1(config-if)#ipv4 address 10.0.0.1/24
RP/0/0/CPU0:XR1(config-if)#commit
RP/0/0/CPU0:Jun 25 14:45:47.339 : config[65706]: %MGBL-CONFIG-6-DB_COMMIT : Configuration committed by user 'xradmin'. Use 'show configuration commit changes 1000000308' to view the changes.
RP/0/0/CPU0:XR1(config-if)#end
RP/0/0/CPU0:Jun 25 14:45:48.924 : config[65706]: %MGBL-SYS-5-CONFIG_I : Configured from console by xradmin
RP/0/0/CPU0:XR1#show ipv4 interface brief
Mon Jun 25 14:46:01.889 UTC

Interface                      IP-Address      Status                Protocol
MgmtEth0/0/CPU0/0              unassigned      Up                    Up
MgmtEth0/0/CPU0/1              unassigned      Up                    Up
MgmtEth0/0/CPU0/2              unassigned      Down                  Down
GigabitEthernet0/1/0/0         10.0.0.1        Up                    Up
GigabitEthernet0/1/0/1         unassigned      Up                    Up
GigabitEthernet0/1/0/2         unassigned      Up                    Up
GigabitEthernet0/1/0/3         unassigned      Up                    Up
POS0/6/0/0                     unassigned      Up                    Up      

SW1#show run int gig0/1
Building configuration...

Current configuration : 51 bytes
!
interface GigabitEthernet0/1
 port-type nni
end

SW1#config t
Enter configuration commands, one per line.  End with CNTL/Z.
SW1(config)#int vlan 1
SW1(config-if)#ip address 10.0.0.2 255.255.255.0
SW1(config-if)#no shut
SW1(config-if)#end
SW1#

XR1′s link shows up/up in the show ipv4 interface brief output, so you would assume that these hosts would have connectivity. Verification shows otherwise though.

RP/0/0/CPU0:XR1#ping 10.0.0.2
Mon Jun 25 14:58:05.972 UTC
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.0.2, timeout is 2 seconds:
..U..
Success rate is 0 percent (0/5)

Further digging shows that SW1′s link appears like there is a layer 1 problem:

SW1#show int gig0/1 status

Port      Name               Status       Vlan       Duplex  Speed Type
Gi0/1                        notconnect   1            full   1000 1000BaseSX SFP

This is normally where the rack rental user submits the support ticket ;)  A little digging in the documentation for IOS XR shows us what the problem is though:

By default, autonegotiation of Ethernet linecard ports is off.  Doh! :)  To get the link up then the fix is simple.  We either have to disable negotiation on the switch side, or enable negotiation on the router side.  The configuration of both options would be as follows:

SW1#config t
Enter configuration commands, one per line.  End with CNTL/Z.
SW1(config)#int gig0/1
SW1(config-if)#speed nonegotiate
SW1(config-if)#end
SW1#
*Mar  1 00:18:53.921: %SYS-5-CONFIG_I: Configured from console by console
*Mar  1 00:18:54.173: %LINK-3-UPDOWN: Interface GigabitEthernet0/1, changed state to up
*Mar  1 00:18:55.179: %LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to up
*Mar  1 00:19:23.055: %LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to up
SW1#ping 10.0.0.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.0.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/203/1007 ms
SW1#

SW1#config t
Enter configuration commands, one per line.  End with CNTL/Z.
SW1(config)#default int gig0/1
Interface GigabitEthernet0/1 set to default configuration
SW1(config)#end
SW1#
*Mar  1 00:20:01.844: %LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to down
*Mar  1 00:20:01.844: %LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to down
*Mar  1 00:20:02.045: %SYS-5-CONFIG_I: Configured from console by console
*Mar  1 00:20:02.876: %LINK-3-UPDOWN: Interface GigabitEthernet0/1, changed state to down
SW1#

RP/0/0/CPU0:XR1#config t
Mon Jun 25 15:09:56.192 UTC
RP/0/0/CPU0:XR1(config)#int gig0/1/0/0
RP/0/0/CPU0:XR1(config-if)#negotiation auto
RP/0/0/CPU0:XR1(config-if)#commit
RP/0/0/CPU0:Jun 25 15:10:06.300 : config[65706]: %MGBL-CONFIG-6-DB_COMMIT : Configuration committed by user 'xradmin'. Use 'show configuration commit changes 1000000312' to view the changes. 

SW1#
*Mar  1 00:20:27.857: %LINK-3-UPDOWN: Interface GigabitEthernet0/1, changed state to up
*Mar  1 00:20:28.863: %LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to up
*Mar  1 00:20:56.873: %LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to up
SW1#ping 10.0.0.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.0.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/203/1006 ms

Tada! Like I said, it’s a very simple solution to the problem, but it’s one of those things that if you’re not in the know, you’re out of luck. Can you imagine going to the CCIE Lab Exam and then failing because you can’t get your links into the up/up state? Ouch! :)

For those of you interested in learning more about IOS XR be sure to check out our CCIE Service Provider Version 3.0 Advanced Technologies Class on Demand, our CCIE Service Provider Version 3.0 Lab Workbook, and our CCIE Service Provider Version 3.0 Rack Rentals.

Thanks!

About Brian McGahan, CCIE #8593, CCDE #2013::13:

Brian McGahan was one of the youngest engineers in the world to obtain the CCIE, having achieved his first CCIE in Routing & Switching at the age of 20 in 2002. Brian has been teaching and developing CCIE training courses for over 10 years, and has assisted thousands of engineers in obtaining their CCIE certification. When not teaching or developing new products Brian consults with large ISPs and enterprise customers in the midwest region of the United States.

Find all posts by Brian McGahan, CCIE #8593, CCDE #2013::13 | Visit Website


You can leave a response, or trackback from your own site.

10 Responses to “IOS XR Ethernet Link Negotiation”

 
  1. Ali Gheidarpour says:

    Awesome!
    Thank you Brian

  2. JOHN MARSHAL CCIE RS says:

    thanks……..

  3. Melvin Reyes says:

    Cool, good to know..

    Thanks..

  4. Huck says:

    Cool, I got it, Tada.

  5. George M says:

    Thanks Brian.

  6. Pavan says:

    I tried both option but didn’t work . Here is output

    RP/0/0/CPU0:XR1#ping vrf XYZ 172.16.10.10
    Sun Jul 8 10:34:09.113 UTC
    Type escape sequence to abort.
    Sending 5, 100-byte ICMP Echos to 172.16.10.10, timeout is 2 seconds:
    ..U..
    Success rate is 0 percent (0/5)

    RP/0/0/CPU0:XR1#show run in GigabitEthernet0/1/0/0
    Sun Jul 8 10:29:18.284 UTC
    interface GigabitEthernet0/1/0/0
    vrf XYZ
    ipv4 address 172.16.10.19 255.255.255.0
    negotiation auto
    !

    SW1#show int gig0/1 status
    Port Name Status Vlan Duplex Speed Type
    Gi0/1 connected 1910 full 1000 1000BaseSX SFP

    SW1#show run in gig0/1
    interface GigabitEthernet0/1
    port-type nni
    switchport access vlan 1910
    spanning-tree portfast

    SW2#show ip int br | in Vlan1910
    Interface IP-Address OK? Method Status Protocol
    Vlan1910 172.19.10.10 YES manual up up

    ==================================================================
    2nd Option :-
    SW1(config)#do show run in GigabitEthernet0/1

    interface GigabitEthernet0/1
    port-type nni
    switchport access vlan 1910
    speed nonegotiate
    spanning-tree portfast

    SW1(config)#do show int gig0/1 status
    Port Name Status Vlan Duplex Speed Type
    Gi0/1 connected 1910 full 1000 1000BaseSX SFP

    RP/0/0/CPU0:XR1(config)#do show run in GigabitEthernet0/1/0/0
    Sun Jul 8 11:47:22.329 UTC
    interface GigabitEthernet0/1/0/0
    vrf XYZ
    ipv4 address 172.16.10.19 255.255.255.0
    !
    RP/0/0/CPU0:XR1(config)#do show ipv4 vrf XYZ inter br
    Sun Jul 8 11:51:21.966 UTC
    Interface IP-Address Status Protocol
    GigabitEthernet0/1/0/0 172.16.10.19 Up Up

    SW2# show ip int br
    Interface IP-Address OK? Method Status Protocol
    Vlan1910 172.19.10.10 YES manual up up

    RP/0/0/CPU0:XR1(config)#do ping vrf XYZ 172.19.10.10
    Sun Jul 8 11:50:53.554 UTC
    Type escape sequence to abort.
    Sending 5, 100-byte ICMP Echos to 172.19.10.10, timeout is 2 seconds:
    …..
    Success rate is 0 percent (0/5)

  7. Vivek says:

    Thank Brian…

  8. Thanx Brian. says:

    amazing…

 

Leave a Reply

Categories

CCIE Bloggers