Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

There will be significant changes in multi back end cinder architecture of RDO Juno running on CentOS 7 or Fedora 21 utilizing LVM based iSCSI targets. Create following entries in /etc/cinder/cinder.conf on Controller ( which in case of two node Cluster works as Storage node as well).

#################

enabled_backends=lvm51,lvm52

#

[lvm51] iscsi_helper=lioadm volume_group=cinder-volumes51 volume_driver=cinder.volume.drivers.lvm.LVMISCSIDriver iscsi_ip_address=192.168.1.127 volume_backend_name=LVM_iSCSI51

[lvm52] iscsi_helper=lioadm volume_group=cinder-volumes52 volume_driver=cinder.volume.drivers.lvm.LVMISCSIDriver iscsi_ip_address=192.168.1.127 volume_backend_name=LVM_iSCSI52

VG cinder-volumes52,51 created on /dev/sda6 and /dev/sdb1 correspondently :-

pvcreate /dev/sda6

pvcreate /dev/sdb1

vgcreate cinder-volumes52 /dev/sda6

vgcreate cinder-volumes51 /dev/sdb1

Then issue :-

[root@juno1 ~(keystone_admin)]# cinder type-create lvms +--------------------------------------+------+ | ID | Name | +--------------------------------------+------+ | 64414f3a-7770-4958-b422-8db0c3e2f433 | lvms | +--------------------------------------+------+

[root@juno1 ~(keystone_admin)]# cinder type-create lvmz +--------------------------------------+---------+ | ID | Name | +--------------------------------------+---------+ | 29917269-d73f-4c28-b295-59bfbda5d044 | lvmz |

+--------------------------------------+---------+

[root@juno1 ~(keystone_admin)]# cinder type-list +--------------------------------------+---------+ | ID | Name | +--------------------------------------+---------+ | 29917269-d73f-4c28-b295-59bfbda5d044 | lvmz | | 64414f3a-7770-4958-b422-8db0c3e2f433 | lvms | +--------------------------------------+---------+

[root@juno1 ~(keystone_admin)]# cinder type-key lvmz set volume_backend_name=LVM_iSCSI51

[root@juno1 ~(keystone_admin)]# cinder type-key lvms set volume_backend_name=LVM_iSCSI52

Then enable and start service target:-

[root@juno1 ~(keystone_admin)]# service target enable [root@juno1 ~(keystone_admin)]# service target start

[root@juno1 ~(keystone_admin)]# service target status Redirecting to /bin/systemctl status target.service target.service - Restore LIO kernel target configuration Loaded: loaded (/usr/lib/systemd/system/target.service; enabled) Active: active (exited) since Wed 2014-11-05 13:23:09 MSK; 44min ago Process: 1611 ExecStart=/usr/bin/targetctl restore (code=exited, status=0/SUCCESS) Main PID: 1611 (code=exited, status=0/SUCCESS) CGroup: /system.slice/target.service

juno1.localdomain systemd[1]: Starting Restore LIO kernel target configuration...

juno1.localdomain systemd[1]: Started Restore LIO kernel target configuration.

Now all changes done by creating cinder volumes of types lvms,lvmz ( via dashboard - volume create with dropdown menu volume types or via cinder CLI ) will be persistent in targetcli> ls output between reboots

[root@juno1 ~(keystone_boris)]# cinder list +--------------------------------------+--------+------------------+------+-------------+----------+--------------------------------------+ | ID | Status | Display Name | Size | Volume Type | Bootable | Attached to | +--------------------------------------+--------+-------

Reference: https://www.centos.org/forums/viewtopic.php?f=47&t=48591

click to hide/show revision 2
No.2 Revision

There will be significant changes in multi back end cinder architecture of RDO Juno running on CentOS 7 or Fedora 21 utilizing LVM based iSCSI targets. Create following entries in /etc/cinder/cinder.conf on Controller ( which in case of two node Cluster works as Storage node as well).

