write(spawn_id=]: broken pipe
- From: "Ranjan" <ranjan.kapoor@xxxxxxxxx>
- Date: 14 Apr 2007 03:11:56 -0700
I have written a small expect script to telnet a FreeBSD machine and
send some commands to that machine remotely, through Windows XP
machine
These commands are being sent periodically in a loop. After sending
few command , the scripts throws the following exception:
write(spawn_id=]: broken pipe
while executing
"send -s "ipfw pipe 1 config delay $mod_delay \r""
invoked from within
"expect -nobrace 1# {
for { set cycle 0 } { $cycle < $no_of_cycles } {incr
cycle } {
puts "###..."
invoked from within
"expect {
"1#" {
for { set cycle 0 } { $cycle < $no_of_cycles } {incr
cycle } {
Can anybody please let me know the cause for this.
Is this issue of the freeBSD machine or my PC. Can what can be the
workaround for this
Extract from my script:
..
..
expect {
"1#" {
for { set cycle 0 } { $cycle < $no_of_cycles } {incr
cycle } {
puts "##### CYCLE NUMBER -- $cycle #####"
while { $delay <= $max_delay } {
set mod_delay [join "$delay ms" ""]
puts stdout "\nDelay set to $mod_delay\n"
send -s "ipfw pipe 1 config delay $mod_delay
\r"
set delay [expr $delay + $incr_delay]
after $wait
}
set delay $min_delay
}
}
timeout { puts "Timeout !!!"
exp_continue }
}
..
..
..
Additional Info: I am using Dummynet application of FreeBSD to
simulate Network delays.
And these commands are used to insert variable
delays in packets received from one port and are then sent out
on another interface.
.
- Follow-Ups:
- Re: write(spawn_id=]: broken pipe
- From: Bezoar
- Re: write(spawn_id=]: broken pipe
- From: Alexandre Ferrieux
- Re: write(spawn_id=]: broken pipe
- Prev by Date: looking for tcl based Cisco like command line interface
- Next by Date: Re: LDAP troubles
- Previous by thread: looking for tcl based Cisco like command line interface
- Next by thread: Re: write(spawn_id=]: broken pipe
- Index(es):
Relevant Pages
|