[Users] Adding iscsi/fcp storage with rest api

Mohua Li moli at redhat.com
Thu Dec 20 02:35:04 EST 2012


Hi,

I'm trying to add  fcp/iscsi storage with rest api like below, 


#iscsi(iscsi hba card)
743                   # type_: storage type
744                   storage_params = param.Storage(address="10.66.90.100",·
745                                                   port="3260",·
                                                      id="36090a038d0f7316a6807a568b2491f1d",
                                                      target="iqn.2001-05.com.equallogic:0-8a0906-6a31f7d03-1d1f49b268a50768"
746                                                   type_="iscsi")
747                   # type_: storagedomain type
748                   storagedomain_params = param.StorageDomain(name="iscsidomain",
749                                                              data_center=dc, host=host,
750                                                              type_="data", storage_format="v3",
751                                                              storage=storage_params)
752                   try:
753                      logging.info("Creating iscsi data storage %s" % name)
754                      storagedomain = self.api.storagedomains.add(storagedomain_params)


storage params for fcp storage:

744                   storage_params = param.Storage(id="3600a0b80005adb0b00004d834f0b7954",
746                                                   type_="fcp")


my question are:

* if this is enough to connect iscsi/fcp(lun id, target) storage?
* did wrong type the logical_unit element, 


thanks for your help again.





Regards,

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: Digital signature
URL: <http://lists.ovirt.org/pipermail/users/attachments/20121220/6bb8f09d/attachment-0002.sig>


More information about the Users mailing list