Hi, I am trying to debug some abnormal behavior here and to help me figure out what is happening, I''ve run the agent with --graph option. And meanwhile I''ve found that under resources.odt I see a Class[Main] node child with a wrong hostname. Class[Main]->Node[hyp2-cdn-*picd*.foo.bar] but in my manifest I''ve defined this hostname using a regular expression like: node /^hyp2\-cdn\-*pic\d+*\.foo\.bar$/ inherits hyp2_base { # stuff file { ''''/tmp/puppet_debug.txt": ensure => file, content => "DEBUG" } } I can see the puppet_debug.txt file content so I can assume it goes through the correct class, but shouldn''t it be: Class[Main]->Node[hyp2-cdn-*pic01*.foo.bar] and so on? : malfunction behavior is not related with this... I am just trying to debug: somehow, after register and apply the catalog without errors, the server gets out of puppet and if I run puppet agent --no-daemonize -v -d -o it asks me to sign it again. weird... Cheers, Francisco -- 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.
On Wednesday, September 4, 2013 11:40:01 AM UTC-5, ureal frank wrote:> > Hi, > > > I am trying to debug some abnormal behavior here and to help me figure out > what is happening, I''ve run the agent with --graph option. > > And meanwhile I''ve found that under resources.odt I see a Class[Main] node > child with a wrong hostname. > > Class[Main]->Node[hyp2-cdn-*picd*.foo.bar] > > but in my manifest I''ve defined this hostname using a regular expression > like: > > node /^hyp2\-cdn\-*pic\d+*\.foo\.bar$/ inherits hyp2_base { > > # stuff > > file { ''''/tmp/puppet_debug.txt": > ensure => file, > content => "DEBUG" > } > } > > I can see the puppet_debug.txt file content so I can assume it goes > through the correct class, but shouldn''t it be: > > Class[Main]->Node[hyp2-cdn-*pic01*.foo.bar] and so on? > >No. Puppet is identifying the chosen *node block* with that label, not the client. The label is Puppet''s string version of your regex. There is still a ticklish issue here, in that Puppet needs to support mixing regex node identifiers with string node idientifiers in the same manifest set. I have seen clashes between the two before, but that doesn''t appear to be a problem in your case. John -- 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.
On Thu, Sep 5, 2013 at 2:25 PM, jcbollinger <John.Bollinger@stjude.org>wrote:> > > On Wednesday, September 4, 2013 11:40:01 AM UTC-5, ureal frank wrote: >> >> Hi, >> >> >> I am trying to debug some abnormal behavior here and to help me figure >> out what is happening, I''ve run the agent with --graph option. >> >> And meanwhile I''ve found that under resources.odt I see a Class[Main] >> node child with a wrong hostname. >> >> Class[Main]->Node[hyp2-cdn-*picd*.foo.bar] >> >> but in my manifest I''ve defined this hostname using a regular expression >> like: >> >> node /^hyp2\-cdn\-*pic\d+*\.foo\.bar$**/ inherits hyp2_base { >> >> # stuff >> >> file { ''''/tmp/puppet_debug.txt": >> ensure => file, >> content => "DEBUG" >> } >> } >> >> I can see the puppet_debug.txt file content so I can assume it goes >> through the correct class, but shouldn''t it be: >> >> Class[Main]->Node[hyp2-cdn-*pic01*.foo.bar] and so on? >> >> > > No. Puppet is identifying the chosen *node block* with that label, not > the client. The label is Puppet''s string version of your regex. >Ah ok. I didn''t knew that. Anyway I think it is a weird way of representing the Node[name] :)> > There is still a ticklish issue here, in that Puppet needs to support > mixing regex node identifiers with string node idientifiers in the same > manifest set. I have seen clashes between the two before, but that doesn''t > appear to be a problem in your case. >Is there any good practice on this? Should I stick to just one way of defining nodes. Just regexp for example?> > John > > -- > 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. >-- 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.
On Thursday, September 5, 2013 10:00:34 AM UTC-5, ureal frank wrote:> > > > > On Thu, Sep 5, 2013 at 2:25 PM, jcbollinger <John.Bo...@stjude.org<javascript:> > > wrote: > >> >> >> On Wednesday, September 4, 2013 11:40:01 AM UTC-5, ureal frank wrote: >>> >>> Hi, >>> >>> >>> I am trying to debug some abnormal behavior here and to help me figure >>> out what is happening, I''ve run the agent with --graph option. >>> >>> And meanwhile I''ve found that under resources.odt I see a Class[Main] >>> node child with a wrong hostname. >>> >>> Class[Main]->Node[hyp2-cdn-*picd*.foo.bar] >>> >>> but in my manifest I''ve defined this hostname using a regular expression >>> like: >>> >>> node /^hyp2\-cdn\-*pic\d+*\.foo\.bar$**/ inherits hyp2_base { >>> >>> # stuff >>> >>> file { ''''/tmp/puppet_debug.txt": >>> ensure => file, >>> content => "DEBUG" >>> } >>> } >>> >>> I can see the puppet_debug.txt file content so I can assume it goes >>> through the correct class, but shouldn''t it be: >>> >>> Class[Main]->Node[hyp2-cdn-*pic01*.foo.bar] and so on? >>> >>> >> >> No. Puppet is identifying the chosen *node block* with that label, not >> the client. The label is Puppet''s string version of your regex. >> > > Ah ok. > I didn''t knew that. > Anyway I think it is a weird way of representing the Node[name] :) > > >> >> There is still a ticklish issue here, in that Puppet needs to support >> mixing regex node identifiers with string node idientifiers in the same >> manifest set. I have seen clashes between the two before, but that doesn''t >> appear to be a problem in your case. >> > > Is there any good practice on this? > Should I stick to just one way of defining nodes. Just regexp for example? > >I don''t think you need to worry too much about it. As I recall, catalog compilation failed when Puppet''s string version of a node regex was the same as a plain-string node label, so you''ll know if you ever get a clash. And clashes will only happen with node labels that bear a strong similarity to node regexes used in the same manifest set, so you have more genteel means to mitigate your risk than forbidding plain-string node labels. John -- 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.