#################

enabled_backends=lvm51,lvm52

#

####################### 
enabled_backends=lvm51,lvm52
#######################

[lvm51]
iscsi_helper=lioadm
volume_group=cinder-volumes51
volume_driver=cinder.volume.drivers.lvm.LVMISCSIDriver
iscsi_ip_address=192.168.1.127
volume_backend_name=LVM_iSCSI51

volume_backend_name=LVM_iSCSI51 [lvm52] iscsi_helper=lioadm volume_group=cinder-volumes52 volume_driver=cinder.volume.drivers.lvm.LVMISCSIDriver iscsi_ip_address=192.168.1.127 volume_backend_name=LVM_iSCSI52

volume_backend_name=LVM_iSCSI52

VG cinder-volumes52,51 created on /dev/sda6 and /dev/sdb1 correspondently :-

# pvcreate /dev/sda6

/dev/sda6 # pvcreate /dev/sdb1

/dev/sdb1 # vgcreate cinder-volumes52 /dev/sda6

/dev/sda6 # vgcreate cinder-volumes51 /dev/sdb1

/dev/sdb1

Then issue :-

[root@juno1 ~(keystone_admin)]# cinder type-create lvms
+--------------------------------------+------+
|                  ID                  | Name |
+--------------------------------------+------+
| 64414f3a-7770-4958-b422-8db0c3e2f433 | lvms  |
+--------------------------------------+------+

+--------------------------------------+------+ [root@juno1 ~(keystone_admin)]# cinder type-create lvmz +--------------------------------------+---------+ | ID | Name | +--------------------------------------+---------+ | 29917269-d73f-4c28-b295-59bfbda5d044 | lvmz |

| +--------------------------------------+---------+

[root@juno1 ~(keystone_admin)]# cinder type-list +--------------------------------------+---------+ | ID | Name | +--------------------------------------+---------+ | 29917269-d73f-4c28-b295-59bfbda5d044 | lvmz | | 64414f3a-7770-4958-b422-8db0c3e2f433 | lvms | +--------------------------------------+---------+

+--------------------------------------+---------+ [root@juno1 ~(keystone_admin)]# cinder type-key lvmz set volume_backend_name=LVM_iSCSI51

volume_backend_name=LVM_iSCSI51 [root@juno1 ~(keystone_admin)]# cinder type-key lvms set volume_backend_name=LVM_iSCSI52

volume_backend_name=LVM_iSCSI52

Then enable and start service target:-

[root@juno1 ~(keystone_admin)]#   service target enable
 [root@juno1 ~(keystone_admin)]#   service target start

start [root@juno1 ~(keystone_admin)]# service target status Redirecting to /bin/systemctl status target.service target.service - Restore LIO kernel target configuration Loaded: loaded (/usr/lib/systemd/system/target.service; enabled) Active: active (exited) since Wed 2014-11-05 13:23:09 MSK; 44min ago Process: 1611 ExecStart=/usr/bin/targetctl restore (code=exited, status=0/SUCCESS) Main PID: 1611 (code=exited, status=0/SUCCESS) CGroup: /system.slice/target.service

/system.slice/target.service juno1.localdomain systemd[1]: Starting Restore LIO kernel target configuration...

configuration... juno1.localdomain systemd[1]: Started Restore LIO kernel target configuration.

configuration.

Now all changes done by creating cinder volumes of types lvms,lvmz ( via dashboard - volume create with dropdown menu volume types or via cinder CLI ) will be persistent in targetcli> ls output between reboots

[root@juno1 ~(keystone_boris)]# cinder list
+--------------------------------------+--------+------------------+------+-------------+----------+--------------------------------------+
|                  ID                  | Status |   Display Name   | Size | Volume Type | Bootable |             Attached to              |
+--------------------------------------+--------+-------

+--------------------------------------+--------+-------

Reference: https://www.centos.org/forums/viewtopic.php?f=47&t=48591

