Martin Englund
2009-Sep-09 16:35 UTC
[Puppet Users] Apache load balancing problem with 0.25.0
Here''s another problem which I ran into today: When running puppetd with a puppetmaster which is 6 mongrel instances load balanced with apache, I get: /usr/ops/lib/ruby/site_ruby/1.8/puppet/network/format_handler.rb:87:in `format_to_canonical_name'': No format match the given format name or mime-type (text/html) (ArgumentError) If I stop apache and fire up the puppetmaster as normal, puppetd doesn''t fail with the above error. Inspecting the code where it fails makes me scratch my head (code included at the bottom). The variable "format" is, according to the error message, "text/html" - but that should have matched then when clause "%r{\w+/\w+}". Can someone help me shed some light on this? cheers, /Martin puppet/network/format_handler.rb: # Return a format name given: # * a format name # * a mime-type # * a format instance def self.format_to_canonical_name(format) case format when Puppet::Network::Format out = format when %r{\w+/\w+} out = mime(format) else out = format(format) end raise ArgumentError, "No format match the given format name or mime-type (%s)" % format if out.nil? out.name end cheers, /Martin --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
On Sep 9, 5:35 pm, Martin Englund <martin.engl...@sun.com> wrote:> Inspecting the code where it fails makes me scratch my head (code > included at the bottom). The variable "format" is, according to the > error message, "text/html" - but that should have matched then when > clause "%r{\w+/\w+}". >I''m one step closer: I''ve figured out that mime("text/html") returns nil, so now I need to figure out how to get my apache reverse proxy to let puppetd know it accepts yaml, marshal, raw & json... cheers, /Martin> puppet/network/format_handler.rb: > > # Return a format name given: > # * a format name > # * a mime-type > # * a format instance > def self.format_to_canonical_name(format) > case format > when Puppet::Network::Format > out = format > when %r{\w+/\w+} > out = mime(format) > else > out = format(format) > end > raise ArgumentError, "No format match the given format name or > mime-type > (%s)" % format if out.nil? > out.name > end >--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Christopher Webber
2010-May-26 14:22 UTC
Re: [Puppet Users] Re: Apache load balancing problem with 0.25.0
Was a solution to this issue ever found? I just upgraded my puppetmaster to 0.25.5 and the only client that is having issues is the only client running 0.25.5. -- cwebber On Sep 9, 2009, at 1:14 PM, martin wrote:> > On Sep 9, 5:35 pm, Martin Englund <martin.engl...@sun.com> wrote: > >> Inspecting the code where it fails makes me scratch my head (code >> included at the bottom). The variable "format" is, according to the >> error message, "text/html" - but that should have matched then when >> clause "%r{\w+/\w+}". >> > I''m one step closer: I''ve figured out that mime("text/html") returns > nil, so now I need to figure out how to get my apache reverse proxy to > let puppetd know it accepts yaml, marshal, raw & json... > > cheers, > /Martin > >> puppet/network/format_handler.rb: >> >> # Return a format name given: >> # * a format name >> # * a mime-type >> # * a format instance >> def self.format_to_canonical_name(format) >> case format >> when Puppet::Network::Format >> out = format >> when %r{\w+/\w+} >> out = mime(format) >> else >> out = format(format) >> end >> raise ArgumentError, "No format match the given format name or >> mime-type >> (%s)" % format if out.nil? >> out.name >> end >> > > --~--~---------~--~----~------------~-------~--~----~ > 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 > -~----------~----~----~----~------~----~------~--~--- >-- 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.