I'm pretty sure the auth.conf is required in puppet 0.25.x. Try adding
the default one to your puppet conf directory on the puppetmaster.
-brandon
Brandon Evans wrote:
> I'm pretty sure the auth.conf is required in puppet 0.25.x. Try adding
> the default one to your puppet conf directory on the puppetmaster.
I'm happily running 0.25.1 without an auth.conf and haven't seen any issues.
cYa,
Avi
auth.conf is not mandatory. If you don't have one, Puppet will
automatically create sane minimal rules (matching the default provided
auth.conf).
The error the OP posted comes from the file serving layer, so it's more
a fileserver.conf issue.
--
Brice Figureau
Follow the latest Puppet Community evolutions on www.planetpuppet.org!
I don't think so.
IMHO, you should try to add some debug information to your master to see
why those requests are forbidden for you.
The code that checks if the file serving request is allowed is in:
lib/puppet/indirector/file_server.rb
Check the authorized? method.
Add there some Puppet.info or whatever to print request.node and
request.ip. Then compare this to your fileserver.conf.
If the entries don't match then you're fileserver.conf is not correct.
If the entry match, then the request is forbidden because it wasn't
possible to find the correct mount for the file request.
Hope that helps,
--
Brice Figureau
My Blog: http://www.masterzen.fr/
The code is completely different between 0.24.8 and 0.25.1 which is why
you're seeing a difference.
Is network-config a module?
If yes, then your source url is not correct, all the sourced files (for
a module) should be in: <module>/files/<whatever>
Here the url is only <module>/<whatever>
That means puppet "thinks" it isn't a module but a regular mount. Since
your fileserver.conf doesn't contain the "network-config" mount, it
doesn't find any valid mount, so the request is forbidden.
What I suggest:
* move the files under network-config/files/
* open a redmine ticket so that we have a better error message, which
at least would give us the reason.
I don't think we can see this problem as a regression since 0.24,
because this wasn't supposed to work in 0.24.
I re-read the whole thread, and I might have been wrong.
Your module files are indeed placed in network-config/files, correct?
Based on the error message (which mentions network-config/hosts) I
thought you placed your files at the wrong place. My bad.
On 11/11/09 15:52, Larry Ludwig wrote:
>
>
>> The code is completely different between 0.24.8 and 0.25.1 which is why
>> you're seeing a difference.
>
> I understand this, but what works with 0.24.8 should work with 0.25.1
> no? Hence it's looking more like a bug.
Correct.
>> Is network-config a module?
>> If yes, then your source url is not correct, all the sourced files (for
>> a module) should be in:<module>/files/<whatever>
>>
>
> Yes.
>
> But what about 0.24.8 clients that need access to it, the puppetmaster
> output states change it to<module> once all 0.24.8 are gone and it's
> a warning message so it should work as is no?
We're not talking about the same thing. The warning is to make sure you
will prefix all your modules sourced file by the "modules" keyword to
let puppet know we're talking about the "modules" mount.
>> Here the url is only<module>/<whatever>
>> That means puppet "thinks" it isn't a module but a regular mount. Since
>> your fileserver.conf doesn't contain the "network-config" mount, it
>> doesn't find any valid mount, so the request is forbidden.
>>
>> What I suggest:
>> * move the files under network-config/files/
>
> Do you mean the subfolders below files? I did a test for one file and
> same result.
I meant nothing in fact. I misread your problem.
>>
>> * open a redmine ticket so that we have a better error message, which
>> at least would give us the reason.
>
> Ok.
Back to your issue: so we found that the module can't be found.
We have to find why.
Do you use environments?
The only reason I can see for not finding the module, is that module
doesn't exist in the environment the client think it is.
But I'm afraid we will never know if you don't add more debug info in
the various files that finds a module from its path.
The means adding more debug to:
Puppet::Indirector::FileServer#authorized?
Puppet::FileServing::Configuration#find_mount
...
Hope that helps,
Could it be that one of your environment doesn't have network-config?
Could it be that in 0.25 the client is in this environment instead of
being in the one you think it is in?
BTW, how do you tell the client to be in a particular environment?
There is currently a bug report about this (ie environment can only be
set on the client and not in external_nodes anymore).
>>
>> But I'm afraid we will never know if you don't add more debug info in
>> the various files that finds a module from its path.
>> The means adding more debug to:
>>
>> Puppet::Indirector::FileServer#authorized?
>> Puppet::FileServing::Configuration#find_mount
>
> What info do you want?
in Puppet::Indirector::FileServer#authorized?
you should print the value of mount and just after
configuration.split_path(request)
This will let us know if that's indeed the mount that can't be found.
If mount proves to be nil for this particular request, edit:
Puppet::FileServing::Configuration#find_mount
and print the "mount_name".
With that info, edit: Puppet::Module#path
change the code to:
environment.modulepath.collect { |path| File.join(path, name) }.find { |d|
Puppet.info("testing: %s -> exists?: %s" % [d, FileTest.exist?(d) ]
FileTest.exist?(d)
}
(sorry for the bad wrapping, thunderbird sucks at not word-wrapping)
Then check that for network-config it prints true...
Yes.
> having the client set the environment you then will run into the
> chicken and egg syndrome. ie the first time puppet on the node runs
> it's assumes 'production' then you set the puppet.conf via some method
> and then next round runs in the proper environment. So also flipping
> between env will also have the same issue and be one run behind.
>
> Without question it makes sense to have the puppetmaster determine
> this, not the client.
It was/is debatted on puppet-dev.
I think the consensus was that the master should be able to override the
client env, but read the whole thread for more details.
Then that's your issue, because of #2748.
>> Could it be that in 0.25 the client is in this environment instead of
>> being in the one you think it is in?
>
> Checked LDAP config and it is in fact in the correct environment.
> Again the node works with 0.24.8.
#2748 make that your 0.25.1 client is not in the environment that your
ldap says it must be in. So your client is in the environement which is
specified in puppet.conf.
>> BTW, how do you tell the client to be in a particular environment?
>> There is currently a bug report about this (ie environment can only be
>> set on the client and not in external_nodes anymore).
>
> via LDAP. then it still works with 0.24.8 nodes on a 0.25.1 client.
Because 0.24.8 clients don't send their environment to the master. So
the master look it up and comes with what your external_node system returns.
The way it works right now in 0.25 is that the client sends the
environments with every requests, so the master doesn't even try to look
at the external_nodes returned environment and happily do what the
client tells him to do.
yes: http://projects.reductivelabs.com/issues/2770
cheers pete