Hi,
The basic question would be:
What's working, and what is not?
Obvious things you should change:
- $prompt='bash-2.03'
- add $telnet->dump_log('/tmp/telnet.log');, before the $telnet->open(...); and see what is really happening in the telnet session.
We can give you lots of ideas, but to help you out may be needed that you explain us better what your problem is.