rundeck: secondary sudo password authentication not working

1.8k views Asked by At
  <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

There are 1 answers

0
user7924113 On

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