Ask Your Question

Heat - Create volume and launch instance from it.

asked 2014-06-18 04:13:00 -0500

Dutchak Vitaly gravatar image

I was trying to write heat template for launch instance from volume, but no succseed.


heat_template_version: 2013-05-23
description: Test Template
    type: string
    description: Image use to boot a server
    type: string
    description: Network ID for the server
    type: OS::Nova::Server
    depends_on: volume1
      name: "Ubuntu Node 01"
      block_device_mapping: [{ device_name: "vda", volume_id : { get_resource : volume1 }, delete_on_termination : "true" }]
      flavor: "m1.medium"
      - network: { get_param: NetID }
    type: OS::Cinder::Volume
      name  : "Server 1 - Root Disk"
      image : {"Ref": "ImageID"}
      size  : 1

Volume is created successfully, but instance not launched. For cinder volumes I use ceph backend.

In nova-compute log I was found this:

2014-06-18 12:58:49.552 31072 ERROR nova.virt.libvirt.driver [req-d66607c6-f097-454a-8aa1-1bd2383f5b38 98f22128a93b43af852b1e74ad1b39fe ee376c5145c949b197b6143fdaa32f61] An error occurred while trying to launch a defined domain with xml: <domain type='qemu'>

2014-06-18 12:58:49.553 31072 ERROR nova.compute.manager [req-d66607c6-f097-454a-8aa1-1bd2383f5b38 98f22128a93b43af852b1e74ad1b39fe ee376c5145c949b197b6143fdaa32f61] [instance: 1b1d122b-768e-4964-bd1e-a94613e3691d] Instance failed to spawn

2014-06-18 12:58:50.406 31072 ERROR nova.compute.manager [req-d66607c6-f097-454a-8aa1-1bd2383f5b38 98f22128a93b43af852b1e74ad1b39fe ee376c5145c949b197b6143fdaa32f61] [instance: 1b1d122b-768e-4964-bd1e-a94613e3691d] Error: internal error: process exited while connecting to monitor: qemu-system-x86_64: -drive file=rbd:volumes/1b1d122b-768e-4964-bd1e-a94613e3691d_disk:id=volumes:key=AQCGnJZTKPs5LxAARs2m0WuYCnSSaSnZiwvbGA==:auth_supported=cephx\;none:mon_host=\:6789\;\:6789\;\:6789,if=none,id=drive-virtio-disk0,format=raw,cache=none: error reading header from 1b1d122b-768e-4964-bd1e-a94613e3691d_disk
edit retag flag offensive close merge delete



Your template looks OK (although get_param is preferable to Ref in a HOT template). Have you tried this setup using the Nova and Cinder APIs directly? It seems likely that the problem may not be in Heat.

zaneb gravatar imagezaneb ( 2014-06-19 14:44:41 -0500 )edit

What hypervisor are you running on your system ? What OS are you running on your compute node? As zaneb ask. Can you make an instance without Heat?

TheKid-89 gravatar imageTheKid-89 ( 2014-09-12 01:25:59 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2015-09-24 16:27:45 -0500

Steve Baker gravatar image

You may need to be running at least Kilo Heat so that you can use the block_device_mapping_v2 property instead of the block_device_mapping property which has the same limitations as the deprecated block_device_mapping nova boot REST API.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools



Asked: 2014-06-18 04:13:00 -0500

Seen: 4,215 times

Last updated: Sep 24 '15