On 31/07/12 19:16, Jake - USPS wrote: > Try something like the following instead (added 'incl' and 'lens' and > removed context as its default based on incl is what you had) : > > augeas { 'homeLV': > incl => '/etc/fstab', > lens => 'Fstab.lns', > changes => [ > 'set *[file = "/home"]/dump 0', > 'set *[file = "/home"]/passno 0', > ], > onlyif => 'match *[file = "/home"] size > 0', > } > > I think this helps augeas not autoload everything it can possibly edit > and narrows it in on just one file.
Exactly: Augeas loads all files with all lenses it knows about by default as it doesn't know ahead of time which commands/paths you'll use. In Puppet 3.0, there's an optimisation in the provider (issue #7285) that will use the "context" parameter (optional, but usually specified) to only load lenses that are applicable to that context. Hopefully you'll see the same drastic reduction in runtime out of the box in the near future. -- Dominic Cleal Red Hat Consulting m: +44 (0)7817 878113 -- 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.