Do you have selinux enforcing?

On Tue, Apr 8, 2014 at 5:13 AM, Makimoto Marakatti <[email protected]>wrote:

> Hi all
>
> I'm having a weird issue that I can't figure out:
>
> I'm making a backup of /etc/sudoers from client boxes, before templating.
> ansible complains it has no rights to read /etc/sudoers. (with sudo)
> And yet it can read any other file in /etc/.
> /etc/sudoers has 0440 as permissions.
>
> I've tried with fetch, shell, command, and lastly script.
> All fail with some variation of this:
>
> failed: [clientbox] => {"changed": true, "rc": 1}
> stdout: cp: cannot open `/etc/sudoers' for reading: Permission denied
>
> And I know this is not a permissions issue as this actually works in the
> same box:
>
> ssh -t clientbox "sudo -Hi cp /etc/sudoers /tmp/temp_sudoers && sudo -Hi
> chmod 777 /tmp/temp_sudoers && scp /tmp/temp_sudoers
> ansible_masterbox:/tmp/"
>
> Could anyone please let me know what I'm doing wrong here?
>
> Thanks
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/eee2d34a-a2e5-408d-8ccc-e67c11d5a7ee%40googlegroups.com<https://groups.google.com/d/msgid/ansible-project/eee2d34a-a2e5-408d-8ccc-e67c11d5a7ee%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAFg%2Bn8R_1TLJM5Zn7uxd3GtRWz4qT56GjwLT%2B_h3c8PCKXnAaw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to