Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: How to incorporate Expect in Perl Script? OR Pass the password via perl script?

by Corion (Patriarch)
on Jul 12, 2022 at 15:16 UTC ( [id://11145453]=note: print w/replies, xml ) Need Help??


in reply to How to incorporate Expect in Perl Script? OR Pass the password via perl script?

Consider using a (passwordless) SSH key to store the access credentials for the remote machine.

Your expect call likely fails because expect or ssh wants a (pseudo-)terminal connected to do their stuff.

Replies are listed 'Best First'.
Re^2: How to incorporate Expect in Perl Script? OR Pass the password via perl script?
by prad001 (Initiate) on Jul 13, 2022 at 12:51 UTC
    The expect command works fine from the command line but I am not sure how to incorporate that in to the perl script that I have mentioned..!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11145453]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (8)
As of 2024-04-18 10:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found