cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
984
Views
0
Helpful
1
Replies

Tcl loop

ladius1991
Level 1
Level 1

Hello Guys,

i have a loop Problem, can you help me?

proc ping { IP } {                       
set PING [ exec "ping $IP repeat 3" ]
set PING [ regexp -inline -all {[\.!]{3}} $PING ]


if { [ string first "!" $PING ] == -1 } {typeahead "\yes" puts [ exec "reload" ]}
{
set counter 1
while { $counter == 1}

foreach address {
123.45.67.8
123.45.67.9
109.87.65.4
}
{ after 120
ping $address
}
}

1 Reply 1

Joe Clarke
Cisco Employee
Cisco Employee

Exactly what problem are you seeing?