Ask Your Question
1

nova launch instance does not use volume from cinder

asked 2014-05-23 05:32:24 -0500

sudarshan gravatar image

Hi,

I have deployed 3 node openstack with neutron. everything is working fine but i when i launch an instance the root volume is created under /var/lib/nova/instances directory & it doesnt use cinder to create this volume.

i want to configure this such that when i launch an instance a volume has to be created by cinder according to the size specified in the flavor and it has to be attached to the instance.

cinder volumes is configured with netapp drivers & a volume is mounted using nfs. i can attach cinder volume as secondary disk to the instance, but how to make nova to call cinder to create the root volume as well during the lauch of the new instance.

Plz help. let me know if you need any other details.

nova.conf from my compute node [

default]
dhcpbridge_flagfile=/etc/nova/nova.conf
dhcpbridge=/usr/bin/nova-dhcpbridge
logdir=/var/log/nova
state_path=/var/lib/nova
lock_path=/var/lock/nova
force_dhcp_release=True
iscsi_helper=tgtadm
libvirt_use_virtio_for_bridges=True
connection_type=libvirt
root_helper=sudo nova-rootwrap /etc/nova/rootwrap.conf
verbose=True
ec2_private_dns_show_ip=True
api_paste_config=/etc/nova/api-paste.ini
volumes_path=/var/lib/nova/volumes
enabled_apis=ec2,osapi_compute,metadata

rpc_backend = rabbit
rabbit_host = heos-ctrls
rabbit_password = Heosadm1n
my_ip = 10.126.58.18
vnc_enabled = True
vncserver_listen = 0.0.0.0
vncserver_proxyclient_address = 10.126.58.18
novncproxy_base_url = http://heos-ctrls:6080/vnc_auto.html

network_api_class = nova.network.neutronv2.api.API
neutron_url = http://heos-ctrls:9696
neutron_auth_strategy = keystone
neutron_admin_tenant_name = service
neutron_admin_username = neutron
neutron_admin_password = Heosadm1n
neutron_admin_auth_url = http://heos-ctrls:35357/v2.0
linuxnet_interface_driver = nova.network.linux_net.LinuxOVSInterfaceDriver
firewall_driver = nova.virt.firewall.NoopFirewallDriver
security_group_api = neutron

instance_usage_audit = True
instance_usage_audit_period = hour
notify_on_state_change = vm_and_task_state
notification_driver = nova.openstack.common.notifier.rpc_notifier
notification_driver = ceilometer.compute.nova_notifier

[database]
# The SQLAlchemy connection string used to connect to the database
connection = mysql://nova:Heosadm1n@heos-ctrls/nova

[keystone_authtoken]
auth_uri = http://heos-ctrls:5000
auth_host = heos-ctrls
auth_port = 35357
auth_protocol = http
admin_tenant_name = service
admin_user = nova
admin_password = Heosadm1n
edit retag flag offensive close merge delete

Comments

If I understand your requirement correctly, you need to create a bootable volume and boot an instance out of that volume (instead of an image). This will ensure that the volume becomes the root disk; and will also prevent nova from creating a root disk for the instance in /var/lib/nova/instances.

unmesh-gurjar gravatar imageunmesh-gurjar ( 2014-05-26 01:26:02 -0500 )edit

some thing similar.

i want to use qcow2 as image and launch instance should create volume using cinder.

currently boot volumes are created at /var/lib/nova/instances i need them to be created under /var/lib/cinder/mnt

so that i can see those volumes under volumes tab from horizon and the volume usage will also get updated accordingly.

currnet usage limit show zero volume usage even if i have create multiple instances with around 100Gb space. because boot volumes are creatd under /var/lib/nova/instances

sudarshan gravatar imagesudarshan ( 2014-05-28 05:35:38 -0500 )edit

2 answers

Sort by ยป oldest newest most voted
0

answered 2014-06-25 22:47:31 -0500

madhu_CC gravatar image

updated 2014-06-25 23:20:00 -0500

You should configure the Cinder to consume Volume from a storage vendor(3par,netapp etc.,) and then disable the availability zone as below.

Remark below lines: availability zone of this node (string value) storage_availability_zone=nova

Then use the LVM as storage provider. Ensure you configure the LVM in your hosting server.

Regards

edit flag offensive delete link more
0

answered 2014-06-26 00:17:55 -0500

mpetason gravatar image

This will be relevant:

http://docs.openstack.org/user-guide/...

You need to boot an instance from a volume, but have the volume be created and specify the image you are using. You can do this easily through Horizon or use the command line interface. In Horizon you would create a volume from an image and boot the instance on it.

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

Stats

Asked: 2014-05-23 05:32:24 -0500

Seen: 2,280 times

Last updated: Jun 26 '14