使用ssh-copy-id :command not found

在客戶端生成一對密鑰(公鑰/私鑰)

ssh-keygen -t rsa -P '' -f ~/.ssh/id_rsa

參數說明: 
-t 加密算法類型,這裏是使用rsa算法 
-P 指定私鑰的密碼,不需要可以不指定 
-f 指定生成祕鑰對保持的位置 

將客戶端公鑰發送個服務端(其他客戶端),使用ssh-copy-id

bash: ssh-copy-id: 未找到命令...  或者
bash: ssh-copy-id :command not found

curl -L https://raw.githubusercontent.com/beautifulcode/ssh-copy-id-for-OSX/master/install.sh | sh

測試:

1.輸入本地安裝軟件的密碼, 看到 Installed ssh-copy-id into /usr/local/bin. 的輸出信息就表示安裝成功了

2.ssh 用戶名@IP地址

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章