Error : Import Template Vcenter (Opennebula 5.4)

Please take into account that the path to the VMDK in the datastore cannot have spaces at well, is that the case?

My vCenter is hosted by a tier . I’m not able to confirm that the full path is without spaces …

Hi Tino,

i got the information:

Here the full path of my VMDK template :

/vmfs/volumes/24c09254-03888e94/ubuntu-template-context/ubuntu-template-context-000001.vmdk

no spaces as well

Hi Tino,

I tried with vOneCloud appliance and GUI import template . Same error.

Is it in a regular datastore? or it in a VApp?

it is a NFS Datastore.

it worked well on 5.2 version

i try in a new “Ressource Pool”

same error

Hello Team ,
For information , i tried the new vOneCloud release 3.0.2 and got the same error … :cry:

Could you paste the error message again? Most likely the lines have changed. Thanks.

Here is :

There was an error trying to create an image for disk in vcenter template. Reason: undefined method _ref' for nil:NilClass ["/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:240:inblock in import_vcenter_disks’", “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:239:in each'", "/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:239:inimport_vcenter_disks’”, “/usr/lib/one/sunstone/routes/vcenter.rb:338:in block in '", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1611:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1611:in block in compile!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in[]’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in block (3 levels) in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:994:inroute_eval’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in block (2 levels) in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1015:inblock in process_route’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1013:in catch'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1013:inprocess_route’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:973:in block in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:972:ineach’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:972:in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1085:inblock in dispatch!’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in block in invoke'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:incatch’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in invoke'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1082:indispatch!’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:907:in block in call!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:inblock in invoke’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in catch'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:ininvoke’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:907:in call!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:895:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/commonlogger.rb:33:in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:219:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/deflater.rb:35:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/session/abstract/id.rb:225:incontext’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/session/abstract/id.rb:220:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/xss_header.rb:18:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/path_traversal.rb:16:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/json_csrf.rb:18:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/frame_options.rb:31:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/nulllogger.rb:9:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/head.rb:13:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/methodoverride.rb:22:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:182:in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:2013:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1487:in block in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1787:insynchronize’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1487:in call'", "/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/rack/thread_handler_extension.rb:97:inprocess_request’”, “/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb:152:in accept_and_process_next_request'", "/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb:113:inmain_loop’”, “/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/request_handler.rb:416:in block (3 levels) in start_threads'", "/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/utils.rb:113:inblock in create_thread_and_abort_on_exception’”]

Thanks !

I am seeing the same thing here… started a new thread/issue last night.

has anyone found a workaround for this?

No workaround for me

Could you replace the /usr/lib/one/ruby/vcenter_driver/virtual_machine.rb with the following file:

https://github.com/OpenNebula/one/blob/master/src/vmm_mad/remotes/lib/vcenter_driver/virtual_machine.rb

and let us know if it works, or what error messages it produces

Thanks Tino,

i could test next week.

I will keep you posted

I’ll see if I can test this this week/weekend.

Hello,

I got a global error:

here is HTTP error

App 1971 stdout:
[ E 2017-10-09 16:07:10.8906 1324/Te age/Cor/App/Implementation.cpp:304 ]: Could not spawn process for application /usr/lib/one/sunst
one: An error occurred while starting up the preloader.
Error ID: 8105d99b
Error details saved to: /tmp/passenger-error-sPpeHv.html
Message from application: /usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:7: syntax error, unexpected ‘<’

^
/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:8: syntax error, unexpected ‘<’

