ceph-iscsi-cli icon indicating copy to clipboard operation
ceph-iscsi-cli copied to clipboard

Hi,excuse me,about the number of target and lun.

Open letterwuyu opened this issue 6 years ago • 12 comments

Now I find that I can only create a target and create a maximum of 256 Lun, and I want to ask if there is a way to create more Lun.

letterwuyu avatar Mar 15 '18 11:03 letterwuyu

No, 256 LUNs per target is a limitation within LIO I believe.

dillaman avatar Mar 15 '18 12:03 dillaman

@dillaman thank you for your answer and great work, I have another question: As I have just mentioned, a iSCSI gateway cluster can create only one target. Can I create two target by creating two iSCSI gateway clusters (connecting the same CEPH cluster), thereby increasing the number of Lun support?

letterwuyu avatar Mar 15 '18 14:03 letterwuyu

@letterwuyu What's your use-case for needing such a high number of LUNs?

dillaman avatar Mar 15 '18 14:03 dillaman

@dillaman At present, we want to use CEPH to do the back-end storage of VMware, and later it will be used for other businesses. Considering the expansion problem, I don't know whether the 256 number can meet the general needs, so I want to know about it.

letterwuyu avatar Mar 15 '18 14:03 letterwuyu

@letterwuyu For the VMware case, I don't see why you would need so many LUNs. You would only need to export maybe one for each gateway to spread the load appropriately. VMware will put its VMFS on top of the LUNs to build a single datastore over the LUNs. If you need to add more space in the future, you can resize the LUNs.

dillaman avatar Mar 15 '18 14:03 dillaman

Yes, VMware case is what you said. Thank you very much for your detailed answer.

letterwuyu avatar Mar 15 '18 14:03 letterwuyu

Just a FYI.

rtslib was fixed the other day to support more luns:

https://github.com/open-iscsi/rtslib-fb/commit/20a50d9967464add8d33f723f6849a197dbe0c52

There is still a problem where older kernels like used by RHEL 7.4 only support 256 due to a hard coded limit in the kernel (this is fixed in RHEL 7.5 btw). Newer kernels are limited by the SCSI spec and what a 64 bit id can hold and what your system can allocate before it runs out of memory :)

If there is a need we can update our tools. Note that vmware only supports 512 LUNs for iscsi so you normally do what dillaman suggested. Maybe we should just at least increase our limit to match vmware.

mikechristie avatar Mar 15 '18 17:03 mikechristie

oh, thanks for your FYI

letterwuyu avatar Mar 16 '18 06:03 letterwuyu

I'd like to add an additional usecase. Openstack baremetal case also require higher number of LUNs.

zhuozh avatar Apr 20 '18 02:04 zhuozh

@zhuozh That's not really a use-case we plan to work on, but contributions are welcome.

dillaman avatar Apr 20 '18 12:04 dillaman

I need to create 2 targets in iscsi gateway The use case is for creating differenrt target for self hosted engine storage doamin and another for additional storage data domain . Can you suggest me a solution for this . Thanks

sadiq1425 avatar Jun 10 '18 19:06 sadiq1425

You can map different LUNs (RBD images) to different initiators within the same target. That will allow you to have isolated storage domains.

dillaman avatar Jun 10 '18 21:06 dillaman