rundeck: secondary sudo password authentication not working

霸气de小男生 提交于 2019-12-25 00:14:23

问题


  <node 
    name="***"
    tags="***" 
    osFamily="***" 
    username="***"
    hostname="192.168.***.***"
    ssh-authentication="password"
    ssh-password-storage-path="keys/nodes/${node.name}/ssh.password"
    sudo-command-enabled="true"
    sudo-password-storage-path="keys/nodes/${node.name}/sudo.password"
  />

Command:

sudo mv /temp/hello.txt /path/to/destination/

Then I have added the password through key storage.

  • I am sure that the password written in sudo.password is correct.
  • I have rebooted rundeck server I can't get this working...
  • I tried setting sudo-fail-on-prompt-timeout="false"

Error received:

Remote command failed with exit status -1 
14:48:18   Sudo execution password response failed: Failed waiting for input prompt: Expected input was not seen in 5000 milliseconds 
14:48:18   Failed: NonZeroResultCode: Remote command failed with exit status -1 

14:48:13   Password:  

What is it not working???


回答1:


After hours, I've found the solution... Control the sudo-prompt-pattern attribute! Depending on which OS, distrib, .. you're using, you DO need to modify default value which is ^[sudo] password for .+: .* https://groups.google.com/forum/#!topic/rundeck-discuss/yiYDlfCkJvY



来源:https://stackoverflow.com/questions/45961196/rundeck-secondary-sudo-password-authentication-not-working

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!