← Back to team overview

openstack team mailing list archive

Re: Boot from volume invalid device name /dev/vda

 

Yup, that's it. I'll fix the default in Horizon.

I owe you a beer at the Folsom summit Cole. :)

On Jan 22, 2012, at 9:59 AM, Cole Robinson wrote:

> On 01/21/2012 01:04 PM, Tres Henry wrote:
>> Getting an error trying to boot an instance from volume (the following is the
>> traceback from nova compute):
>> 
>> (nova.rpc): TRACE: Traceback (most recent call last):
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/rpc/impl_kombu.py", line 723,
>> in _process_data
>> (nova.rpc): TRACE:     rval = node_func(context=ctxt, **node_args)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/exception.py", line 126, in
>> wrapped
>> (nova.rpc): TRACE:     return f(*args, **kw)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/compute/manager.py", line 150,
>> in decorated_function
>> (nova.rpc): TRACE:     self.add_instance_fault_from_exc(context, instance_uuid, e)
>> (nova.rpc): TRACE:   File "/usr/lib/python2.7/contextlib.py", line 24, in __exit__
>> (nova.rpc): TRACE:     self.gen.next()
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/compute/manager.py", line 145,
>> in decorated_function
>> (nova.rpc): TRACE:     return function(self, context, instance_uuid, *args,
>> **kwargs)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/compute/manager.py", line 565,
>> in run_instance
>> (nova.rpc): TRACE:     self._run_instance(context, instance_uuid, **kwargs)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/compute/manager.py", line 394,
>> in _run_instance
>> (nova.rpc): TRACE:     vm_state=vm_states.ERROR)
>> (nova.rpc): TRACE:   File "/usr/lib/python2.7/contextlib.py", line 24, in __exit__
>> (nova.rpc): TRACE:     self.gen.next()
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/compute/manager.py", line 381,
>> in _run_instance
>> (nova.rpc): TRACE:     self._deallocate_network(context, instance)
>> (nova.rpc): TRACE:   File "/usr/lib/python2.7/contextlib.py", line 24, in __exit__
>> (nova.rpc): TRACE:     self.gen.next()
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/compute/manager.py", line 378,
>> in _run_instance
>> (nova.rpc): TRACE:     injected_files, admin_password)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/compute/manager.py", line 511,
>> in _spawn
>> (nova.rpc): TRACE:     network_info, block_device_info)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/exception.py", line 126, in
>> wrapped
>> (nova.rpc): TRACE:     return f(*args, **kw)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/virt/libvirt/connection.py",
>> line 681, in spawn
>> (nova.rpc): TRACE:     domain = self._create_new_domain(xml)
>> (nova.rpc): TRACE:   File "/opt/stack/nova/nova/virt/libvirt/connection.py",
>> line 1255, in _create_new_domain
>> (nova.rpc): TRACE:     domain = self._conn.defineXML(xml)
>> (nova.rpc): TRACE:   File "/usr/lib/python2.7/dist-packages/libvirt.py", line
>> 1708, in defineXML
>> (nova.rpc): TRACE:     if ret is None:raise libvirtError('virDomainDefineXML()
>> failed', conn=self)
>> (nova.rpc): TRACE: libvirtError: internal error Invalid harddisk device name:
>> /dev/vda
>> (nova.rpc): TRACE:
>> 
>> The block_device_mapping supplied was {"/dev/vda": "1:::1"} which results in:
>> [{u'volume_size': u'', u'device_name': u'/dev/vda', u'delete_on_termination':
>> u'1', u'volume_id': u'1'}]), however I've tried about every combination of
>> values I can think of (supplying type, size, changing device name, etc.) with
>> the same result (although the error is "Invalid harddisk device name:
>> /dev/vdb" or whatever I supplied as the device name).
>> 
>> If it helps:
>> Running devstack @ af0f7cadb9
>> Tried to launch an instance with both the cirros default devstack image and
>> UEC oneiric x64.
>> The existing volume is larger than the image's ephemeral volume (not sure if
>> that matters).
>> 
>> What am I doing wrong?
>> 
> 
> I think libvirt is expecting a device name like 'vda' and not '/dev/vda', so
> try giving that a spin in block_device_mapping.
> 
> - Cole



References