Re: [Puppet Users] augtool/augeas doesn't work in f17?
On 07/12/12 11:56, Bret Wortman wrote: Even in interactive mode, I get nothing out of augtool! What should I look at to see why this is failing? Syslog doesn't show anything illustrative, nor did puppet agent -t --debug. The lack of errors from the augeas resource type should be much improved now if you're able to use Puppet 3. I've added debug if there are parsing errors (which will print output equivalent to Raphaël's augtool suggestion) and warnings if you're using context/incl parameters and it finds an error on a file you're trying to modify. -- Dominic Cleal Red Hat Engineering -- 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+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Re: [Puppet Users] augtool/augeas doesn't work in f17?
On Monday, December 10, 2012 1:51:46 PM UTC-5, Bret Wortman wrote: On Monday, December 10, 2012 8:34:17 AM UTC-5, Dominic Cleal wrote: On 07/12/12 11:56, Bret Wortman wrote: Even in interactive mode, I get nothing out of augtool! What should I look at to see why this is failing? Syslog doesn't show anything illustrative, nor did puppet agent -t --debug. The lack of errors from the augeas resource type should be much improved now if you're able to use Puppet 3. I am using Puppet 3 -- 3.0.1-1, to be precise. In response to Raphael's suggestion, I'm able to find some errors and can work through those. I spoke too soon. The specific file I'm trying to work with is /etc/cron.allow. When I try to parse it: augtool ls /files/etc/cron.allow augtool print /augeas//error /augesa/files/etc/hosts/error = parse_failed /augeas/files/etc/hosts/error/pos = 18473 /augeas/files/etc/hosts/error/line = 273 /augeas/files/etc/hosts/error/char = 0 /augeas/files/etc/hsots/error/lens = /usr/share/augeas/lenses/dist/hosts.aug:23.12-.42: /augeas/files/etc/hsots/error/message = Iterated lens matched less than it should It doesn't look like the error is getting updated, or am I misunderstanding something? Where should these be printing to from Puppet? I've added debug if there are parsing errors (which will print output equivalent to Rapha�l's augtool suggestion) and warnings if you're using context/incl parameters and it finds an error on a file you're trying to modify. -- Dominic Cleal Red Hat Engineering -- You received this message because you are subscribed to the Google Groups Puppet Users group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/lFktVrVF4_8J. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Re: [Puppet Users] augtool/augeas doesn't work in f17?
On 10/12/12 18:59, Bret Wortman wrote: On Monday, December 10, 2012 1:51:46 PM UTC-5, Bret Wortman wrote: On Monday, December 10, 2012 8:34:17 AM UTC-5, Dominic Cleal wrote: On 07/12/12 11:56, Bret Wortman wrote: Even in interactive mode, I get nothing out of augtool! What should I look at to see why this is failing? Syslog doesn't show anything illustrative, nor did puppet agent -t --debug. The lack of errors from the augeas resource type should be much improved now if you're able to use Puppet 3. I am using Puppet 3 -- 3.0.1-1, to be precise. In response to Raphael's suggestion, I'm able to find some errors and can work through those. I spoke too soon. The specific file I'm trying to work with is /etc/cron.allow. When I try to parse it: Ah ok, cron.allow doesn't have a lens in Augeas 0.10.0, it's something that's only been added recently. This is why it won't even show up as a parse error. What you could try is taking the lens from git: http://git.fedorahosted.org/cgit/augeas.git/tree/lenses/simplelines.aug Either store it in /usr/share/augeas/lenses/, or add it to a module at modulename/lib/augeas/lenses/ and it will pluginsync to the client[1]. If you put it in the former directory, you should be able to do an ls from augtool. augtool ls /files/etc/cron.allow augtool print /augeas//error /augesa/files/etc/hosts/error = parse_failed /augeas/files/etc/hosts/error/pos = 18473 /augeas/files/etc/hosts/error/line = 273 /augeas/files/etc/hosts/error/char = 0 /augeas/files/etc/hsots/error/lens = /usr/share/augeas/lenses/dist/hosts.aug:23.12-.42: /augeas/files/etc/hsots/error/message = Iterated lens matched less than it should It doesn't look like the error is getting updated, or am I misunderstanding something? When you run augtool, it parses all the files (in their default locations) that it knows about. So that's just reporting it has a parse error with your /etc/hosts file on line 273 (!!), which is going to be unrelated to cron.allow. As above, because 0.10.0 doesn't have support for cron.allow, nothing appears when you do an ls for that file. Where should these be printing to from Puppet? It would be printing in the debug logs, but it would probably only print the /etc/hosts error since that's the only one that occurred. [1]http://docs.puppetlabs.com/guides/plugins_in_modules.html#details -- Dominic Cleal Red Hat Engineering -- 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+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.