Mark Plaksin
2008-Feb-12 17:27 UTC
0.24.1 puppetmaster skips new config with syntax errors?
Is puppetmaster supposed to ignore manifest changes when those changes include syntax errors? And then it does notice when I restart puppetmaster? That''s what seems to be happening to me. For example, if I put a syntax error in my.pp and then test a client against the the master I get no complaints. If I restart puppetmaster and retest the client says "Ack! Syntax error!". I could sort of see this being a feature--puppetmaster refuses to acknowledge new configs that have syntax errors. But since it *does* notice on restart it''s possible to have syntax errors waiting to bite you. (I finally have a pre-commit hook in place so I shouldn''t run into this situation any more :) This is with 0.24.1 client and server both running on RHEL 5.
Luke Kanies
2008-Feb-12 18:20 UTC
Re: 0.24.1 puppetmaster skips new config with syntax errors?
On Feb 12, 2008, at 11:27 AM, Mark Plaksin wrote:> Is puppetmaster supposed to ignore manifest changes when those changes > include syntax errors? And then it does notice when I restart > puppetmaster? That''s what seems to be happening to me. > > For example, if I put a syntax error in my.pp and then test a client > against the the master I get no complaints. If I restart puppetmaster > and retest the client says "Ack! Syntax error!". > > I could sort of see this being a feature--puppetmaster refuses to > acknowledge new configs that have syntax errors. But since it *does* > notice on restart it''s possible to have syntax errors waiting to bite > you. > > (I finally have a pre-commit hook in place so I shouldn''t run into > this > situation any more :) > > This is with 0.24.1 client and server both running on RHEL 5.It should definitely notice syntax errors and at least log them. I think I noticed the same thing but I couldn''t track it down; it would make sense that the errors are only when reparsing, not on the initial parse. Can you file this for me? I''ll get it fixed in 0.24.2, which will be out as soon as we start moving two tickets forward for every one ticket back. :/ -- Today at work an ethernet switch decided to take the ''N'' out of NVRAM -- Richard Letts --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com
Nigel Kersten
2008-Feb-12 19:51 UTC
Re: 0.24.1 puppetmaster skips new config with syntax errors?
On Feb 12, 2008 9:27 AM, Mark Plaksin <happy@usg.edu> wrote:> > (I finally have a pre-commit hook in place so I shouldn''t run into this > situation any more :) >One thing I noticed that I wasn''t sure if it was a bug or not was that puppetmasterd --parseonly ignores modules if you''re not explicitly importing the init.pp files with globbing. I ended up setting up a parseonly.pp file and class that does explicitly parse them like: puppetmasterd --parseonly --verbose --confdir="${confdir}" --manifest="${confdir}/manifests/parseonly.pp" class parseonly { import "../../modules/*/manifests/init.pp" } include parseonly import "site.pp" Should this be considered a bug ? -- Nigel Kersten Systems Administrator MacOps _______________________________________________ Puppet-users mailing list Puppet-users@madstop.com https://mail.madstop.com/mailman/listinfo/puppet-users
Luke Kanies
2008-Feb-12 20:20 UTC
Re: 0.24.1 puppetmaster skips new config with syntax errors?
On Feb 12, 2008, at 1:51 PM, Nigel Kersten wrote:> On Feb 12, 2008 9:27 AM, Mark Plaksin <happy@usg.edu> wrote: > > (I finally have a pre-commit hook in place so I shouldn''t run into > this > situation any more :) > > > One thing I noticed that I wasn''t sure if it was a bug or not was > that puppetmasterd --parseonly ignores modules if you''re not > explicitly importing the init.pp files with globbing. > > I ended up setting up a parseonly.pp file and class that does > explicitly parse them like: > > puppetmasterd --parseonly --verbose --confdir="${confdir}" -- > manifest="${confdir}/manifests/parseonly.pp" > > class parseonly { > import "../../modules/*/manifests/init.pp" > } > > include parseonly > > import "site.pp" > > > Should this be considered a bug ?Implicit imports happen at compile time, not parse time, so there''s no way to know what files would be imported. I recommend running parseonly againsts all changed .pp files, basically. -- I used to get high on life but lately I''ve built up a resistance. --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com
Mark Plaksin
2008-Feb-12 21:28 UTC
Re: 0.24.1 puppetmaster skips new config with syntax errors?
Luke Kanies <luke@madstop.com> writes:> On Feb 12, 2008, at 11:27 AM, Mark Plaksin wrote: > >> Is puppetmaster supposed to ignore manifest changes when those changes >> include syntax errors? And then it does notice when I restart >> puppetmaster? That''s what seems to be happening to me. >> >> For example, if I put a syntax error in my.pp and then test a client >> against the the master I get no complaints. If I restart puppetmaster >> and retest the client says "Ack! Syntax error!". >> >> I could sort of see this being a feature--puppetmaster refuses to >> acknowledge new configs that have syntax errors. But since it *does* >> notice on restart it''s possible to have syntax errors waiting to bite >> you. >> >> (I finally have a pre-commit hook in place so I shouldn''t run into >> this >> situation any more :) >> >> This is with 0.24.1 client and server both running on RHEL 5. > > It should definitely notice syntax errors and at least log them. I > think I noticed the same thing but I couldn''t track it down; it would > make sense that the errors are only when reparsing, not on the initial > parse. > > Can you file this for me? I''ll get it fixed in 0.24.2, which will be > out as soon as we start moving two tickets forward for every one > ticket back. :/Done: http://reductivelabs.com/trac/puppet/ticket/1063
Andrew Otto
2008-Feb-13 04:38 UTC
Re: 0.24.1 puppetmaster skips new config with syntax errors?
I''ve also seen this behavior, it happens for me in exactly the same way. On Feb 13, 2008, at 12:27 AM, Mark Plaksin wrote:> Is puppetmaster supposed to ignore manifest changes when those changes > include syntax errors? And then it does notice when I restart > puppetmaster? That''s what seems to be happening to me. > > For example, if I put a syntax error in my.pp and then test a client > against the the master I get no complaints. If I restart puppetmaster > and retest the client says "Ack! Syntax error!". > > I could sort of see this being a feature--puppetmaster refuses to > acknowledge new configs that have syntax errors. But since it *does* > notice on restart it''s possible to have syntax errors waiting to bite > you. > > (I finally have a pre-commit hook in place so I shouldn''t run into > this > situation any more :) > > This is with 0.24.1 client and server both running on RHEL 5. > > _______________________________________________ > Puppet-users mailing list > Puppet-users@madstop.com > https://mail.madstop.com/mailman/listinfo/puppet-users