[英]Rundeck ssh: Failed: AuthenticationFailure: Authentication failure connecting to node:
我正在 RHEL 7.7 上測試來自 Docker 1.13.1 的 rundeck 3.3.0
我有以下節點:
oc3583155071 keys/local/root password
Operating System Linux
ssh-authentication: password
sudo-command-enabled: true
sudo-password-storage-path: keys/local/root
這些是它的關鍵存儲:
keys/local
2 keys
neslarra Password
root Password <<<<<<==============
Storage path: keys/local/root
Created: 5:27 pm by: admin
我從 rundeck shell 測試了 ssh 連接,它工作正常:
rundeck@9ce08386edcd:~$ ssh root@oc3583155071
root@oc3583155071's password:
[root@oc3583155071 ~]# uname -n; whoami
oc3583155071
root
[root@oc3583155071 ~]#
但是,當我嘗試從 runeck GUI 執行命令時,它會返回此錯誤:
Nodes oc3583155071
Recent: uname -n; whoami
> uname -n; whoami #28
Failed: AuthenticationFailure: Authentication failure connecting to node: "oc3583155071". Could not authenticate.
Execution failed: 28 in project Test1: [Workflow result: , step failures: {1=Dispatch failed on 1 nodes: [oc3583155071: AuthenticationFailure: Authentication failure connecting to node: "oc3583155071". Could not authenticate. + {dataContext=MultiDataContextImpl(map={ContextView(node:oc3583155071)=BaseDataContext{{exec={exitCode=-1}}}, ContextView(step:1, node:oc3583155071)=BaseDataContext{{exec={exitCode=-1}}}}, base=null)} ]}, Node failures: {oc3583155071=[AuthenticationFailure: Authentication failure connecting to node: "oc3583155071". Could not authenticate. + {dataContext=MultiDataContextImpl(map={ContextView(node:oc3583155071)=BaseDataContext{{exec={exitCode=-1}}}, ContextView(step:1, node:oc3583155071)=BaseDataContext{{exec={exitCode=-1}}}}, base=null)} ]}, status: failed]
幫助將不勝感激(很多..!)。 內斯特。
您需要配置您的 ssh 目標節點並在 Rundeck 的節點源上正確設置,您的節點定義需要更多屬性,我將這些步驟從頭開始配置:
確保您的目標 ssh 配置允許密碼登錄(在/etc/ssh/sshd_config
配置文件上啟用PasswordAuthentication yes
並重新啟動sshd
服務: systemctl restart sshd
)。
在 Rundeck 端創建一個密碼密鑰,以便稍后在resources.xml
文件( ssh-password-storage-path
屬性)中引用它。
在 Rundeck 方面,確保您使用的是配置良好的節點定義。 我使用了以下resources.xml
。xml 內容示例:
<?xml version="1.0" encoding="UTF-8"?>
<project>
<node name="remote" description="remote ssh node" osFamily="unix" username="vagrant" hostname="192.168.33.20" ssh-authentication="password" ssh-password-storage-path="keys/sshpasswd" />
</project>
name: <your-node-name>
)並發送任何命令(“Enter命令”文本框),您必須看到結果。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.