CCIE Pursuit Blog

April 30, 2008

Question Of The Day: 30 April, 2008

Topic: IOS

You need to add multiple lines of configuration to the following interfaces on sw1:

Fa0/1, Fa0/2, Fa0/3, Fa0/5, Fa0/7, Fa0/8, Fa0/10, Fa0/13, Fa0/14, Fa0/15, Fa0/16, Fa0/17

Can you write a single-line interface range command to apply the changes to all of these interfaces at one time?

Click Here For Answer


Yesterday’s Question

Question Of The Day: 29 April, 2008 

Topic: OSPF

You have the following configuration on r1.

interface Loopback0
 ip address 1.1.1.1 255.0.0.0
!
router ospf 100
 router-id 1.1.1.1
 log-adjacency-changes
 network 1.1.1.1 0.0.0.0 area 0
 network 10.1.12.1 0.0.0.0 area 0

r2 is seeng the loopback address with a /32 mask:

r2#sh ip route ospf
     1.0.0.0/32is subnetted, 1 subnets
O       1.1.1.1 [110/2] via 10.1.12.1, 00:00:13, FastEthernet0/0

Using only a single command, make it so that r2 sees r1’s Loopback 0 with its configured network mask.

Answer: ip ospf network point-to-point

OSPF treats Loopback interfaces as stub networks and will advertise these networks as host routes (/32) regardless of the ‘native’ network mask. 

r1#show ip ospf interface loopback 0
Loopback0 is up, line protocol is up
  Internet Address 1.1.1.1/8, Area 0 
  Process ID 100, Router ID 1.1.1.1, Network Type LOOPBACK, Cost: 1
 Loopback interface is treated as a stub Host

To avoid this behavior you need to change the OSPF network type of the Loopback interface to point-to-point.  Why point-to-point?  Because it’s the only OSPF network type that IOS will accept for a Loopback interface:

r1(config-if)#ip ospf network non-broadcast
OSPF: Invalid type for interface

      
r1(config-if)#ip ospf network broadcast
OSPF: Invalid type for interface

r1(config-if)#ip ospf network point-to-multipoint
OSPF: Invalid type for interface

r1(config-if)#ip ospf network point-to-multipoint non-broadcast
OSPF: Invalid type for interface

After you change the Loopback interface to an OSPF point-to-point network, you will see the route on r2 as a /8.

r1(config)#interface loopback 0          
r1(config-if)#ip ospf network point-to-point

r1(config-if)#do sh ip os int lo0
Loopback0 is up, line protocol is up
  Internet Address 1.1.1.1/8, Area 0
  Process ID 100, Router ID 1.1.1.1, Network Type POINT_TO_POINT, Cost: 1
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    oob-resync timeout 40
  Supports Link-local Signaling (LLS)
  Index 2/2, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 0, maximum is 0
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 0, Adjacent neighbor count is 0
  Suppress hello for 0 neighbor(s)

r2#sh ip route ospf
O    1.0.0.0/8 [110/2] via 10.1.12.1, 00:02:08, FastEthernet0/0

Advertisements

2 Comments »

  1. Ah! An easy one that I use all the time… not often that discontiguous though 🙂 There are several ways to do this, but the one I would use without thinking about it would be:

    sw1(config)# int range Fa0/1 – 3 , Fa0/5 , Fa0/7 – 8 , Fa0/10 , Fa0/13 – 17

    Comment by Steve — April 30, 2008 @ 4:10 pm | Reply

  2. […] Question Of The Day: 30 April, 2008  […]

    Pingback by Question Of The Day: 01 May, 2008 « CCIE Pursuit — May 1, 2008 @ 9:44 am | Reply


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.

%d bloggers like this: