Hi everyone,
I am new user on ansible and I have a little difficulty to execute commands remotely on a Ubuntu Server. (Ubuntu don’t accept ssh with user root and the user vamberto can use sudo su - )
My machine is a Fedora Linux and I execute this command: ansible -vvv wolverine -m apt -a “update_cache=yes” --user=vamberto -k --become-method=su --become-user=root --ask-become-pass
And the server asks
SSH password:
SU password[defaults to SSH password]:
After I putt the ssh and su password I receive this error:
olverine | FAILED >> {
“failed”: true,
“msg”: “Failed to lock apt for exclusive operation”
}
Someone can help me ?