in reply to Script to telnet to different cisco devices, but timed out at a particular statement.
You might look at this alternative, it's dated, but when I used it never had time out problems. cisco-insert
Neil Watson watson-wilson.ca