博文背景 实现SSH的自动重连,比如机器正在开机或者网速慢,可以自行不断尝试,直至成功连接。 具体操作 index=0; for ((i=1;i<=10;i++)); do sshpass -p xxxxxxx ssh -o PreferredAuthentications