There will be significant changes in multi back end cinder architecture of RDO Juno running on CentOS 7 or Fedora 21 utilizing LVM based iSCSI targets. Create following entries in /etc/cinder/cinder.conf on Controller ( which in case of two node Cluster works as Storage node as well).

####################### 
enabled_backends=lvm51,lvm52
#######################

[lvm51]
iscsi_helper=lioadm
volume_group=cinder-volumes51
volume_driver=cinder.volume.drivers.lvm.LVMISCSIDriver
iscsi_ip_address=192.168.1.127
volume_backend_name=LVM_iSCSI51


[lvm52]
iscsi_helper=lioadm
volume_group=cinder-volumes52
volume_driver=cinder.volume.drivers.lvm.LVMISCSIDriver
iscsi_ip_address=192.168.1.127
volume_backend_name=LVM_iSCSI52

VG cinder-volumes52,51 created on /dev/sda6 and /dev/sdb1 correspondently :-

# pvcreate /dev/sda6
# pvcreate /dev/sdb1
# vgcreate cinder-volumes52 /dev/sda6
# vgcreate cinder-volumes51  /dev/sdb1

Then issue :-

[root@juno1 ~(keystone_admin)]# cinder type-create lvms
+--------------------------------------+------+
|                  ID                  | Name |
+--------------------------------------+------+
| 64414f3a-7770-4958-b422-8db0c3e2f433 | lvms  |
+--------------------------------------+------+


[root@juno1 ~(keystone_admin)]# cinder type-create lvmz +--------------------------------------+---------+
|                  ID                  |   Name  |
+--------------------------------------+---------+
| 29917269-d73f-4c28-b295-59bfbda5d044 | lvmz |

+--------------------------------------+---------+ 

[root@juno1 ~(keystone_admin)]# cinder type-list
+--------------------------------------+---------+
|                  ID                  |   Name  |
+--------------------------------------+---------+
| 29917269-d73f-4c28-b295-59bfbda5d044 |  lvmz   |
| 64414f3a-7770-4958-b422-8db0c3e2f433 |  lvms   |
+--------------------------------------+---------+


[root@juno1 ~(keystone_admin)]# cinder type-key lvmz set volume_backend_name=LVM_iSCSI51

[root@juno1 ~(keystone_admin)]# cinder type-key lvms set volume_backend_name=LVM_iSCSI52

Then enable and start service target:-

[root@juno1 ~(keystone_admin)]#   service target enable
[root@juno1 ~(keystone_admin)]#   service target start

[root@juno1 ~(keystone_admin)]# service target status
Redirecting to /bin/systemctl status  target.service
target.service - Restore LIO kernel target configuration
   Loaded: loaded (/usr/lib/systemd/system/target.service; enabled)
   Active: active (exited) since Wed 2014-11-05 13:23:09 MSK; 44min ago
  Process: 1611 ExecStart=/usr/bin/targetctl restore (code=exited, status=0/SUCCESS)
 Main PID: 1611 (code=exited, status=0/SUCCESS)
   CGroup: /system.slice/target.service


juno1.localdomain systemd[1]: Starting Restore LIO kernel target configuration...


juno1.localdomain systemd[1]: Started Restore LIO kernel target configuration.

Now all changes done by creating cinder volumes of types lvms,lvmz ( via dashboard - volume create with dropdown menu volume types or via cinder CLI ) will be persistent in targetcli> ls output between reboots

[root@juno1 ~(keystone_boris)]# cinder list
+--------------------------------------+--------+------------------+------+-------------+----------+--------------------------------------+
|                  ID                  | Status |   Display Name   | Size | Volume Type | Bootable |             Attached to              |
+--------------------------------------+--------+-------

Reference: Source: http://bderzhavets.blogspot.jp/2014/11/lvmiscsi-cinder-backend-for-rdo-juno-on.html

https://www.centos.org/forums/viewtopic.php?f=47&t=48591