Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Sep 2017 08:15:54 +0100
From:      Edward Tomasz =?utf-8?Q?Napiera=C5=82a?= <trasz@FreeBSD.org>
To:        "Eugene M. Zheganin" <emz@norma.perm.ru>
Cc:        freebsd-stable@freebsd.org
Subject:   Re: ctld: only 579 iSCSI targets can be created
Message-ID:  <20170922071554.GA3846@brick>
In-Reply-To: <04e8820c2c6cc7a95d6ffdf257f00f7d@norman-vivat.ru>
References:  <04e8820c2c6cc7a95d6ffdf257f00f7d@norman-vivat.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
On 0922T1036, Eugene M. Zheganin wrote:
> Hi,
> 
> I have old 11-STABLE as an iSCSI server, but out of the blue I 
> encountered weird problem: only 579 targets can be created. I mean, I am 
> fully aware that the out-of-the-box limit is 128 targets, with is 
> enforced by the CTL_MAX_PORTS define, and I've set it to 1024 (and of 
> course rebuilt and installed a new kernel), but when I add more that 579 
> targets I start to get the protocol errors:
> 
> Sep 22 10:16:48 san1 ctld[8657]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x4
> Sep 22 10:16:48 san1 ctld[8658]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x46
> Sep 22 10:17:31 san1 ctld[8746]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x4
> Sep 22 10:17:31 san1 ctld[8747]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x46
> Sep 22 10:19:58 san1 ctld[9190]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x4
> Sep 22 10:19:58 san1 ctld[9191]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x46
> Sep 22 10:21:33 san1 ctld[9518]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x4
> Sep 22 10:21:33 san1 ctld[9519]: 10.0.3.127 
> (iqn.1991-05.com.microsoft:worker296): protocol error: received invalid 
> opcode 0x46

There are two weird things here.  First is that the error is coming from
ctld(8) - the userspace daemon, not the kernel.  The second is that those
invalid opcodes are actually both valid - they are the Text Request,
and the Logout Request with Immediate flag set, exectly what you'd expect
for a discovery session.

Do you have a way to do a packet dump?




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20170922071554.GA3846>