diff --git a/content/posts/linux-command.md b/content/posts/linux-command.md index 5c7fb19..220404b 100644 --- a/content/posts/linux-command.md +++ b/content/posts/linux-command.md @@ -28,4 +28,34 @@ memray run --live -m module.file ```bash pip install py-spy py-spy top --pid ${pid} +``` + +### 批量设置ssh自动登录 + + + +```bash +#!/bin/bash +# FileName: auto-ssh-login.sh +# Revision: 1.0 +# Date: 2020-03-25 +# Author: baige +# Description: the script for auto-ssh-login +while read host;do + ip=`echo $host | cut -d " " -f1` + username=`echo $host | cut -d " " -f2` + password=`echo $host | cut -d " " -f3` +expect <