my dog learned polymorphism
The moose likes Linux / UNIX and the fly likes ssh from script Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "ssh from script" Watch "ssh from script" New topic

ssh from script

Satish Kulkarni
Ranch Hand

Joined: Jul 19, 2003
Posts: 60
I am writing a simple script to ssh to a another machine and execute some command


ssh -l <hostip> << EOF

but when I execute the script I am getting the following message

"Pseudo-terminal will not be allocated because stdin is not a terminal." an d I am asked to enter the password on the prompt..

Any idea how this could be resovled.

Stefan Wagner
Ranch Hand

Joined: Jun 02, 2003
Posts: 1923

My manpage tells me lot of possibilities to handle login via /etc/hosts.equiv, ~/.shosts, /etc/ssh/... or other config-files.

(none of them seems to work for me )
Have you checked out Aspose?
subject: ssh from script
It's not a secret anymore!