# Revision history [back]

### How to set cinder multi-backend default

I am testing a Havana cinder multi-backend setup with two Ceph backends (volumes-hdd and volumes-ssd) and two types:

• Regular, linked to volume_backend_name "volumes-hdd"
• Gold, linked to volume_backend_name "volumes-ssd"

This works well and running cinder create from the command line with the --volume-type parameter or selecting a type in the Create Volume form in the Horizon dashboard allows me to create volumes in either backend.

Turns out that if I don't provide a volume type preference then cinder will automatically create the volume in volumes-ssd. I'm assumning it's because that's the first backend in cinder.conf. Of course in this use case I don't want volumes without the type specified to be distributed evenly accross backends. In stead I want the volumes-hdd backend to always be the default backend for all volumes created without type being specified. I've had no luck adding "default_volume_type=volumes-hdd" or "default_volume_type=Regular" to the cinder.conf [DEFAULT] section but that didn't seem to do the trick.

So how do I set which "default backend" to use in case no volume type is provided?

### How to set cinder multi-backend default

I am testing a Havana cinder multi-backend setup with two Ceph backends (volumes-hdd and volumes-ssd) and two types:

• Regular, linked to volume_backend_name "volumes-hdd"
• Gold, linked to volume_backend_name "volumes-ssd"

This works well and running cinder create from the command line with the --volume-type parameter or selecting a type in the Create Volume form in the Horizon dashboard allows me to create volumes in either backend.

Turns out that if I don't provide a volume type preference then cinder will automatically create the volume in volumes-ssd. I'm assumning it's because that's the first backend in cinder.conf. Of course in this use case I don't want volumes without the type specified to be distributed evenly accross backends. In stead I want the volumes-hdd backend to always be the default backend for all volumes created without type being specified. I've had no luck adding "default_volume_type=volumes-hdd" or "default_volume_type=Regular" to the cinder.conf [DEFAULT] section but that didn't seem to do the trick.trick. I've added my puppet-generated cinder.conf below.

So how do I set which "default backend" to use in case no volume type is provided?

[DEFAULT]
rootwrap_config = /etc/cinder/rootwrap.conf
api_paste_confg = /etc/cinder/api-paste.ini
volume_name_template = volume-%s
volume_group = cinder-volumes
verbose = False
auth_strategy = keystone
state_path = /var/lib/cinder
lock_path = /var/lock/cinder
volumes_dir = /var/lib/cinder/volumes
rabbit_host=127.0.0.1
backup_ceph_user=cinder
backup_ceph_conf=/etc/ceph/ceph.conf
use_syslog=False
api_paste_config=/etc/cinder/api-paste.ini
enabled_backends=volumes-hdd,volumes-ssd
backup_ceph_chunk_size=134217728
backup_driver=cinder.backup.driver.ceph
backup_ceph_stripe_unit=0
debug=False
rabbit_userid=openstack
log_dir=/var/log/cinder
osapi_volume_listen=0.0.0.0
backup_ceph_stripe_count=0
backup_ceph_pool=backups
sql_idle_timeout=3600
rabbit_virtual_host=/
scheduler_driver=cinder.scheduler.filter_scheduler.FilterScheduler
rabbit_hosts=127.0.0.1:5672
control_exchange=openstack
rabbit_ha_queues=False
rabbit_port=5672
rpc_backend=cinder.openstack.common.rpc.impl_kombu

[volumes-hdd]
rbd_pool=volumes-regular
volume_driver=cinder.volume.drivers.rbd.RBDDriver
rbd_flatten_volume_from_snapshot=False
rbd_max_clone_depth=5
rbd_user=cinder
volume_backend_name=volumes-hdd
rbd_ceph_conf=/etc/ceph/ceph.conf

[volumes-ssd]
rbd_user=cinder
volume_driver=cinder.volume.drivers.rbd.RBDDriver
rbd_max_clone_depth=5
rbd_pool=volumes-performance
rbd_ceph_conf=/etc/ceph/ceph.conf
rbd_flatten_volume_from_snapshot=False
volume_backend_name=volumes-ssd

 3 retagged dachary 291 ●6 ●11 ●20

### How to set cinder multi-backend default

I am testing a Havana cinder multi-backend setup with two Ceph backends (volumes-hdd and volumes-ssd) and two types:

• Regular, linked to volume_backend_name "volumes-hdd"
• Gold, linked to volume_backend_name "volumes-ssd"

This works well and running cinder create from the command line with the --volume-type parameter or selecting a type in the Create Volume form in the Horizon dashboard allows me to create volumes in either backend.

Turns out that if I don't provide a volume type preference then cinder will automatically create the volume in volumes-ssd. I'm assumning it's because that's the first backend in cinder.conf. Of course in this use case I don't want volumes without the type specified to be distributed evenly accross backends. In stead I want the volumes-hdd backend to always be the default backend for all volumes created without type being specified. I've had no luck adding "default_volume_type=volumes-hdd" or "default_volume_type=Regular" to the cinder.conf [DEFAULT] section but that didn't seem to do the trick. I've added my puppet-generated cinder.conf below.

So how do I set which "default backend" to use in case no volume type is provided?

[DEFAULT]
rootwrap_config = /etc/cinder/rootwrap.conf
api_paste_confg = /etc/cinder/api-paste.ini
volume_name_template = volume-%s
volume_group = cinder-volumes
verbose = False
auth_strategy = keystone
state_path = /var/lib/cinder
lock_path = /var/lock/cinder
volumes_dir = /var/lib/cinder/volumes
rabbit_host=127.0.0.1
backup_ceph_user=cinder
backup_ceph_conf=/etc/ceph/ceph.conf
use_syslog=False
api_paste_config=/etc/cinder/api-paste.ini
enabled_backends=volumes-hdd,volumes-ssd
backup_ceph_chunk_size=134217728
backup_driver=cinder.backup.driver.ceph
backup_ceph_stripe_unit=0
debug=False
rabbit_userid=openstack
log_dir=/var/log/cinder
osapi_volume_listen=0.0.0.0
backup_ceph_stripe_count=0
backup_ceph_pool=backups
sql_idle_timeout=3600
rabbit_virtual_host=/
scheduler_driver=cinder.scheduler.filter_scheduler.FilterScheduler
rabbit_hosts=127.0.0.1:5672
control_exchange=openstack
rabbit_ha_queues=False
rabbit_port=5672
rpc_backend=cinder.openstack.common.rpc.impl_kombu

[volumes-hdd]
rbd_pool=volumes-regular
volume_driver=cinder.volume.drivers.rbd.RBDDriver
rbd_flatten_volume_from_snapshot=False
rbd_max_clone_depth=5
rbd_user=cinder
volume_backend_name=volumes-hdd
rbd_ceph_conf=/etc/ceph/ceph.conf

[volumes-ssd]
rbd_user=cinder
volume_driver=cinder.volume.drivers.rbd.RBDDriver
rbd_max_clone_depth=5
rbd_pool=volumes-performance
rbd_ceph_conf=/etc/ceph/ceph.conf
rbd_flatten_volume_from_snapshot=False
volume_backend_name=volumes-ssd