From owner-freebsd-fs@freebsd.org Sun Jul 30 06:34:09 2017 Return-Path: Delivered-To: freebsd-fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2B519DB03D8 for ; Sun, 30 Jul 2017 06:34:09 +0000 (UTC) (envelope-from emz@norma.perm.ru) Received: from elf.hq.norma.perm.ru (mail.norma.perm.ru [IPv6:2a00:7540:1::5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.norma.perm.ru", Issuer "Vivat-Trade UNIX Root CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 8DAD867700 for ; Sun, 30 Jul 2017 06:34:08 +0000 (UTC) (envelope-from emz@norma.perm.ru) Received: from [IPv6:2a02:2698:26:9b0e:1926:57f5:2ee4:923c] (dynamic-2a02-2698-26-0-0.perm.ertelecom.ru [IPv6:2a02:2698:26:9b0e:1926:57f5:2ee4:923c] (may be forged)) (authenticated bits=0) by elf.hq.norma.perm.ru (8.15.2/8.15.2) with ESMTPSA id v6U6Y25R047677 (version=TLSv1.2 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO) for ; Sun, 30 Jul 2017 11:34:02 +0500 (YEKT) (envelope-from emz@norma.perm.ru) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=norma.perm.ru; s=key; t=1501396442; bh=pqPAlkjtWgmZVZpNHufK9MFTKTV3PERWALgRNWMCDH0=; h=Subject:To:References:From:Date:In-Reply-To; b=rUvhhKl3iMybr13cEuCo1282nqtwgfbW0BRD1wZdUOx3Y4+QbCj0C+4x3ydDp9t5G IK55ceQTzUQcsKoroY8FYKl3Ri/5WgBhbQcOEMkdLOUGGzkiiGcKUOiFmUwVJ5W+2m i0/pHGnOk3epbrWJkSqLr/6eF0qeHAPmA4bMa4mo= Subject: Re: ZFS and ISCSI question To: freebsd-fs@freebsd.org References: From: "Eugene M. Zheganin" Message-ID: Date: Sun, 30 Jul 2017 11:34:02 +0500 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-GB X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 30 Jul 2017 06:34:09 -0000 On 29.07.2017 23:59, Kaya Saman wrote: > Hi, > > > I'm trying to find out how ZFS and ISCSI work together. So far I have > followed the guide in the handbook: > > > https://www.freebsd.org/doc/handbook/network-iscsi.html > > > Based on the guide what I have done is created 3 demo files using dd: > > > disk1, disk2, disk3 > > > then created a zpool around them: zpool create iscsi-tst /data/disk1 > /data/disk2 /data/disk3 > > > and finally a ZVOL: zfs create -V iscsi-tst/tank > > > From the guide a basic (for testing only) ctl.conf: > > > portal-group pg0 { > discovery-auth-group no-authentication > listen 0.0.0.0 > listen [::] > } > > target iqn.2012-06.com.example:target0 { > auth-group no-authentication > portal-group pg0 > > lun 0 { > path iscsi-tst/tank > size 500M > } > } > > > and then on the Initiator machine: > > > iscsictl -A -p -t iqn.2012-06.com.example:target0 > > > I can confirm a connection: > > > # iscsictl -L > Target name Target portal State > iqn.2012-06.com.example:target0 Connected: da24 > > > But if we look at dmesg output it is saying the size cannot be queried? > > > da24 at iscsi4 bus 0 scbus9 target 0 lun 0 > da24: Fixed Direct Access SPC-4 SCSI device > da24: Serial Number MYSERIAL 0 > da24: 150.000MB/s transfers > da24: Command Queueing enabled > da24: Attempt to query device size failed: NOT READY, Logical unit not > ready, manual > > > I am wondering what I have done wrong and additionally is it possible > to get the Initiator to see the zpool/ZVOL so that I can create a zfs > dataset on it? > You forgot to enter the zvol size - f -V argument. I'm surprised it was even created. Eugene.