Closed athak closed 11 years ago
Run the command with --trace. I'm guessing we need to change to how the shared lib is loaded to accomodate apply vs. agent as well as difference between 2.7 v.s. 3.0/3.1 similar to https://github.com/puppetlabs/puppetlabs-mount_providers/blob/master/lib/puppet/provider/mountpoint/linux.rb#L3-L10.
Hi Nan, thanks for the prompt reply. This is the output with --trace:
vma:/var/lib/puppet/state # puppet agent --no-daemonize --onetime --verbose --trace
Info: Retrieving plugin
Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb
Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb
Info: Loading facts in /var/lib/puppet/lib/facter/pe_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not autoload puppet/type/vcsa_eula: Could not autoload puppet/provider/vcsa_eula/default: undefined method path' for nil:NilClass on node vma.athak.local /usr/lib64/ruby/vendor_ruby/1.8/puppet/indirector/rest.rb:65:in
deserialize'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/indirector/rest.rb:121:in find' /usr/lib64/ruby/vendor_ruby/1.8/puppet/indirector/indirection.rb:191:in
find'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/configurer.rb:243:in retrieve_new_catalog' /usr/lib64/ruby/vendor_ruby/1.8/puppet/util.rb:351:in
thinmark'
/usr/lib64/ruby/1.8/benchmark.rb:308:in realtime' /usr/lib64/ruby/vendor_ruby/1.8/puppet/util.rb:350:in
thinmark'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/configurer.rb:242:in retrieve_new_catalog' /usr/lib64/ruby/vendor_ruby/1.8/puppet/configurer.rb:67:in
retrieve_catalog'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/configurer.rb:107:in prepare_and_retrieve_catalog' /usr/lib64/ruby/vendor_ruby/1.8/puppet/configurer.rb:159:in
run'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:45:in run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/agent/locker.rb:20:in
lock'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:45:in run' /usr/lib64/ruby/1.8/sync.rb:230:in
synchronize'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:45:in run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:119:in
with_client'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:42:in run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:84:in
run_in_fork'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:41:in run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/application.rb:179:in
call'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/application.rb:179:in controlled_run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/agent.rb:39:in
run'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/application/agent.rb:338:in onetime' /usr/lib64/ruby/vendor_ruby/1.8/puppet/application/agent.rb:312:in
run_command'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/application.rb:364:in run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/application.rb:456:in
plugin_hook'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/application.rb:364:in run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/util.rb:504:in
exit_on_fail'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/application.rb:364:in run' /usr/lib64/ruby/vendor_ruby/1.8/puppet/util/command_line.rb:132:in
run'
/usr/lib64/ruby/vendor_ruby/1.8/puppet/util/command_line.rb:86:in `execute'
/usr/bin/puppet:4
Notice: Using cached catalog
Info: Applying configuration version '1362455187'
Notice: Finished catalog run in 0.03 seconds
Cheers, Atha
Can you test this branch and see if it resolves the loading issue: https://github.com/nanliu/vmware-vcsa/tree/loadpath (I was able to test 2.7/3.1 with apply and I'm loading a 2.7 agent to test agent/master on 2.7.)
Is your repo private? I am not able to access it.
It was, it's public now.
Hi Nan, it seems to be working now!
vma:/var/lib/puppet/state # puppet agent --no-daemonize --onetime --verbose --trace Info: Retrieving plugin Notice: /File[/var/lib/puppet/lib/puppet/provider/vcsa.rb]/content: content changed '{md5}50c777ac817b71e45003b553cbbfa219' to '{md5}ac30421d41c333fa5a49dd6270447162' Notice: /File[/var/lib/puppet/lib/puppet_x/vmware/util.rb]/content: content changed '{md5}3b7253e6ec8c6eba8cb69dbd56a5abef' to '{md5}b6bfda1bb9c1515dac0da90e3bf60b02' Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb Info: Loading facts in /var/lib/puppet/lib/facter/pe_version.rb Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb Info: Caching catalog for vma.athak.local Info: Applying configuration version '1362502129' Notice: Finished catalog run in 4.11 seconds
I did have to install the net-ssh gem. I'll try to submit a patch for that.
Best, Atha
net-ssh gem is part of class { 'vcenter::package': }. In this case might make sense to make vcsa::package (maybe use ensure_package or ensure_resource from stdlib). I'll put the pull request in a short bit for all the modules (you'll run into the same issue with vcenter/vshield).
Hi, I'm trying to test the module but this is what I get:
Could not autoload puppet/type/vcsa_eula: Could not autoload puppet/provider/vcsa_eula/default: undefined method `path' for nil:NilClass
Depending on the run I get the same message for all the other vcsa providers, vcsa_db, vcsa_sso, vcsa_java, vcsa_service.
Puppet version is 3.1.0 on both the master and agent. Master us Ubuntu 12.04 and agent is SLES 11 (VMware Management Assistant).
Cheers, Atha