[Kimchi-devel] [PATCH 0/3] (WIP) Storagepool SCSI/FC

Rodrigo Trujillo rodrigo.trujillo at linux.vnet.ibm.com
Fri Jan 10 17:34:39 UTC 2014


NOTICE: THIS FEATURE IS STILL UNDER DISCUSSION/AGREEMENT/DEVELOPMENT

This patch set implements the basic functions in order to create a SCSI
storagepool based in fibre channel protocol.

--- What is implemented? ---
* backend API 
   It is possible to create a pool with curl POST request like:
   curl -X POST -u <USER>  -H 'Content-type: application/json' \
   -H 'Accept: application/json' http://localhost:8000/storagepools \
    --data '{ \
        "name": "testFC", \
        "source": { "adapter_type": "scsi_host", \
                    "adapter_name": "scsi_hostX", \
                    "wwnn":"112233789",  \
                    "wwpn":"44332211" }, \
        "path": "/dev/disk/by-id", \
        "type": "scsi" }'

* json schema updated

* created a function to test the host libvirt version
   SCSI FC pool and volumes have theirself configuration only after
   libvirt version 1.0.5. If lesser, I must use older configuration
   tags

* updates the VM guest template with proper disk xml
   Create volumes in a SCSI pool is not supported by libvirt, because
   volumes are the LUNS preconfigured and available in the SAN. Disk
   will have the biggest LUN found assigned.

--- What does need to be discussed? Ideas? ---
1) Backend expects right information from UI, so UI would have to ask
   and send 'adapter_name', 'wwnn' and 'wwpn' (other fields can be fi
   xed). However, the UI coud show the FC_Hosts available and let user
   select which one he wants. This would require to implement more ba
   ck-end functions to gather FC_host info, automatically (name, wwnn,
   wwpn).
   So, at this moment, just create an UI with input fields or facili
   tate the users life ?  

2) Currently the user have no choice on with LUN to assign to a guest.
   LUN is selected automatically and if not LUN is available, guest
   will not have any disk. In order to improve this, the guest creation
   fase could have one more step, if the pool in the template in SCSI
   type. If SCSI, user could choose which LUN he wants to assign to VM.
   Notice that the disk size in the template have been, and will be, ig
   nored.
   What do you guys think about this approach ?

3) LUNs refresh: Once the storage admin creates more LUNs, the host admin
   needs to perform some commands in order to kernel 'see' and map new
   devices. I am implementing this backend functionality. A refresh bu
   tton will be necessary in the UI, where could it be placed?
     - In the storagepool creation window ? When select SCSI type
     - In the window to select the LUN, when creating new guest (if 
       approved this extra step)
     - In the storagepool tab, in the pool section, if its a SCSI type
     - Also, when the user expands a SCSI pool section, which will show
       the volumes (LUNs), this function can be triggered.

4) More ideas/concerns/suggestions ?



Rodrigo Trujillo (3):
  Storagepool: SCSI/Fibre Channel backend implementation
  Storagepools: Function to check libvirt version
  Storagepools: Assign SCSI fibre channel LUN as disk to a new guest

 docs/API.md              |  6 ++++
 src/kimchi/API.json      | 18 ++++++++++-
 src/kimchi/model.py      | 79 +++++++++++++++++++++++++++++++++++++++++++++---
 src/kimchi/utils.py      | 14 +++++++++
 src/kimchi/vmtemplate.py | 40 +++++++++++++++++++++++-
 5 files changed, 151 insertions(+), 6 deletions(-)

-- 
1.8.1.4




More information about the Kimchi-devel mailing list