Issue #22619 has been updated by Josh Cooper.

Description updated

----------------------------------------
Bug #22619: Error when NetConnectionId is missing on NetworkAdapter
https://projects.puppetlabs.com/issues/22619#change-97775

* Author: Rob Reynolds
* Status: Investigating
* Priority: Normal
* Assignee: Rob Reynolds
* Category: 
* Target version: 1.7.4
* Keywords: windows
* Branch: 
* Affected Facter version: 1.7.3
----------------------------------------
When someone has a network configuration that has IPEnabled set to true, it 
doesn't necessarily mean the Network Adapter behind it also has IPEnabled set 
to true. The latest release of facter (1.7.3) introduced a bug that causes 
puppet to error when gathering facts about the interfaces if someone has such a 
configuration on their system.

Output from WMI queries on an affected system:  

 - https://gist.github.com/anonymous/15c1e09eca5b7c42e29e
 - https://gist.github.com/anonymous/810f922a3a40bfbe863f

Match each of them up by Index (as we do here: 
https://github.com/puppetlabs/facter/blob/stable/lib/facter/util/ip/windows.rb#L46-L47
 )

 - Index=7 (Server_LAN)
 - Index=12 (Replication)
 - Index=14 (Backup-LAN)
 - Index=16 (no NetConnectionID) (the network config has IPEnabled, but the 
adapter does not)

The offender is "Microsoft Failover Cluster Virtual Adapter"