^ /usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:9: syntax error, unexpected '<' ^ /usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:11: syntax error, unexpected '<' ^ /usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:11: syntax error, unexpected tIDENTIFIER, expecting end-of-input ^ (SyntaxError) /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/lib/one/ruby/vcenter_driver.rb:57:in `' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/lib/one/sunstone/routes/vcenter.rb:28:in `' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/lib/one/sunstone/sunstone-server.rb:442:in `block in ' /usr/lib/one/sunstone/sunstone-server.rb:441:in `each' /usr/lib/one/sunstone/sunstone-server.rb:441:in `' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require' config.ru:9:in `block in ' /usr/local/share/gems/gems/rack-1.6.4/lib/rack/builder.rb:55:in `instance_eval' /usr/local/share/gems/gems/rack-1.6.4/lib/rack/builder.rb:55:in `initialize' config.ru:1:in `new' config.ru:1:in `' /usr/local/share/gems/gems/passenger-5.1.8/src/helper-scripts/rack-preloader.rb:110:in `eval' /usr/local/share/gems/gems/passenger-5.1.8/src/helper-scripts/rack-preloader.rb:110:in `preload_app' /usr/local/share/gems/gems/passenger-5.1.8/src/helper-scripts/rack-preloader.rb:156:in `' /usr/local/share/gems/gems/passenger-5.1.8/src/helper-scripts/rack-preloader.rb:30:in `' /usr/local/share/gems/gems/passenger-5.1.8/src/helper-scripts/rack-preloader.rb:29:in `'

I use vOneCloud 3.0.2

Thanks !

Ruby is complaining about a syntax error, which doesn’t show up in our tests. Could you check that the file in your filesystem and the one in github are indeed the same one?

I get the following error with 5.4.1 and the replaced file

There was an error trying to create an image for disk in vcenter template. Reason: ManagedObjectNotFound: The object ‘vim.VirtualMachine:undefined’ has already been deleted or has not been completely created ["/usr/lib/one/ruby/vendors/rbvmomi/lib/rbvmomi/connection.rb:61:in parse_response'", "/usr/lib/one/ruby/vendors/rbvmomi/lib/rbvmomi/connection.rb:90:incall’", “/usr/lib/one/ruby/vendors/rbvmomi/lib/rbvmomi/basic_types.rb:211:in _call'", "/usr/lib/one/ruby/vendors/rbvmomi/lib/rbvmomi/basic_types.rb:74:inblock (2 levels) in init’”, “/usr/lib/one/ruby/vendors/rbvmomi/lib/rbvmomi/basic_types.rb:189:in _get_property'", "/usr/lib/one/ruby/vendors/rbvmomi/lib/rbvmomi/basic_types.rb:35:inblock (2 levels) in init’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:78:in get_dc'", "/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:230:inimport_vcenter_disks’”, “/usr/lib/one/sunstone/routes/vcenter.rb:338:in block in '", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1611:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1611:in block in compile!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in[]’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in block (3 levels) in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:994:inroute_eval’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in block (2 levels) in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1015:inblock in process_route’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1013:in catch'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1013:inprocess_route’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:973:in block in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:972:ineach’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:972:in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1085:inblock in dispatch!’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in block in invoke'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:incatch’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in invoke'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1082:indispatch!’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:907:in block in call!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:inblock in invoke’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in catch'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:ininvoke’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:907:in call!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:895:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/commonlogger.rb:33:in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:219:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/deflater.rb:35:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/session/abstract/id.rb:225:incontext’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/session/abstract/id.rb:220:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/xss_header.rb:18:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/path_traversal.rb:16:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/json_csrf.rb:18:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/frame_options.rb:31:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/nulllogger.rb:9:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/head.rb:13:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/methodoverride.rb:22:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/show_exceptions.rb:25:in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:182:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:2013:in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1487:inblock in call’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1787:in synchronize'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1487:incall’”, “/usr/local/share/gems/gems/thin-1.7.0/lib/thin/connection.rb:86:in block in pre_process'", "/usr/local/share/gems/gems/thin-1.7.0/lib/thin/connection.rb:84:incatch’”, “/usr/local/share/gems/gems/thin-1.7.0/lib/thin/connection.rb:84:in pre_process'", "/usr/local/share/gems/gems/thin-1.7.0/lib/thin/connection.rb:50:inblock in process’”, “/usr/local/share/gems/gems/eventmachine-1.2.0.1/lib/eventmachine.rb:1076:in call'", "/usr/local/share/gems/gems/eventmachine-1.2.0.1/lib/eventmachine.rb:1076:inblock in spawn_threadpool’”]

I do the test. I got the same error :
There was an error trying to create an image for disk in vcenter template. Reason: undefined method _ref' for nil:NilClass ["/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:247:inblock in import_vcenter_disks’", “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:246:in each'", "/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:246:inimport_vcenter_disks’”, “/usr/lib/one/sunstone/routes/vcenter.rb:338:in block in '", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1611:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1611:in block in compile!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in[]’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in block (3 levels) in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:994:inroute_eval’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:975:in block (2 levels) in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1015:inblock in process_route’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1013:in catch'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1013:inprocess_route’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:973:in block in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:972:ineach’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:972:in route!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1085:inblock in dispatch!’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in block in invoke'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:incatch’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in invoke'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1082:indispatch!’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:907:in block in call!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:inblock in invoke’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:in catch'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1067:ininvoke’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:907:in call!'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:895:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/commonlogger.rb:33:in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:219:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/deflater.rb:35:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/session/abstract/id.rb:225:incontext’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/session/abstract/id.rb:220:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/xss_header.rb:18:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/path_traversal.rb:16:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/json_csrf.rb:18:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in call'", "/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:incall’”, “/usr/local/share/gems/gems/rack-protection-1.5.3/lib/rack/protection/frame_options.rb:31:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/nulllogger.rb:9:incall’”, “/usr/local/share/gems/gems/rack-1.6.4/lib/rack/head.rb:13:in call'", "/usr/local/share/gems/gems/rack-1.6.4/lib/rack/methodoverride.rb:22:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:182:in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:2013:incall’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1487:in block in call'", "/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1787:insynchronize’”, “/usr/local/share/gems/gems/sinatra-1.4.7/lib/sinatra/base.rb:1487:in call'", "/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/rack/thread_handler_extension.rb:97:inprocess_request’”, “/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb:152:in accept_and_process_next_request'", "/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb:113:inmain_loop’”, “/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/request_handler.rb:416:in block (3 levels) in start_threads'", "/usr/local/share/gems/gems/passenger-5.1.8/src/ruby_supportlib/phusion_passenger/utils.rb:113:inblock in create_thread_and_abort_on_exception’”]