sshpass is not working

When you are tying to sshpass from another machine. You may suffer from Following problem:-

When you enter a command for sshpass , you will not get prompt of new machine you wanted to login.You will get a prompt of your current machine.

example:

root@local$  sshpass -p ‘password’ ssh usenarme@172.22.25.25

after fired this command  get a prompt of your current machine.

like

root@local$

Solution:-

In that case.Login to your machine you want to sshpass.

install sshpass (sudo apt-get install sshpass)

After installation , please reboot your machine.(that is the most important thing )

and try the sshpass command again.

You will be able to login your desired machine.

example:

root@local$  sshpass -p ‘password’ ssh usenarme@172.22.25.25

you will get a prompt .

root@remote$

The above prompt is the prompt of a machine.You wanted to  login using sshpass.

 

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s