From: Wayne Hines (wayneh@DataNetDev.com.au)
Date: Wed Dec 03 2003 - 09:09:30 GMT-3
Hello all,
I temporarily do not have access to a [non production] box with tclsh on it.
Could I request anyone who has 2 routers 1 with tclsh test this simple but
efficient script. It works off a desktop client, just want to reverify it
works from an IOS client before sitting the lab in 36 hours!
Notes
r2 is a box needing tclsh, r1 does not need tclsh
change e0/0 to whatever will give back to back connectivity between routers
as needed.
just about any box with the latest IOS will run it - except 1700 and 2500s
thanks in advance
Wayne
!r1
conf t
hostname r1
ip rcmd rsh-enable
ip rcmd remote-host r2 1.1.1.1 r2 enable
int lo 1
ip add 172.16.30.1 255.255.255.255
int lo 2
ip add 172.16.30.2 255.255.255.255
int e0/0
ip add 172.16.40.1 255.255.255.0
no shut
ip route 0.0.0.0 0.0.0.0 172.16.40.2
end
!r2
conf t
hostname r2
ip rcmd rsh-enable
ip rcmd remote-host r2 1.1.1.1 r2 enable
ip rcmd source-interface Loopback10
interface Loopback10
ip address 1.1.1.1 255.255.255.255
int e0/0
ip add 172.16.40.2 255.255.255.0
no shut
ip route 0.0.0.0 0.0.0.0 172.16.40.1
end
tclsh
foreach i {
172.16.40.1
172.16.40.2
} {
puts "****************R$i***********************"
puts "****************R$i***********************"
puts "****************R$i***********************"
rsh $i sh ip frame map
rsh $i sh ip route
rsh $i sh ip bgp
rsh $i sh ip bgp s
rsh $i sh ip ospf n
rsh $i sh ip eigrp n
foreach j {
1.1.1.1
172.16.30.1
172.16.30.2
172.16.40.1
172.16.40.2
} {
rsh $i ping $j
}
}
tclexit
This archive was generated by hypermail 2.1.4 : Sat Jan 03 2004 - 08:25:35 GMT-3