You are currently browsing the category archive for the 'Uncategorized' category.

As i’ve been going though my mock CCIE labs, I’ve had to modify the initial configs before beginning each lab. The main problem i have is my routers are ISR’s and thus have the #/#/# format for modules vs the older #/# format. I was searching for an easy way to modify all of the initial configs prior to starting each lab. I ended up solving my problem with notepad++ and regex.

Notepad++ allows you to open multiple files at the same time in separate tabs. Notepad++ then allows you to do a find/replace across all OPEN documents using regex.

I first opened all my initial router configs in notepad++ and used the following settings below. Make sure regex is checked and you press replace all in all open documents.

The [0-9] = any number from 0-9. (E.G. Serial0/0 Serial0/1)

The Replace string uses a \1 which is replaced with the first Parentheses value from the find string above.

REPLACE_ALL

notepad++ can be found at http://notepad-plus.sourceforge.net/uk/site.htm

For stub areas, a default route is not propogated by default. You must explicetely tell the ABR to send the default route into the NSSA area.

router ospf 1
area nssa default-information-originate

The above output will generate NSSA Type-2 external default route (LSA type-7).
The metric type for the default route above can be changed to a Type 1 with the metric command.

router ospf 1 area
nssa default-information-originate metric-type 1

If the area is set to NSSA totally stuby area. An Inter-area default route will be created on the ABR and sent to the NSSA totally stubby area.

router ospf 1 area
nssa default-information-originate no-summary

I ran in to an issue where connectivity would drop randomly for around 1 minute. Sometimes this would happen multiple times a day. Other days would have no issues. To help facilitate troubleshooting of the issue, i created an ip sla session to span the path that tracks the last 25 failures.

ip sla 1
icmp-echo 10.1.1.1 source-ip 10.1.1.2
threshold 500
frequency 10
history filter failures
history buckets-kept 25
history lives-kept 1
ip sla schedule 1 life forever start-time now

I was using a tcl script with the IEWB to test connectivity. The extra data included with the pings made it difficult to check the connectivity. I found the below code that will ping multiple devices and output the results in a clean format with either (OK, FAILED)


tclsh
proc ping { IP } {
set PING [ exec "ping $IP repeat 3" ]
set PING [ regexp -inline -all {[\.!]{3}} $PING ]
if { [ string first "!" $PING ] == -1 } {
puts "[format "%-40s %s" "ping $IP" "\[FAILED\]" ]"
} else {
puts "[format "%-40s %s" "ping $IP" "\[ OK \]" ]"
}
}

foreach address {
155.1.146.1
155.1.146.4
155.1.146.6
155.1.67.6
155.1.67.7
155.1.79.7
155.1.79.9
155.1.9.9
155.1.37.7
155.1.37.3
155.1.13.1
155.1.13.3
155.1.23.3
155.1.23.2
155.1.10.10
155.1.108.10
155.1.108.8
155.1.8.8
155.1.58.8
155.1.58.5
155.1.5.5
155.1.45.5
155.45.1.4
155.1.0.1
155.1.0.2
155.1.0.3
155.1.0.4
155.1.0.5
} { ping $address}

And here are my results.

ping 155.1.146.1 [ OK ]
ping 155.1.146.4 [FAILED]
ping 155.1.146.6 [ OK ]
ping 155.1.67.6 [ OK ]
ping 155.1.67.7 [ OK ]
ping 155.1.79.7 [ OK ]
ping 155.1.79.9 [FAILED]
ping 155.1.9.9 [FAILED]
ping 155.1.37.7 [ OK ]
ping 155.1.37.3 [ OK ]
ping 155.1.13.1 [ OK ]
ping 155.1.13.3 [ OK ]
ping 155.1.23.3 [ OK ]
ping 155.1.23.2 [ OK ]
ping 155.1.10.10 [FAILED]
ping 155.1.108.10 [FAILED]
ping 155.1.108.8 [ OK ]
ping 155.1.8.8 [ OK ]
ping 155.1.58.8 [ OK ]
ping 155.1.58.5 [ OK ]
ping 155.1.5.5 [ OK ]
ping 155.1.45.5 [ OK ]
ping 155.45.1.4 [FAILED]
ping 155.1.0.1 [ OK ]
ping 155.1.0.2 [ OK ]
ping 155.1.0.3 [ OK ]
ping 155.1.0.4 [ OK ]
ping 155.1.0.5 [ OK ]