标签:
#!/bin/sh
sshpass -p "your password" ssh user@ip
注意:
需要先安装sshpass:
源码下载地址:http://sourceforge.net/projects/sshpass/
tar -zxvf sshpass-1.05.tar.gz
cd sshpass-1.05
./configure
make && make install
安装完成后输入sshpass查看是否安装成功
标签:
原文地址:http://www.cnblogs.com/zhaochunhua/p/5180326.html