<pre>
C:\puppet\bin>puppet agent --test --debug --trace 
Error: Could not retrieve local facts: undefined method `gsub' for nil:NilClass
C:/puppet/facter/lib/facter/util/ip.rb:39:in `alphafy'
C:/puppet/facter/lib/facter/interfaces.rb:35:in `block (2 levels) in <top 
(required)>'
C:/puppet/facter/lib/facter/interfaces.rb:34:in `each'
C:/puppet/facter/lib/facter/interfaces.rb:34:in `block in <top (required)>'
C:/puppet/facter/lib/facter/interfaces.rb:29:in `each'
C:/puppet/facter/lib/facter/interfaces.rb:29:in `<top (required)>'
C:/puppet/facter/lib/facter/util/loader.rb:95:in `load'
C:/puppet/facter/lib/facter/util/loader.rb:95:in `load_file'
C:/puppet/facter/lib/facter/util/loader.rb:46:in `block (2 levels) in load_all'
C:/puppet/facter/lib/facter/util/loader.rb:41:in `each'
C:/puppet/facter/lib/facter/util/loader.rb:41:in `block in load_all'
C:/puppet/facter/lib/facter/util/loader.rb:38:in `each'
C:/puppet/facter/lib/facter/util/loader.rb:38:in `load_all'
C:/puppet/facter/lib/facter/util/collection.rb:114:in `load_all'
C:/puppet/facter/lib/facter.rb:248:in `loadfacts'
C:/puppet/puppet/lib/puppet/indirector/facts/facter.rb:11:in `reload_facter'
C:/puppet/puppet/lib/puppet/indirector/facts/facter.rb:53:in `find'
C:/puppet/puppet/lib/puppet/indirector/indirection.rb:197:in `find'
C:/puppet/puppet/lib/puppet/configurer/fact_handler.rb:15:in `find_facts'
C:/puppet/puppet/lib/puppet/configurer/fact_handler.rb:31:in 
`facts_for_uploading'
C:/puppet/puppet/lib/puppet/configurer.rb:101:in `get_facts'
C:/puppet/puppet/lib/puppet/configurer.rb:164:in `run'
C:/puppet/puppet/lib/puppet/agent.rb:45:in `block (5 levels) in run'
C:/puppet/puppet/lib/puppet/agent/locker.rb:20:in `lock'
C:/puppet/puppet/lib/puppet/agent.rb:45:in `block (4 levels) in run'
C:/puppet/sys/ruby/lib/ruby/1.9.1/sync.rb:227:in `sync_synchronize'
C:/puppet/puppet/lib/puppet/agent.rb:45:in `block (3 levels) in run'
C:/puppet/puppet/lib/puppet/agent.rb:119:in `with_client'
C:/puppet/puppet/lib/puppet/agent.rb:42:in `block (2 levels) in run'
C:/puppet/puppet/lib/puppet/agent.rb:84:in `run_in_fork'
C:/puppet/puppet/lib/puppet/agent.rb:41:in `block in run'
C:/puppet/puppet/lib/puppet/application.rb:179:in `call'
C:/puppet/puppet/lib/puppet/application.rb:179:in `controlled_run'
C:/puppet/puppet/lib/puppet/agent.rb:39:in `run'
C:/puppet/puppet/lib/puppet/application/agent.rb:360:in `onetime'
C:/puppet/puppet/lib/puppet/application/agent.rb:326:in `run_command'
C:/puppet/puppet/lib/puppet/application.rb:364:in `block (2 levels) in run'
C:/puppet/puppet/lib/puppet/application.rb:457:in `plugin_hook'
C:/puppet/puppet/lib/puppet/application.rb:364:in `block in run'
C:/puppet/puppet/lib/puppet/util.rb:511:in `exit_on_fail'
C:/puppet/puppet/lib/puppet/application.rb:364:in `run'
C:/puppet/puppet/lib/puppet/util/command_line.rb:132:in `run'
C:/puppet/puppet/lib/puppet/util/command_line.rb:86:in `execute'
C:/puppet/puppet/bin/puppet:4:in `&lt;main>'
Error: Failed to apply catalog: Could not retrieve local facts: undefined 
method `gsub' for nil:NilClass
C:/puppet/puppet/lib/puppet/configurer/fact_handler.rb:26:in `rescue in 
find_facts'
C:/puppet/puppet/lib/puppet/configurer/fact_handler.rb:14:in `find_facts'
C:/puppet/puppet/lib/puppet/configurer/fact_handler.rb:31:in 
`facts_for_uploading'
C:/puppet/puppet/lib/puppet/configurer.rb:101:in `get_facts'
C:/puppet/puppet/lib/puppet/configurer.rb:164:in `run'
C:/puppet/puppet/lib/puppet/agent.rb:45:in `block (5 levels) in run'
C:/puppet/puppet/lib/puppet/agent/locker.rb:20:in `lock'
C:/puppet/puppet/lib/puppet/agent.rb:45:in `block (4 levels) in run'
C:/puppet/sys/ruby/lib/ruby/1.9.1/sync.rb:227:in `sync_synchronize'
C:/puppet/puppet/lib/puppet/agent.rb:45:in `block (3 levels) in run'
C:/puppet/puppet/lib/puppet/agent.rb:119:in `with_client'
C:/puppet/puppet/lib/puppet/agent.rb:42:in `block (2 levels) in run'
C:/puppet/puppet/lib/puppet/agent.rb:84:in `run_in_fork'
C:/puppet/puppet/lib/puppet/agent.rb:41:in `block in run'
C:/puppet/puppet/lib/puppet/application.rb:179:in `call'
C:/puppet/puppet/lib/puppet/application.rb:179:in `controlled_run'
C:/puppet/puppet/lib/puppet/agent.rb:39:in `run'
C:/puppet/puppet/lib/puppet/application/agent.rb:360:in `onetime'
C:/puppet/puppet/lib/puppet/application/agent.rb:326:in `run_command'
C:/puppet/puppet/lib/puppet/application.rb:364:in `block (2 levels) in run'
C:/puppet/puppet/lib/puppet/application.rb:457:in `plugin_hook'
C:/puppet/puppet/lib/puppet/application.rb:364:in `block in run'
C:/puppet/puppet/lib/puppet/util.rb:511:in `exit_on_fail'
C:/puppet/puppet/lib/puppet/application.rb:364:in `run'
C:/puppet/puppet/lib/puppet/util/command_line.rb:132:in `run'
C:/puppet/puppet/lib/puppet/util/command_line.rb:86:in `execute'
C:/puppet/puppet/bin/puppet:4:in `&lt;main>'
</pre>


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to