<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>xpresslearn.com &#187; Cisco</title>
	<atom:link href="http://www.xpresslearn.com/category/cisco/feed" rel="self" type="application/rss+xml" />
	<link>http://www.xpresslearn.com</link>
	<description>Solutions to your Networking and Security questions</description>
	<lastBuildDate>Wed, 30 Jun 2010 18:20:08 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Configure a Basic MPLS Network II</title>
		<link>http://www.xpresslearn.com/cisco/mpls-cisco/configure-a-basic-mpls-network-ii</link>
		<comments>http://www.xpresslearn.com/cisco/mpls-cisco/configure-a-basic-mpls-network-ii#comments</comments>
		<pubDate>Thu, 10 Jun 2010 22:56:36 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[MPLS]]></category>
		<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Label Switching]]></category>
		<category><![CDATA[LDP]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=362</guid>
		<description><![CDATA[Part 2 of many articles explaining how to build out an internal MPLS network.  This article starts off with basic MPLS specific configuration added to the network that was established in the first article.]]></description>
			<content:encoded><![CDATA[<p>In the first article, we went over some very basic MPLS terms and explanations.  That article ended with a basic network using four 7206 routers &#8211; two in each datacenter.  At this point, we have no routing protocols or MPLS configuration.  All we can do presently is ping directly connected interfaces of neighboring devices.  The first thing that we want to establish, is the routing protocol used by the MPLS aware devices to determine how to reach the other core devices.</p>
<p>The routing protocol distributes topology information through the network so that the route of a Label Switched Path (LSP) can be calculated.  An interior gateway protocol, such as OSPF or IS-IS, is normally used, as MPLS networks typically cover a single administrative domain.  Let&#8217;s configure OSPF on the P/Core devices so that we can ping every interface on all four routers.</p>
<p>
<pre>
hostname r1
!
interface Loopback1
 ip address 10.254.1.1 255.255.255.255
!
interface FastEthernet1/0
 description r2 f1/0
 ip address 10.1.1.1 255.255.255.252
!
interface FastEthernet1/1
 description r3 f1/1
 ip address 10.1.1.5 255.255.255.252
!
router ospf 1
 log-adjacency-changes
 network 10.1.1.0 0.0.0.3 area 0
 network 10.1.1.4 0.0.0.3 area 0
 network 10.254.1.1 0.0.0.0 area 0
</pre>
</p>
<p>
<pre>
hostname r2
!
interface Loopback1
 ip address 10.254.1.2 255.255.255.255
!
interface FastEthernet1/0
 description r1 f1/0
 ip address 10.1.1.2 255.255.255.252
!
interface FastEthernet1/1
 description r4 f1/1
 ip address 10.1.1.13 255.255.255.252
!
router ospf 1
 log-adjacency-changes
 network 10.1.1.0 0.0.0.3 area 0
 network 10.1.1.12 0.0.0.3 area 0
 network 10.254.1.2 0.0.0.0 area 0
</pre>
</p>
<p><span id="more-362"></span></p>
<p>
<pre>
hostname r3
!
interface Loopback1
 ip address 10.254.1.3 255.255.255.255
!
interface FastEthernet1/0
 description r4 f1/0
 ip address 10.1.1.9 255.255.255.252
!
interface FastEthernet1/1
 description r1 f1/1
 ip address 10.1.1.6 255.255.255.252
!
router ospf 1
 log-adjacency-changes
 network 10.1.1.4 0.0.0.3 area 0
 network 10.1.1.8 0.0.0.3 area 0
 network 10.254.1.3 0.0.0.0 area 0
</pre>
</p>
<p><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>
<pre>
hostname r4
!
interface Loopback1
 ip address 10.254.1.4 255.255.255.255
!
interface FastEthernet1/0
 description r3 f1/0
 ip address 10.1.1.10 255.255.255.252
!
interface FastEthernet1/1
 description r2 f1/1
 ip address 10.1.1.14 255.255.255.252
!
router ospf 1
 log-adjacency-changes
 network 10.1.1.8 0.0.0.3 area 0
 network 10.1.1.12 0.0.0.3 area 0
 network 10.254.1.4 0.0.0.0 area 0
</pre>
</p>
<p>
A quick way to determine if all your interfaces are in OSPF and each assigned area is to issue the following command:</p>
<p>
<pre>
r1#show ip ospf interface brief
Interface    PID   Area            IP Address/Mask    Cost  State Nbrs F/C
Lo1          1     0               10.254.1.1/32      1     LOOP  0/0
Fa1/1        1     0               10.1.1.5/30        1     BDR   1/1
Fa1/0        1     0               10.1.1.1/30        1     BDR   1/1
r1#
</pre>
</p>
<p>Here is the output of the same command ran on the other three routers, just so you can double check your work and make sure we are in sync:</p>
<p>
<pre>
r2#show ip ospf interface brief
Interface    PID   Area            IP Address/Mask    Cost  State Nbrs F/C
Lo1          1     0               10.254.1.2/32      1     LOOP  0/0
Fa1/1        1     0               10.1.1.13/30       1     BDR   1/1
Fa1/0        1     0               10.1.1.2/30        1     DR    1/1
r2#
r3#show ip ospf interface brief
Interface    PID   Area            IP Address/Mask    Cost  State Nbrs F/C
Lo1          1     0               10.254.1.3/32      1     LOOP  0/0
Fa1/0        1     0               10.1.1.9/30        1     BDR   1/1
Fa1/1        1     0               10.1.1.6/30        1     DR    1/1
r3#
r4#show ip ospf interface brief
Interface    PID   Area            IP Address/Mask    Cost  State Nbrs F/C
Lo1          1     0               10.254.1.4/32      1     LOOP  0/0
Fa1/1        1     0               10.1.1.14/30       1     DR    1/1
Fa1/0        1     0               10.1.1.10/30       1     DR    1/1
r4#
</pre>
</p>
<p>
Once all the interfaces are configured correctly in OSPF, the routing tables will have the reach-ability to all interfaces on all routers.  At this stage, let&#8217;s verify what the routing tables should look like on all four routers.</p>
<p>
<pre>
r1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, + - replicated route

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 10 subnets, 2 masks
C        10.1.1.0/30 is directly connected, FastEthernet1/0
L        10.1.1.1/32 is directly connected, FastEthernet1/0
C        10.1.1.4/30 is directly connected, FastEthernet1/1
L        10.1.1.5/32 is directly connected, FastEthernet1/1
O        10.1.1.8/30 [110/2] via 10.1.1.6, 00:48:55, FastEthernet1/1
O        10.1.1.12/30 [110/2] via 10.1.1.2, 00:49:05, FastEthernet1/0
C        10.254.1.1/32 is directly connected, Loopback1
O        10.254.1.2/32 [110/2] via 10.1.1.2, 00:49:05, FastEthernet1/0
O        10.254.1.3/32 [110/2] via 10.1.1.6, 00:48:55, FastEthernet1/1
O        10.254.1.4/32 [110/3] via 10.1.1.6, 00:48:55, FastEthernet1/1
                       [110/3] via 10.1.1.2, 00:49:05, FastEthernet1/0
r1#

r2#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, + - replicated route

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 10 subnets, 2 masks
C        10.1.1.0/30 is directly connected, FastEthernet1/0
L        10.1.1.2/32 is directly connected, FastEthernet1/0
O        10.1.1.4/30 [110/2] via 10.1.1.1, 00:49:28, FastEthernet1/0
O        10.1.1.8/30 [110/2] via 10.1.1.14, 00:49:38, FastEthernet1/1
C        10.1.1.12/30 is directly connected, FastEthernet1/1
L        10.1.1.13/32 is directly connected, FastEthernet1/1
O        10.254.1.1/32 [110/2] via 10.1.1.1, 00:49:38, FastEthernet1/0
C        10.254.1.2/32 is directly connected, Loopback1
O        10.254.1.3/32 [110/3] via 10.1.1.14, 00:49:28, FastEthernet1/1
                       [110/3] via 10.1.1.1, 00:49:28, FastEthernet1/0
O        10.254.1.4/32 [110/2] via 10.1.1.14, 00:49:38, FastEthernet1/1
r2#

r3#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, + - replicated route

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 10 subnets, 2 masks
O        10.1.1.0/30 [110/2] via 10.1.1.5, 00:49:53, FastEthernet1/1
C        10.1.1.4/30 is directly connected, FastEthernet1/1
L        10.1.1.6/32 is directly connected, FastEthernet1/1
C        10.1.1.8/30 is directly connected, FastEthernet1/0
L        10.1.1.9/32 is directly connected, FastEthernet1/0
O        10.1.1.12/30 [110/2] via 10.1.1.10, 00:49:53, FastEthernet1/0
O        10.254.1.1/32 [110/2] via 10.1.1.5, 00:49:53, FastEthernet1/1
O        10.254.1.2/32 [110/3] via 10.1.1.10, 00:49:53, FastEthernet1/0
                       [110/3] via 10.1.1.5, 00:49:53, FastEthernet1/1
C        10.254.1.3/32 is directly connected, Loopback1
O        10.254.1.4/32 [110/2] via 10.1.1.10, 00:49:53, FastEthernet1/0
r3#

r4#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, + - replicated route

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 10 subnets, 2 masks
O        10.1.1.0/30 [110/2] via 10.1.1.13, 00:50:29, FastEthernet1/1
O        10.1.1.4/30 [110/2] via 10.1.1.9, 00:50:19, FastEthernet1/0
C        10.1.1.8/30 is directly connected, FastEthernet1/0
L        10.1.1.10/32 is directly connected, FastEthernet1/0
C        10.1.1.12/30 is directly connected, FastEthernet1/1
L        10.1.1.14/32 is directly connected, FastEthernet1/1
O        10.254.1.1/32 [110/3] via 10.1.1.13, 00:50:19, FastEthernet1/1
                       [110/3] via 10.1.1.9, 00:50:19, FastEthernet1/0
O        10.254.1.2/32 [110/2] via 10.1.1.13, 00:50:29, FastEthernet1/1
O        10.254.1.3/32 [110/2] via 10.1.1.9, 00:50:19, FastEthernet1/0
C        10.254.1.4/32 is directly connected, Loopback1
r4#
</pre>
</p>
<p><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>At this point, pinging any interface from any router should be successful.  The next step is to configure MPLS on the physical interfaces of each device.  There are a couple of things that are needed in order to do this.  First, <b>ip cef</b> needs to be running; which is a global configuration command.  Second, <b>mpls ip</b> needs to be configured on each physical interface.  Here is what the configuration will look like:</p>
<p>
<pre>
!
hostname r1
!
ip cef
!
interface FastEthernet1/0
 description r2 f1/0
 ip address 10.1.1.1 255.255.255.252
 mpls ip
!
interface FastEthernet1/1
 description r3 f1/1
 ip address 10.1.1.5 255.255.255.252
 mpls ip
</pre>
</p>
<p>
<pre>
!
hostname r2
!
ip cef
!
interface FastEthernet1/0
 description r1 f1/0
 ip address 10.1.1.2 255.255.255.252
 mpls ip
!
interface FastEthernet1/1
 description r4 f1/1
 ip address 10.1.1.13 255.255.255.252
 mpls ip
</pre>
</p>
<p>
<pre>
!
hostname r3
!
ip cef
!
interface FastEthernet1/0
 description r4 f1/0
 ip address 10.1.1.9 255.255.255.252
 mpls ip
!
interface FastEthernet1/1
 description r1 f1/1
 ip address 10.1.1.6 255.255.255.252
 mpls ip
</pre>
</p>
<p>
<pre>
!
hostname r4
!
ip cef
!
interface FastEthernet1/0
 description r3 f1/0
 ip address 10.1.1.10 255.255.255.252
 mpls ip
!
interface FastEthernet1/1
 description r2 f1/1
 ip address 10.1.1.14 255.255.255.252
 mpls ip
</pre>
</p>
<p>Once you start getting mpls configured on each device, console messages will appear alerting that LDP neighbors have been established.</p>
<p>
<pre>
r1#
*Jun  7 10:05:02.335: %LDP-5-NBRCHG: LDP Neighbor 10.254.1.2:0 (2) is UP
*Jun  7 10:03:17.791: %LDP-5-NBRCHG: LDP Neighbor 10.254.1.3:0 (1) is UP
</pre>
</p>
<p>Next thing you want to verify is that you have discovered your directly connect neighbors.  Each router will have two neighbors, since they have two direct connections to other routers.  On any of the routers, we will issue the command: <b>show mpls ldp discovery</b>.  This is to verify we are communicating via the LDP protocol to our connected neighbors.</p>
<p>
<pre>
r4(config-router)#do show mpls ldp discovery
 Local LDP Identifier:
    10.254.1.4:0
    Discovery Sources:
    Interfaces:
FastEthernet1/0 (ldp): xmit/recv
    LDP Id: 10.254.1.3:0
FastEthernet1/1 (ldp): xmit/recv
    LDP Id: 10.254.1.2:0
r4(config-router)#end
</pre>
</p>
<p>From the previous example, we examine the output of r4 to determine a few things:</p>
<p>
 &#8211; Our local LDP identifier is 10.254.1.4, this is because we have a loopback configured and LDP will use that first by default as it&#8217;s ID.<br />
 &#8211; We have ldp communications via our local interface FastEthernet1/0 from r3<br />
 &#8211; We have ldp communications via our local interface FastEthernet1/1 from r2</p>
<p>With everything looking good thus far, I would expect to have formed two neighbor relationships.  We can verify our neighbors by issuing the following command: <b>show mpls ldp neighbor</b></p>
<p>
<pre>
r4#show mpls ldp neighbor
    Peer LDP Ident: 10.254.1.2:0; Local LDP Ident 10.254.1.4:0
        TCP connection: 10.254.1.2.646 - 10.254.1.4.26889
        State: Oper; Msgs sent/rcvd: 11/11; Downstream
        Up time: 00:00:53
        LDP discovery sources:
          FastEthernet1/1, Src IP addr: 10.1.1.13
        Addresses bound to peer LDP Ident:
          10.1.1.2        10.254.1.2      10.1.1.13
    Peer LDP Ident: 10.254.1.3:0; Local LDP Ident 10.254.1.4:0
        TCP connection: 10.254.1.3.646 - 10.254.1.4.17695
        State: Oper; Msgs sent/rcvd: 11/12; Downstream
        Up time: 00:00:53
        LDP discovery sources:
          FastEthernet1/0, Src IP addr: 10.1.1.9
        Addresses bound to peer LDP Ident:
          10.1.1.9        10.254.1.3      10.1.1.6
r4#
</pre>
</p>
<p>Ok, let&#8217;s stop for a second &#8211; so that I can explain something you might run into when building an MPLS network.  Let&#8217;s say you expected to see a MPLS neighbor after everything was configured, but when you issued the <b>show mpls ldp neighbor</b> command, the expected neighbor wasn&#8217;t there.  So, you go back and issue the command: <b>show mpls ldp discovery all</b> to verify local LDP communications and the output looked something like this:</p>
<p>
<pre>
r3#show mpls ldp discovery all
 Local LDP Identifier:
    10.254.1.3:0
    Discovery Sources:
    Interfaces:
FastEthernet1/0 (ldp): xmit/recv
    LDP Id: 10.254.1.4:0; no route
FastEthernet1/1 (ldp): xmit/recv
    LDP Id: 10.254.1.1:0</pre>
</p>
<p>In this previous example, the neighbor that is not being established is the one directly connected to FastEthernet1/0.  As you can see from the output, we are sending and receiving LDP messages; but no neighbor relationship.  The LDP Id of the neighbor we want to establish is 10.254.1.4, we can&#8217;t establish it because of the following:</p>
<p>
<pre>
FastEthernet1/0 (ldp): xmit/recv
    LDP Id: 10.254.1.4:0; no route
</pre>
</p>
<p> The output shows we have no route to 10.254.1.4.  In this case, the reason we don&#8217;t have a route to it is because our underlying interior routing protocol was not configured properly.  An LDP neighbor can&#8217;t be established if it doesn&#8217;t have a route to the IP address used for the LDP ID.  So, if the LDP ID was the IP address of the locally connected interface &#8211; there wouldn&#8217;t be a problem, since we would have a route to it.  I mention this so that you can watch out for underlying routing issues when trying to establish LDP neighbor relationships.</p>
<p>The last thing we want to do here is a verbose traceroute to actually see the MPLS tags used in the path.  For this example, we will issue a traceroute from R4 in our configured network:</p>
<p>
<pre>
r4#traceroute
Protocol [ip]:
Target IP address: 10.254.1.1
Source address: 10.254.1.4
Numeric display [n]:
Timeout in seconds [3]:
Probe count [3]:
Minimum Time to Live [1]:
Maximum Time to Live [30]:
Port Number [33434]:
Loose, Strict, Record, Timestamp, Verbose[none]: V
Loose, Strict, Record, Timestamp, Verbose[V]:
Type escape sequence to abort.
Tracing the route to 10.254.1.1

  1 10.1.1.9 [MPLS: Label 18 Exp 0] 392 msec
    10.1.1.13 [MPLS: Label 18 Exp 0] 396 msec
    10.1.1.9 [MPLS: Label 18 Exp 0] 508 msec
  2 10.1.1.1 156 msec
    10.1.1.5 232 msec
    10.1.1.1 240 msec
r4#
</pre>
</p>
<p>OK, what did we discover?  First let&#8217;s look at the traceroute issued, which was to the opposite corner of the network.  Just by looking at the drawing, we can tell the traceroute has to go through one of two devices (r2 or r3) in order to get to it&#8217;s destination (r1).  We are going to issue an extended traceroute to R1&#8242;s loopback address using our loopback (of r4) as the source.  As you can see from the output of the traceroute, label id 18 was assigned to our traceroute packet before it was switched to the destination.</p>
<p>How are we doing so far?  Let&#8217;s take a break and pick it up in the third article in this series, where we will add the PE (Provider Edge) devices and begin talking about VRF&#8217;s.  If you have any questions or comments please leave them in the comment section below and I will answer asap.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/mpls-cisco/configure-a-basic-mpls-network-ii/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Configure a Basic MPLS Network</title>
		<link>http://www.xpresslearn.com/cisco/mpls-cisco/configure-a-basic-mpls-network</link>
		<comments>http://www.xpresslearn.com/cisco/mpls-cisco/configure-a-basic-mpls-network#comments</comments>
		<pubDate>Wed, 09 Jun 2010 20:26:38 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[MPLS]]></category>
		<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Label Switching]]></category>
		<category><![CDATA[LDP]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=339</guid>
		<description><![CDATA[In this article, which is part 1 of many, I would like to present how to build a basic MPLS network.  Whether you just wondered how your service providers network was built or if your considering an internal MPLS network inside your company, this information should help out.]]></description>
			<content:encoded><![CDATA[<p>In these articles, I would like to present how to build a basic MPLS network.  Whether you just wondered how your service providers network was built or if your considering an internal MPLS network inside your company, this information should help out.  As far as why you would want to build an MPLS network, I won&#8217;t go into much detail as this is more intended to show how to build and not why to build.  However, I will say the big reason to build an internal MPLS network is so that you can use MPLS based VPN&#8217;s using Virtual Route Forwarders or VRF.  That&#8217;s all I&#8217;ll mention on that, lets starting building a network.</p>
<p>I&#8217;ll be working with Cisco 7200 routers, since dynamips is being used as the platform.  We could just as easily use some of the other emulated hardware, but out of all the options available in dynamips &#8211; a 7200 is probably the closest to what you might see in the core of an MPLS network.  There are three terms that describe the type of MPLS device:</p>
<p><b>P</b> &#8211; <i>which is for Provider equipment</i><br />
<b>PE</b> &#8211; <i>which stands for Provider Edge</i><br />
<b>CE</b> &#8211; <i>which as you have probably already guessed, stands for customer edge.</i></p>
<p><span id="more-339"></span></p>
<p>As far as a provider network that you use for a company WAN solution, your equipment is obviously the CE device and the PE device is what directly connects you into the providers network.  The P devices is what you would consider the providers backbone and would never &#8216;see&#8217; or interface with that hardware.</p>
<p>In an internally built MPLS network, the premise (or remote office) routers would still be considered the CE equipment and the PE device would typically be in a company data-center serving in a traditional &#8216;distribution layer&#8217;.  The P devices in a corporate built MPLS network would be what connects multiple data-centers together.  For example, if you have two data-centers, then you would have at least one P device at each one that provides the connectivity between those two sites.  The type of hardware used for the P device would be something that supports MPLS label switching.  This could be 7200 routers, 7600 routers, a 6500 Multilayer Switch, or others.  There would be a PE device directly connected to the P devices at each of the two data-centers.  The PE device would be what represents your typical distribution layer, which could be a LAN distribution switch, or a WAN router, or both.  The CE equipment would be say a router at a remote branch office, which resides on the edge of a WAN.  The CE device could also be a firewall back in the data-center.  As you can see, there are many different configurations that one could encounter based on the needs of the company.  I have just tried to list a few of the more common scenarios, but by far is not an exhaustive list.</p>
<h3>A little about the lab</h3>
<p>As I mentioned earlier, we will be using Dynamips to provide the platform on which we will lab this exercise.  More specifically &#8211; GNS3, the all encompasing wrapper around dynamips (and now many other programs I might add) will be the tool of choice here.  At the end of this article, you will find an importable project that you can load directly into your own GNS3 installation.  However, to get the very most out of the exercise &#8211; I would recommend building the network out manually in GNS3, to get the complete feeling of the build.</p>
<h3>CompanyX network scenario</h3>
<p>CompanyX has two datacenters, that are connected by high speed point to point connections.  We have two 100Mbit connections between the datacenters, each one provided by a different commercial carrier.  Each datacenter has two &#8216;core&#8217; devices which will terminate a single 100Mbit connection.  The two core devices in each datacenter will have a local connection to each other, so that full connectivity can be maintained in the event one of the two metro connections are lost.  These &#8216;core&#8217; devices will serve as the &#8216;P&#8217; devices, which does nothing but what is called &#8216;label switching&#8217;.  By the time user traffic reaches these devices, they have labels appended to the packet headers and that is what is used to determine where to foward that traffic.  The concept here applies just like when Layer3 switching was introduced &#8211; it is much quicker to switch a packet than it is to route it.</p>
<h3>CompanyX network diagram containing P devices</h3>
<p><a href="http://www.xpresslearn.com/wp-content/uploads/MPLS.Core_.png"><img class="alignnone size-medium wp-image-347" title="CompanyX Dual Data Center Core" src="http://www.xpresslearn.com/wp-content/uploads/MPLS.Core_-300x141.png" alt="" width="300" height="141" /></a></p>
<p>The point to point connections are all /30 networks and using the 10.1.1.0 network.  All loopback addresses are assigned out of the 10.254.1.0 network as /32 or host addresses.</p>
<p>So, let&#8217;s dive in&#8230; Below you will find the basic GNS3 project information that is importable &#8211; otherwise use the diagram above to build out the network.</p>
<p>Here is the relevant configuration for each router:</p>
<p>
<pre>
hostname r1
!
interface Loopback1
 ip address 10.254.1.1 255.255.255.255
!
interface FastEthernet1/0
 description r2 f1/0
 ip address 10.1.1.1 255.255.255.252
!
interface FastEthernet1/1
 description r3 f1/1
 ip address 10.1.1.5 255.255.255.252
</pre>
</p>
<p>
<pre>
hostname r2
!
interface Loopback1
 ip address 10.254.1.2 255.255.255.255
!
interface FastEthernet1/0
 description r1 f1/0
 ip address 10.1.1.2 255.255.255.252
!
interface FastEthernet1/1
 description r4 f1/1
 ip address 10.1.1.13 255.255.255.252
</pre>
</p>
<p>
<pre>
hostname r3
!
interface Loopback1
 ip address 10.254.1.3 255.255.255.255
!
interface FastEthernet1/0
 description r4 f1/0
 ip address 10.1.1.9 255.255.255.252
!
interface FastEthernet1/1
 description r1 f1/1
 ip address 10.1.1.6 255.255.255.252
</pre>
</p>
<p>
<pre>
hostname r4
!
interface Loopback1
 ip address 10.254.1.4 255.255.255.255
!
interface FastEthernet1/0
 description r3 f1/0
 ip address 10.1.1.10 255.255.255.252
!
interface FastEthernet1/1
 description r2 f1/1
 ip address 10.1.1.14 255.255.255.252
</pre>
</p>
<p><a href='http://www.xpresslearn.com/wp-content/uploads/mpls-basic.zip.zip'>GNS3 project for basic MPLS build</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/mpls-cisco/configure-a-basic-mpls-network/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>General Cisco Security Best Practices</title>
		<link>http://www.xpresslearn.com/cisco/general/general-cisco-security-best-practices</link>
		<comments>http://www.xpresslearn.com/cisco/general/general-cisco-security-best-practices#comments</comments>
		<pubDate>Mon, 25 Jan 2010 00:57:18 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[best practices]]></category>
		<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=271</guid>
		<description><![CDATA[A list of commands for adding to your configuration template the next time you configure a Cisco device.]]></description>
			<content:encoded><![CDATA[<p>There are several general configuration items that should be configured on all Cisco devices running standard IOS.  Some layer2 only switches will ignore a few of the commands in this article that are layer3 specific.</p>
<p>The first place to start is with the service commands</p>
<pre>service password-encryption</pre>
<h3>Explanation:</h3>
<p>The router administrator will ensure passwords are not viewable when displaying the router configuration. Type 5 encryption must be used for the enable mode password.</p>
<pre>no service udp-small-servers
no service tcp-small-servers</pre>
<h3>Explanation:</h3>
<p>All IOS versions above 12.0 has small-servers disabled by default.  However, it is good to make sure these services didn&#8217;t get enabled somewhere along the way.  The commands above won&#8217;t show up in the configuration, since they are off by default.  Cisco IOS provides these &#8220;small services&#8221; which include echo, chargen, and discard.  These services are completely unnecessary to run on Cisco devices.</p>
<p><span id="more-271"></span></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<pre>no service pad</pre>
<h3>Explanation:</h3>
<p>Packet Assembler Disassembler (PAD) is an X.25 component that is seldom used.  PAD acts like a multiplexer for the terminals. If enabled, it can render the device open to attacks.</p>
<pre>service tcp-keepalives-in</pre>
<h3>Explanation:</h3>
<p>Idle logged-in telnet sessions can be susceptible to unauthorized access and hijacking attacks. By default, routers do not continually test whether a previously connected TCP endpoint is still reachable. If one end of a TCP connection idles out or terminates abnormally, the opposite end of the connection may still believe the session is available. These “orphaned” sessions use up valuable router resources and can also be hijacked by an attacker. To mitigate this risk, routers must be configured to send periodic keep-alive messages to check that the remote end of a session is still connected. If the remote device fails to respond to the keep-alive message, the sending router will clear the connection and free resources allocated to the session.</p>
<pre>no service finger</pre>
<h3>Explanation:</h3>
<p>The IOS finger service supports the UNIX finger protocol, which is used for querying a host about the users that are logged on.  This would give potential attackers a head start by providing valid usernames for the device.</p>
<pre>no boot network
no service config</pre>
<h3>Explanation:</h3>
<p>The routers can find their startup configuration either in their own NVRAM or load it over the network via TFTP or Remote Copy (rcp).  Obviously, loading in from the network is taking a security risk. If the startup configuration was intercepted by an attacker, it could be used to either gain access to the router.</p>
<p>Next, let&#8217;s take a look at the various server services available in IOS.</p>
<pre>no ip http-server
no ip ftp-server
no ip tftp-server</pre>
<h3>Explanation:</h3>
<p>The services listed above are extremely insecure and serve very little useful purpose.  An ftp-server or tftp-server might be used in environments where you have one device that has a software image on it that you want to distribute to other reachable devices.  These other devices might not have connectivity to a centralized distribution server that would host images for software upgrades, therefore making it convenient to use a router in order to get the job done.  If these services are used, it should only be in a temporary capacity and need to be disabled before logging out of the device.</p>
<pre>no ip bootp server</pre>
<h3>Explanation:</h3>
<p>Bootp is a user datagram protocol (UDP) that can be used by Cisco routers to access copies of Cisco IOS Software on another Cisco router running the Bootp service. In this scenario, one Cisco router acts as a Cisco IOS Software server that can download the software to other Cisco routers acting as Bootp clients. In reality, this service is rarely used and can allow an attacker to download a copy of a routers Cisco IOS Software.</p>
<pre>no ip source-route</pre>
<h3>Explanation:</h3>
<p>Source routing is a feature of IP, whereby, individual packets can specify routes. This feature is used in several different network attacks.  The router should always control how traffic is routed as apposed to be told to trust a path that is provided from another source.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/general/general-cisco-security-best-practices/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Network link redundancy using BVI</title>
		<link>http://www.xpresslearn.com/cisco/general/network-link-redundancy-using-bvi</link>
		<comments>http://www.xpresslearn.com/cisco/general/network-link-redundancy-using-bvi#comments</comments>
		<pubDate>Mon, 10 Nov 2008 03:53:01 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[bvi]]></category>
		<category><![CDATA[redundant link]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=222</guid>
		<description><![CDATA[Cisco devices functioning as a gateway can have link redundancy without running routing protocols.  Configuring Integrated Routing and Bridging allows two interfaces to be bridged together along with an associated virtual interface that serves as the routed interface.]]></description>
			<content:encoded><![CDATA[<p>When designing a robust network, the requirement that should make the top of the list is redundancy.  Most of the time, this is pretty easy.  When linking switches together, connect multiple links.  When connecting servers to the network, using multiple network adapters with teaming is the norm.  Connecting more than one interface on a router for redundancy is usually a little different.  Most of the time, you would take two interfaces on a router and assign an IP network to each and use a routing protocol for interacting with other connected routers for link selection.  However, there are some devices that are router types that don&#8217;t perform routing functions. </p>
<p>IOS devices functioning as some type of gateway comes to mind as a type of device that won&#8217;t route traffic &#8211; however network redundancy to the device is still desired.  In this example, a Cisco VG224 is used in a network to provide dial tone to analog devices over an IP network.  The VG224 gateway has multiple interfaces and does have the ability to run a routing protocol for reachability, but would be considered a bloated solution just to provide redundant network connections to the device.</p>
<p>In this example, we will accomplish network link redundancy by using a feature called Integrated routing and bridging or IRB for short.  In an IRB configuration, multiple physical interfaces are assigned to a common bridge group.  The two interfaces then form a bridge what communicates with a bridge virtual interface.  The device IP address then gets assigned to the virtual interface.</p>
<p><span id="more-222"></span></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>As with any bridge, loop detection is necessary to prevent problems in the network.  Spanning tree is configured on the specific bridge which will communicate with the connected access switches.  In this particular scenario, we would never want this bridge to become the root for the connected network.  Therefore it is important to specify a priority, even though it is optional, to influence the root bridge selection process.</p>
<p>To get started, specify a bridge number and spanning tree protocol used. The ieee option is the only real valid choice here, which is the 802.1D standard spanning tree.</p>
<pre>GW-VG224-01(config)#bridge 1 protocol ?
  dec          DEC protocol
  ibm          IBM protocol
  ieee         IEEE 802.1 protocol
  vlan-bridge  vlan-bridge protocol

GW-VG224-01(config)#bridge 1 protocol ieee</pre>
<p>Every bridge that participates in a spanning-tree domain goes through the root bridge election process. Specify the highest bridge priority for influencing the election process to not select this device as a root bridge:</p>
<pre>GW-VG224-01(config)#bridge 1 priority ?
  &lt;0-65535&gt;  Priority (low priority more likely to be root)

GW-VG224-01(config)#bridge 1 priority 65535</pre>
<p>This device in this example has two Fast Ethernet interfaces. Assign both of these physical interfaces to the bridge group number previously assigned:</p>
<pre>GW-VG224-01(config)#int fa0/0
GW-VG224-01(config-if)#bridge-group 1
GW-VG224-01(config-if)#int fa0/1
GW-VG224-01(config-if)#bridge-group 1</pre>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>Specify the use of irb:</p>
<pre>GW-VG224-01(config)#bridge ?
  &lt;1-255&gt;            Bridge Group number for Bridging.
  crb                Concurrent routing and bridging
  irb                Integrated routing and bridging
  mac-address-table  MAC-address table configuration commands

GW-VG224-01(config)#bridge irb</pre>
<p>Enter interface configuration mode for the virtual interface that is created. This interface is where the layer3 configuration goes:</p>
<pre>GW-VG224-01(config)#int bvI ?
  &lt;1-255&gt;  BVI interface number

GW-VG224-01(config)#int bvI 1
GW-VG224-01(config-if)#ip address 10.32.16.20 255.255.255.0</pre>
<p>Traffic will not be forwarded until the bridge is configured to route the IP traffic through this virtual bridge.</p>
<pre>GW-VG224-01(config)#bridge 1 route ?
  ip  IP
GW-VG224-01(config)#bridge 1 route ip</pre>
<p>Lastly, take the physical interfaces out of shutdown mode:</p>
<pre>GW-VG224-01(config-if)#int fa0/0
GW-VG224-01(config-if)#no shut
GW-VG224-01(config-if)#int fa0/1
GW-VG224-01(config-if)#no shut</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/general/network-link-redundancy-using-bvi/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Upgrade to a modular IOS image</title>
		<link>http://www.xpresslearn.com/cisco/switching/upgrade-to-a-modular-ios-image</link>
		<comments>http://www.xpresslearn.com/cisco/switching/upgrade-to-a-modular-ios-image#comments</comments>
		<pubDate>Thu, 16 Oct 2008 02:52:55 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[Switching]]></category>
		<category><![CDATA[6500]]></category>
		<category><![CDATA[IOS]]></category>
		<category><![CDATA[Modular]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=200</guid>
		<description><![CDATA[Cisco IOS Software Modularity is available for the two newest Supervisor modules, the Sup720 and Sup32,  which go into the Cisco 6500 series platform.  Basically, by using the modular IOS, the switch runs more efficiently.  This is accomplished by splitting up major components inside the IOS into separate subsystems, which will run in different processes. [...]]]></description>
			<content:encoded><![CDATA[<p>Cisco IOS Software Modularity is available for the two newest Supervisor modules, the Sup720 and Sup32,  which go into the Cisco 6500 series platform.  Basically, by using the modular IOS, the switch runs more efficiently.  This is accomplished by splitting up major components inside the IOS into separate subsystems, which will run in different processes.  The modularity also allows the patching of portions of the IOS, without having to install an entirely new IOS.  Think about this: How many times have you installed a new IOS image to fix a specific bug, but the new software caused a problem in another area that was previously not broken?  Now, fixing issues by only patching the part of the software with a problem helps insure the rest of the device&#8217;s operation will continue to operate as it did in the past.</p>
<p>A new feature that comes along with the modular image is the inclusion of Cisco Embedded Event Manager (EEM).  This feature allows the EEM process to &#8216;catch&#8217; a defined event and then spawn an action from that raised event.  For example, the device can generate and send an email when the CPU goes over a certain percentage for a period that is longer than a defined threshold.  The engine behind this functionality is controlled using the Python scripting language.  Using Python to write these embedded event handlers provides some powerful capabilities at your fingertips.<br />
<span id="more-200"></span></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>This article wasn&#8217;t really intended to help you decide on using the IOS modularity option, but to explain the upgrade/conversion process.  The first thing to do is obtain the proper image from CCO.  The modular version has the same feature sets and versions available just like the native IOS versions do.  Just pick the right modular image based on your hardware and services needed just like you would any other time.</p>
<p>Once you have downloaded the image, upload it to storage that is available on the (primary) supervisor.  Before the &#8216;installation&#8217; of the modular IOS, the supervisor has to boot from it first, like it would any other image.  In fact, the switch can load the modular IOS .bin file and run just like it was the non-modular version.  However, this would defeat the purpose, since patching is not available until the installation has been performed and the system rebooted.</p>
<p>Put a boot statement in the configuration pointing it to the .bin file that was just uploaded to storage and reload the switch.  Once the switch is back up running on the new image here is where it starts to get fun&#8230;</p>
<p>Let&#8217;s look at the output of the <strong>show version</strong> command after the switch has booted the new IOS image:</p>
<pre>6500switch#sh version
Cisco IOS Software, s72033_rp Software (s72033_rp-ADVIPSERVICESK9_WAN-VM),
Version 12.2(33)SXH3a, RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2008 by Cisco Systems, Inc.
Compiled Wed 24-Sep-08 14:37 by prod_rel_team

ROM: System Bootstrap, Version 12.2(17r)SX5, RELEASE SOFTWARE (fc1)

6500switch uptime is 14 hours, 53 minutes
Uptime for this control processor is 14 hours, 52 minutes
Time since 6500switch switched to active is 14 hours, 52 minutes
System returned to ROM by reload at 23:22:24 CDT Tue Oct 14 2008
 (SP by reload)
System image file is "disk0:s72033-advipservicesk9_wan-vz.122-33.SXH3a.bin"

cisco WS-C6506-E (R7000) processor (revision 1.1) with
516096K/8192K bytes of memory.
SR71000 CPU at 600Mhz, Implementation 1284, Rev 1.2, 512KB L2 Cache
Last reset from s/w reset
1 Virtual Ethernet interface
52 Gigabit Ethernet interfaces
1917K bytes of non-volatile configuration memory.

65536K bytes of Flash internal SIMM (Sector size 512K).
Configuration register is 0x2102

Patching is not available since the system is not running from an
installed image. To install please use the "install file" command</pre>
<p>Take a look at the last couple of lines of the output. This output is telling you to run the &#8216;install file&#8217; command in order to install the image. The installation procedure creates a directory structure on the file system specified in the install command. In this example, the image is running from flash installed in slot0:, which is known to the switch as disk0:. We are going to install onto the sup-bootdisk0: flash, which is an compact flash module installed internally with a <a href="http://www.cisco.com/en/US/docs/switches/lan/catalyst6500/hardware/Config_Notes/78_17277.html">compact flash adapter</a> that replaces the SP bootflash on the supervisor. Cisco recommends the modular installation use internal storage, because it is too easy to eject the flash from the slots on the front of the supervisor &#8211; which would cause the switch to crash.<br />
<!--more--></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>The command to start the process will be: <strong>install file disk0:s72033-advipservicesk9_wan-vz.122-33.SXH3a.bin sup-bootdisk0:/sys</strong> . The syntax is basically the source image to use then the destination. Notice the /sys at the end of the destination, which is a required argument and is called the search root. The search root is basically just a top level directory and valid entries are: sys|newsys|oldsys .  Below is a normal output during the installation:</p>
<pre>6500switch#install file disk0:s72033-advipservicesk
9_wan-vz.122-33.SXH3a.bin sup-bootdisk:/sys
Source filename [s72033-advipservicesk9_wan-vz.122-33.SXH3a.bin]?
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Verifying checksums of extracted files

Verifying installation compatibility

Finalizing installation ...
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Computing and verifying file checksums
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Writing installation meta-data.  Please wait ...

NOTE: The newly added base image is not yet active.
      To activate the new base image, perform an 'install bind' in
      config mode followed by a 'reload'.

[DONE]

6500switch#</pre>
<p>The last thing you see is a note on how to activate the new base image.  The correct command in this example is: 6509switch(config)#<strong>install bind sup-bootdisk:/sys</strong> .  Notice this command is done from configuration mode.  This command basically just adds a boot statement in the switch configuration pointing to the new modular image.  Here is the output from the install bind command:</p>
<pre>6500switch(config)#install bind sup-bootdisk:/sys
WARNING: This system is running in a redundant mode.  However, the specified
search root on the Standby does not contain installed software, or is unavailable.
Unless the proper software is installed on the Standby,
it will not boot from this binding</pre>
<p>The message we received above was due to the fact the example system was running dual supervisor modules.  If you have a single supervisor, this message will not display.  In order to get the installation onto the redundant supervisor, the process is a little simpler.  There is a copy command that will copy the existing installation on sup-bootflash0:/sys to the redundant supervisor&#8217;s file system.  The following is all that is required to insure the secondary supervisor can boot successfully:</p>
<pre>6500switch#install copy sup-bootdisk:/sys slavesup-bootdisk:/sys
Copying installed software at sup-bootdisk:/sys to slavesup-bootdisk:/sys
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
[DONE]</pre>
<p>A look at the running configuration shows the following:</p>
<pre>6500switch#show run</pre>
<pre>boot-start-marker
boot system flash disk0:s72033-advipservicesk9_wan-vz.122-33.SXH3a.bin
boot system flash sup-bootdisk:
boot system sup-bootdisk:/sys/s72033/base/s72033-advipservicesk9_wan-vm
boot-end-marker</pre>
<p>As you can see, the install bind command will not remove any of the previous boot statements.  In all the upgrades I have performed so far, I have went ahead and removed all the old boot statements, just to make sure the supervisor boots correctly.</p>
<pre>6500switch#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
6500switch(config)#no boot system flash disk0:s72033-advipservicesk9_wan-vz.122-33.SXH3a.bin
6500switch(config)#no boot system flash sup-bootdisk:
6500switch(config)#end
6500switch#wr
Building configuration...
[OK]
6500switch#sh boot
BOOT variable = sup-bootdisk:/sys/s72033/base/s72033-advipservicesk9_wan-vm,12;
CONFIG_FILE variable =
BOOTLDR variable =
Configuration register is 0x2102

Standby is up
Standby has 524288K/8192K bytes of memory.

Standby BOOT variable = sup-bootdisk:/sys/s72033/base/s72033-advipservicesk9_wan-vm,12;
Standby CONFIG_FILE variable =
Standby BOOTLDR variable =
Standby Configuration register is 0x2102</pre>
<p>The last thing to do is reload the switch:</p>
<pre>6500switch#reload
Proceed with reload? [confirm]</pre>
<p>Once the switch is back up, the output of show version now looks like:</p>
<p><!--more--></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<pre>6500switch# sh ver
Cisco IOS Software, s72033_rp Software (s72033_rp-ADVIPSERVICESK9_WAN-VM),
 Version 12.2(33)SXH3a, RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2008 by Cisco Systems, Inc.
Compiled Wed 24-Sep-08 14:37 by prod_rel_team

ROM: System Bootstrap, Version 12.2(17r)SX5, RELEASE SOFTWARE (fc1)

 6500switch uptime is 8 minutes
Uptime for this control processor is 7 minutes
Time since 6500switch switched to active is 7 minutes
System returned to ROM by reload at 15:07:48 CDT Wed Oct 15 2008 (SP by reload)
System image file is "sup-bootdisk:/sys/s72033/base/s72033-advipservicesk9_wan-vm"

cisco WS-C6506-E (R7000) processor (revision 1.1) with 516096K/8192K bytes of memory.
SR71000 CPU at 600Mhz, Implementation 1284, Rev 1.2, 512KB L2 Cache
Last reset from s/w reset
1 Virtual Ethernet interface
52 Gigabit Ethernet interfaces
1917K bytes of non-volatile configuration memory.

65536K bytes of Flash internal SIMM (Sector size 512K).
Configuration register is 0x2102

System is currently running from installed software
For further information use "show install running"</pre>
<p>To look at the actual software versions along with any patch information, issue the <strong>show install running</strong> command:</p>
<pre>6500switch#show install running

B/P C State     Filename
--- - --------  --------

Software running on card installed at location s72033_rp - Slot 6 :
 B    Active    slavesup-bootdisk:/sys/s72033_rp/base/DRACO2_MP

Software running on card installed at location s72033 - Slot 5 :
 B    Active    sup-bootdisk:/sys/s72033/base/s72033-advipservicesk9_wan-vm -
Version 12.2(33)SXH3a

Software running on card installed at location s72033_rp - Slot 5 :
 B    Active    sup-bootdisk:/sys/s72033_rp/base/DRACO2_MP

Software running on card installed at location c2_lc - Slot 1 :
 B    Active    sup-bootdisk:/sys/c2_lc/base/C2LC

Software running on card installed at location s72033 - Slot 6 :
 B    Active    slavesup-bootdisk:/sys/s72033/base/s72033-advipservicesk9_wan-vm -
Version 12.2(33)SXH3a

LEGEND:
-------:
B/P/MP - (B)ase image, (P)atch, or (M)aintenance (P)ack
'C' - (C)ommitted
Pruned - This file has been pruned from the system
Active - This file is active in the system
PendInst - This file is set to be made available to run on the
   system after next activation.
PendRoll - This file is set to be rolled back after next activation.
InstPRel - This file will run on the system after next reload
RollPRel - This file will be removed from the system after next reload
RPRPndIn - This file is both rolled back pending a reload, and pending
   installation.  On reload, this file will not run and will move to
   PendInst state.  If 'install activate' is done before reload, pending
   removal and install cancel each other and file simply remains active
IPRPndRo - This file is both installed pending a reload, and pending rollback.
   If the card reloads, it will be active on the system pending a rollback
   If 'install activate' is done before a reload, the pending install and
   removal with cancel each other and the file will simply be removed
Occluded - This file has been occluded from the system,
   a newer version of itself has superceded it.

6500switch#</pre>
<p>All things considered, this is a pretty easy upgrade &#8211; just take your time and make sure each step is followed carefully. I would recommend allocating 1.5 hours for the first upgrade performed. Once you&#8217;re familiar with the process, it can be done in half that time and even quicker if the image is transferred to a filesystem on the switch prior to performing the upgrade.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/switching/upgrade-to-a-modular-ios-image/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Automate Cisco commands from Windows</title>
		<link>http://www.xpresslearn.com/cisco/general/automate-cisco-commands-from-windows</link>
		<comments>http://www.xpresslearn.com/cisco/general/automate-cisco-commands-from-windows#comments</comments>
		<pubDate>Tue, 07 Oct 2008 01:40:54 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[automate]]></category>
		<category><![CDATA[Cisco]]></category>
		<category><![CDATA[plink]]></category>
		<category><![CDATA[putty]]></category>
		<category><![CDATA[scripting]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=150</guid>
		<description><![CDATA[Use plink to automate sending commands and receiving information from your telnet and ssh sessions.  This article will show you how to use plink to gather the configuration from an IOS device.]]></description>
			<content:encoded><![CDATA[<p>In the previous article, <a title="Permanent Link to Running commands on a Cisco device from the Windows command line" rel="bookmark" href="http://www.xpresslearn.com/cisco/running-commands-on-a-cisco-device-from-the-windows-command-line">Running commands on a Cisco device from the Windows command line</a> , I wrote on how to run commands from the Windows command line against a Cisco device.  The article was based on using the Unix utility rsh aka Remote Shell.  The biggest downfall of using rsh is the security issues around the protocol.  How about another method of doing the same thing, but with using a more secure process?</p>
<p>Putty has a sister program that is called plink.  Like putty, plink is a standalone executable that is capable of accessing remote devices using telnet or ssh.  Plink is basically used in place of putty when you want the input/output of the program to use STDIN/STDOUT.  So, for example you can open a command prompt, invoke plink and connect to a device.  The interaction with the session will look just as if it would when using the telnet.exe from the XP/Vista command line.  One of the features of plink is that it can share the saved sessions created in Putty.  By default, putty will use the Windows registry to store saved connection information.  However, the configuration can be changed to store the sessions in the local file system.</p>
<p>In this initial example, lets configure a router to accept an incoming ssh connection with a locally defined username/password combination.  The basic IOS configuration to accomplish this task will look like the following:<br />
<span id="more-150"></span></p>
<p><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<pre>
R1(config)#int fa0/0
R1(config-if)#ip address 10.1.100.1 255.255.255.0

<strong>! Define the hostname on the router - required for enabling ssh</strong>
Router(config)#hostname R1

<strong>! Define the domain name on the router - required for enabling ssh</strong>
R1(config)#ip domain-name xpresslearn.com

<strong>! Generate encryption keys for use with ssh</strong>
R1(config)#crypto key generate rsa general-keys
The name for the keys will be: R1.xpresslearn.com
Choose the size of the key modulus in the range of 360 to 2048 for your
General Purpose Keys. Choosing a key modulus greater than 512 may take
a few minutes.
How many bits in the modulus [512]:
% Generating 512 bit RSA keys, keys will be non-exportable...[OK]

<strong>! Use the latest version of ssh</strong>
R1(config)#ip ssh version 2

<strong>! Locally defined username on the router</strong>
R1(config)#username xpresslearn privilege 15 secret pa55w0rd

<strong>! Enable aaa</strong>
R1(config)#aaa new-model

<strong>! Set all logins by default to use the local username entries</strong>
R1(config)#aaa authentication login default local

<strong>! Use the priviledge level defined in the local username statement</strong>
R1(config)#aaa authorization exec default local</pre>
<p>Now, from the command line, let&#8217;s use the plink.exe program to show the interfaces of the Cisco device. But first, lets take a look at the options available from the plink executable:</p>
<div id="attachment_161" class="wp-caption aligncenter" style="width: 457px"><a href="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-options.gif"><img class="size-full wp-image-161" title="Plink command options" src="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-options.gif" alt="Command line options for plink.exe" width="447" height="481" /></a><p class="wp-caption-text">Command line options for plink.exe</p></div>
<p>As you can see, one of the options is a -m to run remote commands from a file.  In order to automatically run commands without interaction, the commands you want to run need to be inserted into a text file.</p>
<div id="attachment_163" class="wp-caption aligncenter" style="width: 355px"><a href="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-commands.gif"><img class="size-full wp-image-163" title="Automating commands in Cisco IOS for use with Plink" src="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-commands.gif" alt="Text file to use with plink.exe" width="345" height="326" /></a><p class="wp-caption-text">Text file to use with plink.exe</p></div>
<p>Now, run the program with the proper command line options.  Which in the following example is:</p>
<p>- Use ssh to connect<br />
- Connect with the username xpresslearn<br />
- The IP address of the device we are connecting is 10.1.100.1<br />
- use the password pa55w0rd<br />
- run the commands contained in the file called plink-commands.txt that resides in the current directory.</p>
<div id="attachment_166" class="wp-caption aligncenter" style="width: 510px"><a href="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-batch.gif"><img class="size-full wp-image-166" title="Running plink.exe in batch mode" src="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-batch.gif" alt="Running plink.exe in batch mode" width="500" height="195" /></a><p class="wp-caption-text">Running plink.exe in batch mode</p></div>
<p>As you can see, the output from the command is displayed as standard program output.  This output can just as easily be piped to a text file.  Next, let&#8217;s use this method to back up the configuration of the router.  First, we will put the proper commands in the text file for batch processing.</p>
<div id="attachment_168" class="wp-caption aligncenter" style="width: 358px"><a href="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-commands2.gif"><img class="size-full wp-image-168" title="Plink commands for configuration backup" src="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-commands2.gif" alt="Backup cisco configuration via plink.exe" width="348" height="330" /></a><p class="wp-caption-text">Backup cisco configuration via plink.exe</p></div>
<p>Now, run plink.exe with the same command line options and add the pipe to end:</p>
<div id="attachment_169" class="wp-caption aligncenter" style="width: 509px"><a href="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-batch2.gif"><img class="size-full wp-image-169" title="Router backup via Plink" src="http://www.xpresslearn.com/wp-content/uploads/2008/09/plink-batch2.gif" alt="Router backup using plink.exe" width="499" height="553" /></a><p class="wp-caption-text">Router backup using plink.exe</p></div>
<p>So we ran plink with the commands in the text file and piped them to a file called R1.txt.  In the above screen shot, you can see where we view the text file after the program has executed.  The text file contains the complete configuration of the device, which was displayed using the show run command.  FYI: the term length 0 command is used to prevent paging when showing the running configuration.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/general/automate-cisco-commands-from-windows/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Upgrading Staging Hardware</title>
		<link>http://www.xpresslearn.com/cisco/general/upgrading-staging-hardware</link>
		<comments>http://www.xpresslearn.com/cisco/general/upgrading-staging-hardware#comments</comments>
		<pubDate>Thu, 04 Sep 2008 16:27:14 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[tftp server]]></category>
		<category><![CDATA[upgrade IOS]]></category>
		<category><![CDATA[usb drive]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=135</guid>
		<description><![CDATA[This article explains how to use a router and USB flash drive instead of a PC in staging areas where you need to upgrade software on other network devices before deployment.]]></description>
			<content:encoded><![CDATA[<p>With the addition of USB ports on the newer Cisco routers, it has made it much easier to load IOS upgrades in staging areas &#8211; where equipment is being configured prior to being installed.  In the past, having a PC either directly connected to the staging equipment or plugged into the same network as the device was the way to upgrade the IOS using tftp.  Sometimes that staging area is a cubicle and causes a hassle if there isn&#8217;t a dedicated PC available for upgrades, because it means unhooking your primary pc from the network (which is the same pc needed to download all the software upgrades from cisco.com).</p>
<p>I have one USB thumb drive that is used strictly for Cisco gear.  First I started with a 256Mb freebie that come from a vendor and inserted it into a 2811 router that was up and running.  The flash was then formatted from the router to insure there would be no issues with the filesystem when using it in future Cisco devices.</p>
<pre>Router#format usbflash1:
Format operation may take a while. Continue? [confirm]
Format operation will destroy all data in "usbflash1:".  Continue? [confirm]
Format: Drive communication &amp; 1st Sector Write OK...

Format: All system sectors written. OK...

Format: Total data sectors in formatted partition: 511435
Format: Total data bytes in formatted partition: 261854720
Format: Operation completed successfully.

Format of usbflash1 complete
Router#</pre>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p><span id="more-135"></span><br />
Next the thumb drive was inserted into the pc and the IOS image copied to it.  In this scenario, a Catalyst 3560 switch is being upgraded which is connected directly to a 2811 router that will serve as the tftp server.</p>
<p>The router&#8217;s FastEthernet0/0 interface is connected to the switch, which is in the same vlan as the management interface (Vlan1) of the switch.</p>
<pre>Router#show ip int brief | exc unassigned
Interface               IP-Address      OK? Method  Status     Protocol
FastEthernet0/0         10.1.2.1        YES manual  up         up
Serial0/0/0             192.168.40.214  YES manual  down       down
Loopback1               10.254.1.18     YES manual  up         up
Router#</pre>
<p>Connectivity to the access switch is then verified using ping:</p>
<pre>Router#ping 10.1.2.5

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.1.2.5, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/4 ms
Router#</pre>
<p>The thumb drive is then put back in the router and the contents of the usb drive is verified.</p>
<pre>Router#dir usbflash1:
Directory of usbflash1:/

    1  -rw-     8811199  Sep 04 2008 10:18:38 +00:00  c3560-ipbasek9-mz.122-46.SE.bin

261853184 bytes total (252272640 bytes free)
Router#</pre>
<p><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
<br />
Next, configure the tftp server on the router:</p>
<pre>Router(config)#tftp-server usbflash1:c3560-ipbasek9-mz.122-46.SE.bin</pre>
<p>From the switch console, we should now be able to perform an IOS upgrade using the connected router as the tftp source:</p>
<pre>Switch#copy tftp://10.1.2.1/c3560-ipbasek9-mz.122-46.SE.bin flash:
Destination filename [c3560-ipbasek9-mz.122-46.SE.bin]?
Accessing tftp://10.1.2.1/c3560-ipbasek9-mz.122-46.SE.bin...
Loading c3560-ipbasek9-mz.122-46.SE.bin from 10.1.2.1 (via Vlan1): !!!!!!!!!!!!!!!&lt;truncated&gt;
[OK - 8811199 bytes]

8811199 bytes copied in 151.591 secs (58125 bytes/sec)
Switch#</pre>
<p>Using the router as a tftp server along with the removable storage proves to be a convenient method for upgrading other IOS devices in situations where a spare pc is not readily available.  Don&#8217;t forget to clean up the router after your finished by removing the tftp-server command.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/general/upgrading-staging-hardware/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Etherchannel Router Interfaces</title>
		<link>http://www.xpresslearn.com/cisco/general/etherchannel-router-interfaces</link>
		<comments>http://www.xpresslearn.com/cisco/general/etherchannel-router-interfaces#comments</comments>
		<pubDate>Fri, 27 Jun 2008 03:54:18 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Etherchannel]]></category>
		<category><![CDATA[Port Channel]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=117</guid>
		<description><![CDATA[To increase bandwidth on a given Cisco network device, typically etherchannel technology is used to accomplish this task. In most scenarios, etherchannel is used between two switches to provide additional bandwidth to the uplink connections. In less common instances, Network cards in servers that have drivers supporting the proprietary technology will be configured for etherchannel. [...]]]></description>
			<content:encoded><![CDATA[<p>To increase bandwidth on a given Cisco network device, typically etherchannel technology is used to accomplish this task. In most scenarios, etherchannel is used between two switches to provide additional bandwidth to the uplink connections. In less common instances, Network cards in servers that have drivers supporting the proprietary technology will be configured for etherchannel. The requirement is usually to increase bandwidth available on a link between two devices.</p>
<p>Etherchannel has not been used nearly as much for such requirements as redundancy, because there is a limitation on all the interfaces that belongs to an etherchannel group, each interface has to be plugged into the same switch. The stackable 3750 switches have allowed a little more redundant ability, in the sense that you can have two switches stacked via the stackwise ports in the back of the switch, which basically extends the backplane. By doing this, you are allowed to have an Etherchannel interface plugged into two different switches (as long as they are stacked). Let&#8217;s take a look at an example diagram for clarification:</p>
<p style="text-align: center;"><img class="aligncenter" title="Router with two Interfaces in Etherchannel configuration" src="http://www.xpresslearn.com/wp-content/uploads/2008/06/routeretherchannel.gif" alt="" /></p>
<p>Let&#8217;s take a look at the router configuration to accomplish the task of adding bandwidth.</p>
<p><span id="more-117"></span></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<pre>interface Port-channel1
ip address 192.168.50.1 255.255.255.0
!
interface FastEthernet0/0
duplex full
speed 100
channel-group 1
!
interface FastEthernet0/1
duplex full
speed 100
channel-group 1</pre>
<p>Next, the switch configuration:</p>
<pre>interface Port-Channel1
switchport
switchport access vlan 10
switchport mode access
!
interface FastEthernet0/1
switchport
switchport access vlan 10
switchport mode access
channel-group 1 mode on
!
interface FastEthernet0/2
switchport
switchport access vlan 10
switchport mode access
channel-group 1 mode on</pre>
<p>This example is configured for etherchannel without also being configured as a trunk (which means the aggregated interfaces are in access mode).</p>
<p>Another common configuration that goes along with etherchannel interfaces is Vlan Trunking. The term &#8216;trunking&#8217; is often misused when referring to etherchannel use. When discussing a trunk, the meaning is an interface that carries multiple vlans across it. The terms trunking and etherchannel do not automatically go with each other.</p>
<p>The following example shows the same Etherchannel configuration as above, only this time the interfaces will also be configured as trunks in order to carry multiple vlans across the link(in this example &#8211; vlan 2,3,4,5,6, and 999).</p>
<p>First, the router configuration:</p>
<pre>interface Port-channel1
 no ip address
!
interface Port-channel1.2
 encapsulation dot1Q 2
 ip address 192.168.2.1 255.255.255.0
!
interface Port-channel1.3
 encapsulation dot1Q 3
 ip address 192.168.3.1 255.255.255.0
!
interface Port-channel1.4
 encapsulation dot1Q 4
 ip address 192.168.4.1 255.255.255.0
!
interface Port-channel1.5
 encapsulation dot1Q 5
 ip address 192.168.5.1 255.255.255.0
!
interface Port-channel1.6
 encapsulation dot1Q 6
 ip address 192.168.6.1 255.255.255.0
!
interface Port-channel1.999
 encapsulation dot1Q 999 native
!
interface FastEthernet0/0
duplex full
speed 100
channel-group 1
!
interface FastEthernet0/1
duplex full
speed 100
channel-group 1</pre>
<p>Here is the switch configuration:</p>
<pre>interface Port-Channel1
switchport
switchport trunk allowed vlan 2,3,4,5,6,999
switchport mode trunk
!
interface FastEthernet0/1
switchport
switchport trunk allowed vlan 2,3,4,5,6,999
switchport mode trunk
channel-group 1 mode on
!
interface FastEthernet0/2
switchport
switchport trunk allowed vlan 2,3,4,5,6,999
switchport mode trunk
channel-group 1 mode on</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/general/etherchannel-router-interfaces/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Policy Based Routing</title>
		<link>http://www.xpresslearn.com/cisco/routing/policy-based-routing</link>
		<comments>http://www.xpresslearn.com/cisco/routing/policy-based-routing#comments</comments>
		<pubDate>Fri, 27 Jun 2008 00:00:27 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[Routing]]></category>
		<category><![CDATA[Policy based routing]]></category>
		<category><![CDATA[route-map]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=119</guid>
		<description><![CDATA[There are scenarios where it would be desirable for a host or group of hosts to take a different route through the network than what is considered the normal path.  Consider this as creating a detour of sorts, forcing an alternate route to the destination.  This can be accomplished on a selective basis, by picking [...]]]></description>
			<content:encoded><![CDATA[<p>There are scenarios where it would be desirable for a host or group of hosts to take a different route through the network than what is considered the normal path.  Consider this as creating a detour of sorts, forcing an alternate route to the destination.  This can be accomplished on a selective basis, by picking out certain hosts to apply the detour to without changing the course of other hosts on the same network.</p>
<p>The solution in this scenario is to use something called policy based routing:</p>
<p><span id="more-119"></span></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>Policy-based routing provides a tool for forwarding and routing data packets based on policies defined by network administrators. In effect, it is a way to have the policy override routing protocol decisions. Policy-based routing includes a mechanism for selectively applying policies based on access list, packet size or other criteria. The actions taken can include routing  packets on user-defined routes, setting the precedence, type of service bits, etc.</p>
<p>Consider the following diagram:</p>
<p style="text-align: center;"><a href="http://www.xpresslearn.com/wp-content/uploads/2008/06/policyrouting.jpg"><img class="size-full wp-image-122 aligncenter" title="Policy Based Networking Example" src="http://www.xpresslearn.com/wp-content/uploads/2008/06/policyrouting.jpg" alt="Diagram used to illustrate Policy Based Routing" width="500" height="118" /></a></p>
<p>Host 1 and 2 both have a default gateway of the defaultRouter, which has the address of 192.168.1.1.  The default route/next hop address in defaultRouter for all traffic is 192.168.2.1, which is named LanRouter.  When Host1 pings Host3 the full path looks like:</p>
<p>Host1 &#8211;&gt; defaultRouter &#8211;&gt; LanRouter &#8211;&gt; Host3</p>
<pre>Host1#<strong>traceroute 192.168.3.100</strong>

Type escape sequence to abort.
Tracing the route to 192.168.3.100

  1 192.168.1.1 152 msec 168 msec 144 msec
  2 192.168.2.1 288 msec 256 msec 172 msec
  3 192.168.3.100 264 msec 260 msec 255 msec
Host1#</pre>
<p>Let&#8217;s say we want Host1 to take an alternate path in the network, but leave Host2 alone and allow it to continue through the original route.  A policy route will be configured on defaultRouter to look for the source address of Host1 and re-route that traffic over altLanRouter.  Any traffic sourced from Host2 will remain going through the original path via LanRouter.</p>
<p>First thing to configure is the access list that will be used to match the desired source address.</p>
<pre>defaultRouter(config)#<strong>ip access-list extended hosts-to-redirect</strong>
defaultRouter(config-ext-nacl)#<strong>permit ip</strong> ?
A.B.C.D  Source address
any      Any source host
host     A single source host

defaultRouter(config-ext-nacl)#<strong>permit ip 192.168.1.100</strong> ?
A.B.C.D  Source wildcard bits

defaultRouter(config-ext-nacl)#<strong>permit ip 192.168.1.100 0.0.0.0</strong> ?
A.B.C.D  Destination address
any      Any destination host
host     A single destination host

defaultRouter(config-ext-nacl)#<strong>permit ip 192.168.1.100 0.0.0.0 any</strong></pre>
<p>Next, create the route map and configure what to use for matching traffic, which is the access list that was previously created.  Also, configure what action to take on the traffic that is matched.</p>
<pre>defaultRouter(config-route-map)#<strong>match ip address</strong> ?
  &lt;1-199&gt;      IP access-list number
  &lt;1300-2699&gt;  IP access-list number (expanded range)
  WORD         IP access-list name
  prefix-list  Match entries of prefix-lists

defaultRouter(config-route-map)#<strong>match ip address hosts-to-redirect</strong>
defaultRouter(config-route-map)#<strong>set</strong> ?
  as-path           Prepend string for a BGP AS-path attribute
  automatic-tag     Automatically compute TAG value
  clns              OSI summary address
  comm-list         set BGP community list (for deletion)
  community         BGP community attribute
  dampening         Set BGP route flap dampening parameters
  default           Set default information
  extcommunity      BGP extended community attribute
  interface         Output interface
  ip                IP specific information
  ipv6              IPv6 specific information
  level             Where to import route
  local-preference  BGP local preference path attribute
  metric            Metric value for destination routing protocol
  metric-type       Type of metric for destination routing protocol
  mpls-label        Set MPLS label for prefix
  nlri              BGP NLRI type
  origin            BGP origin code
  tag               Tag value for destination routing protocol
  traffic-index     BGP traffic classification number for accounting
  vrf               Define VRF name
  weight            BGP weight for routing table
defaultRouter(config-route-map)#<strong>set ip</strong> ?
  address     Specify IP address
  default     Set default information
  df          Set DF bit
  next-hop    Next hop address
  precedence  Set precedence field
  qos-group   Set QOS Group ID
  tos         Set type of service field
defaultRouter(config-route-map)#<strong>set ip next-hop 192.168.2.2</strong></pre>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>Once the route map is configured the only thing left is to apply it to the interface where the traffic comes into the router, which is FastEthernet1/0.</p>
<pre>defaultRouter(config)#<strong>int fa1/0</strong>
defaultRouter(config-if)#<strong>ip policy</strong> ?
  route-map  Policy route map

defaultRouter(config-if)#<strong>ip policy route-map</strong> ?
  WORD  Route map name

defaultRouter(config-if)#<strong>ip policy route-map altRouterRedirect</strong></pre>
<p>Now let&#8217;s take a look at the path Host1 takes to connect to Host3:</p>
<pre>Host1#<strong>traceroute 192.168.3.100</strong>

Type escape sequence to abort.
Tracing the route to 192.168.3.100

  1 192.168.1.1 112 msec 168 msec 72 msec
  2 192.168.2.2 192 msec 312 msec 336 msec
  3 192.168.3.100 288 msec 288 msec 288 msec
Host1#</pre>
<p>Now, verify that host 2 still takes the original path via LanRouter:</p>
<pre>Host2#<strong>traceroute 192.168.3.100</strong>

Type escape sequence to abort.
Tracing the route to 192.168.3.100

  1 192.168.1.1 140 msec 144 msec 144 msec
  2 192.168.2.1 192 msec 212 msec 172 msec
  3 192.168.3.100 432 msec 384 msec 360 msec
Host2#</pre>
<p>This configuration has successfully changed the path in the network of Host 1 and left the traffic sourced from Host 2 untouched.  Keep in mind that the reply traffic from R3 is going back across defaultRouter in both scenarios, this is because Host3 has a default gateway of 192.168.3.1, which is assigned to defaultRouter.  If we wanted the reply traffic from Host 3 destined to host 1 sent via altLanRouter, a policy map would need to be applied to match the destination ip address of Host 1.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/routing/policy-based-routing/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Spanning Tree Root Bridge</title>
		<link>http://www.xpresslearn.com/cisco/switching/spanning-tree-root-bridge</link>
		<comments>http://www.xpresslearn.com/cisco/switching/spanning-tree-root-bridge#comments</comments>
		<pubDate>Sun, 25 May 2008 02:11:23 +0000</pubDate>
		<dc:creator>Scott Pilkinton</dc:creator>
				<category><![CDATA[Switching]]></category>
		<category><![CDATA[802.1D]]></category>
		<category><![CDATA[root bridge]]></category>
		<category><![CDATA[Spanning Tree]]></category>

		<guid isPermaLink="false">http://www.xpresslearn.com/?p=113</guid>
		<description><![CDATA[The most important element to spanning tree is the root bridge placement.  If no other element of spanning tree is manually configured on your network, the root bridge should definitely be set.]]></description>
			<content:encoded><![CDATA[<p>Configuring spanning tree correctly is very important on any local area network.  The most important element to spanning tree is the root bridge placement.  By default, spanning-tree which is running on all switches in the network, will elect a root bridge automatically.  In most all cases, automatic root bridge election is not a good idea.  If no other element of spanning tree is manually configured on your network, the root bridge should definitely be set.</p>
<p>Before you configure STP, select a switch to be the root of the spanning tree. This switch does not need to be the most powerful switch, but choose the most centralized switch on the network. All data flow across the network is from the perspective of this switch. Switches in the distribution layer often serve as the spanning tree root because these switches typically do not connect to end stations. Also, moves and changes within the network are less likely to affect these switches.</p>
<p><span id="more-113"></span></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0663307349809080";
google_ad_slot = "4388421750";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>Let&#8217;s consider the following network diagram:</p>
<p style="text-align: center;"><img class="size-full wp-image-73" title="Dynagen network layout using 3640 routers and NM-16ESW modules" src="http://www.xpresslearn.com/wp-content/uploads/2008/02/dynagenfournm-16.gif" alt="" width="451" height="258" /></p>
<p>Vlan3 is defined on the network with SW1configured as the root bridge.</p>
<pre>SW1#show spanning-tree root
VLAN3
  Root ID    Priority    8192
             Address     cc00.0cf4.0002
             This bridge is the root
             Hello Time   2 sec  Max Age 20 sec  Forward Delay 15 sec</pre>
<p>The output of the previous show command reflects that it is the root bridge for Vlan3.  The mac-address shown is the address of the switch serving as the root bridge.  Using the mac address shown in the show spanning-tree root output, we can go searching for the root bridge of any vlan.</p>
<p>The priority was configured on SW1 in order for it to assume root bridge status for vlan 3.  The configuration command executed on SW1:</p>
<pre>SW1(config)#spanning-tree vlan 3 priority 8192</pre>
<p>SW2 is configured to assume the root bridge in the event SW1fails:</p>
<pre>SW2(config)#spanning-tree vlan 3 priority 16384</pre>
<p>Let&#8217;s say on SW3 we configure the following:</p>
<pre>SW3(config)#spanning-tree vlan 3 priority 4096</pre>
<p>Run the show spanning-tree root command again on SW1:</p>
<pre>SW1#show spanning-tree root
VLAN3
  Root ID    Priority    4096
             Address     cc02.0cf4.0002
             Cost        12
             Port        321 (Port-channel1)
             Hello Time   2 sec  Max Age 20 sec  Forward Delay 15 sec</pre>
<p>The mac-address cc02.0cf4.0002 belongs to SW3, which has now become the root bridge for vlan3.  How do you prevent this from happening?</p>
<p>Using best practice configuration techniques, make sure SW3 and SW4 does not become the root bridge for any vlan.</p>
<pre>SW3(config)#spanning-tree vlan 1-4094 priority 65535
SW4(config)#spanning-tree vlan 1-4094 priority 65535</pre>
<p>Configure SW1 and SW2 as the primary and secondary root bridges for vlan 3</p>
<pre>SW1(config)#spanning-tree vlan 3 priority 1
SW2(config)#spanning-tree vlan 3 priority 2</pre>
<p>Remember to do this configuration for each vlan on the network, because in per vlan spanning-tree, there is a root bridge for each spanning-tree instance.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.xpresslearn.com/cisco/switching/spanning-tree-root-bridge/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
