Pradeep Chhetri
2013-Jan-23 12:34 UTC
[Puppet Users] Puppet error while serving /etc/sudoers file using puppet
I am trying to update /etc/sudoers file using puppet. Here is the init.pp function doing: define sudoers() { file { "/etc/sudoers": owner => root, group => root, mode => 440, source => $operatingsystem ? { "CentOS" => filelookup("users/sudoers-centos"), default => filelookup("users/sudoers"), }, } While running puppet I am getting the error: err: /Stage[main]//Node[tcp-handler-base]/Users::Sudoers[sudoers-file]/File[/etc/sudoers]/content: change from {md5}0897462d4d48fb9dedaafbaf91a9ceae to {md5}3298e302080d0e63a5697dd39556ca66 failed: Could not rename temporary file /etc/sudoers.puppettmp_8514 to /etc/sudoers: Operation not permitted - /etc/sudoers.puppettmp_8514 or /etc/sudoers at /etc/puppet/modules/users/manifests/init.pp:60 The persmission of /etc/sudoers file is 0440. Can someone help in solving this. -- Pradeep Chhetri In the world of Linux, who needs Windows and Gates... -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Jakov Sosic
2013-Jul-01 19:14 UTC
Re: [Puppet Users] Puppet error while serving /etc/sudoers file using puppet
On 01/23/2013 01:34 PM, Pradeep Chhetri wrote:> err: > /Stage[main]//Node[tcp-handler-base]/Users::Sudoers[sudoers-file]/File[/etc/sudoers]/content: > change from {md5}0897462d4d48fb9dedaafbaf91a9ceae to > {md5}3298e302080d0e63a5697dd39556ca66 failed: Could not rename temporary > file /etc/sudoers.puppettmp_8514 to /etc/sudoers: Operation not > permitted - /etc/sudoers.puppettmp_8514 or /etc/sudoers at > /etc/puppet/modules/users/manifests/init.pp:60 > > The persmission of /etc/sudoers file is 0440. > > Can someone help in solving this.Are you running puppet as ''root'' user? Also are you using SELinux? -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com. To post to this group, send email to puppet-users@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-users. For more options, visit https://groups.google.com/groups/opt_out.