Error 400 on SERVER: Not authorized to call find AND Error 403 on SERVER: Forbidden request: client2.puppet.com

2,287 views
Skip to first unread message

jyotir bhandari

unread,
Feb 3, 2014, 4:38:08 AM2/3/14
to puppet...@googlegroups.com
Hi

I am trying to transfer shell file via fileserver in pupper, but i am continuously getting the mentioned error.

fileserver.conf

[files]
   path /etc/puppet/files
   allow *

auth.conf

path ~ ^/file_(metadata|content)/files/
auth yes
allow /^(.+\.)?puppet.com$/
allow_ip 192.168.1.0/24

init.pp

class accounts {
   @accounts::system { 'demo':
       comment      => 'demo users',
      }

file { '/etc/puppet/templates/shadow.sh':
    ensure => file,
    recurse => true,
    mode => "0777",
    source => "puppet:///files/shadow.sh",
     }

exec { "demo":
          command => 'echo "demo:redhat@123" | chpasswd',
          provider => 'shell',
          require => File['/etc/puppet/templates/shadow.sh'],
     }
}

Error on Client :

Error: /File[/var/lib/puppet/lib]: Failed to generate additional resources using 'eval_generate': Error 403 on SERVER: Forbidden request: client2.puppet.com(192.168.1.19) access to /file_metadata/plugins [search] authenticated  at :128
Debug: file_metadata supports formats: pson msgpack b64_zlib_yaml yaml raw
Error: /File[/var/lib/puppet/lib]: Could not evaluate: Error 403 on SERVER: Forbidden request: client2.puppet.com(192.168.1.19) access to /file_metadata/plugins [find] authenticated  at :128 Could not retrieve file metadata for puppet://server.puppet.com/plugins: Error 403 on SERVER: Forbidden request: client2.puppet.com(192.168.1.19) access to /file_metadata/plugins [find] authenticated  at :128

Error: /Stage[main]/Accounts/File[/etc/puppet/templates/shadow.sh]: Failed to generate additional resources using 'eval_generate': Error 400 on SERVER: Not authorized to call search on /file_metadata/files/shadow.sh with {:links=>"manage", :recurse=>true, :checksum_type=>"md5"}
Debug: file_metadata supports formats: pson msgpack b64_zlib_yaml yaml raw
Error: /Stage[main]/Accounts/File[/etc/puppet/templates/shadow.sh]: Could not evaluate: Error 400 on SERVER: Not authorized to call find on /file_metadata/files/shadow.sh with {:links=>"manage"} Could not retrieve file metadata for puppet:///files/shadow.sh: Error 400 on SERVER: Not authorized to call find on /file_metadata/files/shadow.sh with {:links=>"manage"}


Jyotir




jyotir bhandari

unread,
Feb 3, 2014, 9:04:44 AM2/3/14
to puppet...@googlegroups.com
Hi

I have made changes in auth.conf and fileserver.conf for plugins, still it is not working

auth.conf

path /plugins
allow *

fileserver.conf

[plugins]
  allow *

puppet.conf on master

[main]
pluginsync = true

Error on client :



Debug: file_metadata supports formats: pson msgpack b64_zlib_yaml yaml raw
Error: /File[/var/lib/puppet/lib]: Failed to generate additional resources using 'eval_generate': Error 403 on SERVER: Forbidden request: client2.puppet.com(192.168.1.19) access to /file_metadata/plugins [search] authenticated  at :131

Debug: file_metadata supports formats: pson msgpack b64_zlib_yaml yaml raw
Error: /File[/var/lib/puppet/lib]: Could not evaluate: Error 403 on SERVER: Forbidden request: client2.puppet.com(192.168.1.19) access to /file_metadata/plugins [find] authenticated  at :131 Could not retrieve file metadata for puppet://server.puppet.com/plugins: Error 403 on SERVER: Forbidden request: client2.puppet.com(192.168.1.19) access to /file_metadata/plugins [find] authenticated  at :131


What can be the issue, i was able to resolve 400 error by placing pluginsync = true in master server.

I also changed config.ru as referred in https://projects.puppetlabs.com/issues/4367, but i still wasn't able to resolve forbidden error.

Please guide where I might be doing mistake.

Jyotir

jyotir bhandari

unread,
Feb 3, 2014, 9:29:20 PM2/3/14
to puppet...@googlegroups.com
Hi

Resolved issue, mistake at my end was a typo error in auth.conf ---- path /file was path /files


Jyotir

On Monday, 3 February 2014 15:08:08 UTC+5:30, jyotir bhandari wrote:
Reply all
Reply to author
Forward
0 new messages