Attaching the volume from 5500 V3 failed when using Cinder plugin to manage storage

Publication Date:  2016-03-25 Views:  501 Downloads:  0
Issue Description

After install Cinder plugin in the Linux OS, we have to steps below to create the volume from storage and attach it to the VM in the OS:

[xxxxx server]$ cinder create --display-name vol1 10      (Create the Volume "vol1" with 10Gb)
[xxxxx server]$ nova volume-attach vm1 $(cinder list | awk '/vol1/ {print $2}') /dev/vdb      (Attach the volume to the VM with name "vm1")
[xxxxx server]$ nova show vm1       (Check the details of the VM)

When checking the details of the VM, we can see there is no attached volume for the VM as below:

Alarm Information
None
Handling Process

In the "volume.log-xxxxx", we can find the error information as below, which mean that the initiator of the server can't be added to the related HOST in the storage automatically

Then we find out the initiator information in the "volume.log-xxxxx" as below:

And then, we can go to the storage device to check the real status of these initiators as below, and found out that they have been added manually to the existing HOST in the storage.

Root Cause
For the Cinder plugin, when you create the volume and attach it to the VM in the OS of the HOST, we have to make sure the initiator from the HOST is not be added to any other HOSTs in the storage. Because the Cinder will create its own HOST name in the storage and add the initiator to that HOST automatically, if the operators add the initiator to other HOST manually, Cinder will detect the conflict. 
Solution

According to the root cause above, we have to remove the initiator from the other HOST in the storage, and make sure the status of the initiators is online and available, which mean that they are not added to any other host.

Suggestions
When you use Cinder to manage the storage, you only have to make sure the network communication is alright, for any other operation,Cinder will finish it by itself automatically, including creating volume and HOST name, and creating the mapping then adding the initiators to the HOST.

END