Thank you, shuuhei and Ziye.

Your response are so fast.
The spdk_iscsi_conn_migration will schedule a reactor to handle the new connection.
I have understood now.

As I know, the openiscsi initiator only uses one session/connection when connecting to one target, even though it has multiple luns.
So it will process IOs on the same core when they belong to the same target. 


Another question, would you have a plan to support SCSI PR(persistent reservation)?





Thanks,

Feng Li

  

手机:13401157876

Web:http://www.smartx.com/

地址:北京市海淀区科学院南路2号融科资讯中心C座北楼712


2018-07-31 14:50 GMT+08:00 Yang, Ziye <ziye.yang@intel.com>:

Hi Li,

 

The acceptor is running on core 0 on default,  but when the connection is in ffp phase, it will be transferred to other reactors for connection handling, see the code in spdk_iscsi_conn_migration in lib/iscsi/iscsi.c. According to the code, you can see it is also related with the portal group info (cpu mask).

 

 

Thanks.

 

 

 

Best Regards

Ziye Yang

 

From: SPDK [mailto:spdk-bounces@lists.01.org] On Behalf Of 松本周平 / MATSUMOTOSHUUHEI
Sent: Tuesday, July 31, 2018 2:06 PM
To: Storage Performance Development Kit <spdk@lists.01.org>
Subject: Re: [SPDK] How to utilize multiple threads?

 

Hi Li,

 

But the acceptor is only running on the core 0, right?

Yes.

 

But if what you see is in acceptor.c, it may be the acceptor dedicated to check start of communication by initiator.

 

Regardless of this, you are correct and each iSCSI connection is handled by single CPU core because SPDK is highly efficient and lockless.

By increasing number of iSCSI connections, all CPU cores will be used.

 

The following by Ziye Yang is not maintained now but it will be helpful if you read.

https://review.gerrithub.io/#/c/spdk/spdk/+/392733/18/doc/iscsi_pg.md

 

Thanks,

Shuhei


差出人: SPDK <spdk-bounces@lists.01.org> Li Feng <fengli@smartx.com> の代理で送信
送信日時: 2018731 14:32
宛先: Storage Performance Development Kit
件名: [!][SPDK] How to utilize multiple threads?

 

Hi experts,

 

When I'm digging into SPDK iscsi source codes, I have some doubt about the threads/reactors.

 

 

Look at this example.

 

Start iscsi target on core 0-7:

```

app/iscsi_tgt/iscsi_tgt -L all -d 1 -m 0xff

```

I can see 8 threads which are polling.

 

But the acceptor is only running on the core 0, right?

 

This means all IOs are processed on core 0, no matter how many bdevs are connecting ?

 

 

I can see sending NOP IN is a poller running on all reactors. But this is not about read/write.

 

So how to utilize the other threads to maximum the iops and throughput?

 

 

 

Thanks in advance.

 

 

The SmartX email address is only for business purpose. Any sent message that is not related to the business is not authorized or permitted by SmartX.

本邮箱为北京志凌海纳科技有限公司(SmartX)工作邮箱. 如本邮箱发出的邮件与工作无关,该邮件未得到本公司任何的明示或默示的授权.

 


_______________________________________________
SPDK mailing list
SPDK@lists.01.org
https://lists.01.org/mailman/listinfo/spdk



The SmartX email address is only for business purpose. Any sent message that is not related to the business is not authorized or permitted by SmartX.
本邮箱为北京志凌海纳科技有限公司(SmartX)工作邮箱. 如本邮箱发出的邮件与工作无关,该邮件未得到本公司任何的明示或默示的授权.