Telnet script
Hi
I use redhat and need a telnet script in bash, so I CTRL+C CTRL+V this: #/bin/bash (sleep 10s echo "login" sleep 3s echo "senha" sleep 5s echo "sh atm sub atm 1/3.115127" sleep 5s echo "exit" ) | telnet X.X.X.X But it just doesn't work.... 'leep: intervalo de tempo inválido `10s Tente `sleep --help' para mais informação. 'leep: intervalo de tempo inválido ` Tente `sleep --help' para mais informação. 'leep: intervalo de tempo inválido ` Tente `sleep --help' para mais informação. 'leep: intervalo de tempo inválido ` Tente `sleep --help' para mais informação. : Name or service not known : Unknown host : command not foundne 11: |
Welcome to LQ.
You would probably have more luch use an expect script. Or even better, jsut use ssh instead of telnet. |
All times are GMT -5. The time now is 04:52 AM. |