extlookup not working correctly in 2.7.6

141 views
Skip to first unread message

Jason Koppe

unread,
Oct 24, 2011, 7:04:03 PM10/24/11
to Puppet Users
I'm trying to upgrade from 2.6.7 to to 2.7.6 and I'm running into an
issue in my extlookup() calls. A lot of the variables which should be
defined aren't defined within extlookup.rb. I've tested 2.6.7 agent
and 2.7.5 agent against the 2.6.7 master and 2.7.6 master. I adjusted
extlookup.rb slightly to provide some debug output.

http://pastie.org/private/jsmyxrfhggcvflxcioibq shows:
* my 2.7.5 puppet agent failure when run against the 2.7.6 puppet
master
* git diff of extlookup.rb in the 2.7.6 branch
* debug extlookup log output from the 2.7.6 master
* debug extlookup log output from the 2.6.7 master
* extlookup precedence set in site.pp

The same manifests/extlookup configuration work on the "newpuppet"
environment when using a 2.6.7 agent against the 2.6.7 master.

Jason Koppe

unread,
Oct 24, 2011, 7:10:16 PM10/24/11
to Puppet Users
I diff'd the extlookup.rb between 2.6.7 and 2.7.6 and noticed this was
different, so I changed it back and things are working again:

--> git diff ./lib/puppet/parser/functions/extlookup.rb
diff --git a/lib/puppet/parser/functions/extlookup.rb b/lib/puppet/
parser/functions/extlookup.rb
index 5fbf26c..818f7c7 100644
--- a/lib/puppet/parser/functions/extlookup.rb
+++ b/lib/puppet/parser/functions/extlookup.rb
@@ -93,7 +93,7 @@ This is for back compatibility to interpolate
variables with %. % interpolation

extlookup_datadir = undef_as('',lookupvar('::extlookup_datadir'))

- extlookup_precedence =
undef_as([],lookupvar('::extlookup_precedence')).collect { |var|
var.gsub(/%\{(.+?)\}/) { lookupvar("::#{$1}") } }
+ extlookup_precedence =
undef_as([],lookupvar('::extlookup_precedence')).collect { |var|
var.gsub(/%\{(.+?)\}/) { lookupvar($1) } }

datafiles = Array.new

R.I.Pienaar

unread,
Oct 24, 2011, 7:10:15 PM10/24/11
to puppet...@googlegroups.com

Jason Koppe

unread,
Oct 24, 2011, 7:23:01 PM10/24/11
to Puppet Users
looks like that's it. i'll use the workaround nigel recommended in
that issue (same as my diff above) until that issue is resolved.

thanks for the quick response, R.I.!
Reply all
Reply to author
Forward
0 new messages