From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Love, Robert W" Subject: Re: [Qemu-devel] Testing NPIV Feature with Qemu-KVM Date: Thu, 5 Sep 2013 14:59:08 +0000 Message-ID: <52289C3B.5080602@intel.com> References: <20130902123444.GA25765@oc2505588478.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT Return-path: Received: from mga03.intel.com ([143.182.124.21]:28531 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753696Ab3IEO7L convert rfc822-to-8bit (ORCPT ); Thu, 5 Sep 2013 10:59:11 -0400 In-Reply-To: Content-Language: en-US Content-ID: Sender: linux-scsi-owner@vger.kernel.org List-Id: linux-scsi@vger.kernel.org To: Stefan Hajnoczi Cc: chandrashekar shastri , linux-scsi , qemu-devel , "linux-fsdevel@vger.kernel.org" , Hannes Reinecke On 13-09-05 07:15 AM, Stefan Hajnoczi wrote: > On Mon, Sep 2, 2013 at 2:34 PM, chandrashekar shastri > wrote: >> I am testing NPIV feature on upstream Qemu, I have configured the zone >> and able to see the created vport on the storage array. >> >> Since, I am learning on how to setup the NPIV, I haven't created the different zone for >> the vport and the array, I just added in the existing zone. >> >> Now, how do pass the LUN to the qemu, from Dr. Hannes Reineckei mail thread I got to know that lspci command on the host doesn't show the virtual HBA. >> >> I didn't understand why there is limitation on that and if I specify >> /usr/libexec/qemu-kvm -enable-kvm Fedora19 -m 3000 -smp 2 -net nic -net >> \ user -vnc 127.0.0.1:0 -drive if=scsi,file=/dev/sdj >> >> How do I make sure that qemu is using the virtual HBA or (vport)? > From my limited knowledge of NPIV, after you create the vport on the > host you'll have a new "SCSI host" which scans LUNs. That means new > SCSI devices appear on the host. > > You can use "ls -al /sys/class/scsi_host" to see the SCSI hosts that are active. > > You can use "virsh nodedev-list --tree" to see the details of the devices. > > This should help you find the NPIV LUNs which can be passed to QEMU. > Also, there will be a /sys/class/fc_host, associated with the scsi_host. It will have a port_type, that when read, should show "NPIV VPORT". //Rob From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45937) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VHb1i-0005kU-7P for qemu-devel@nongnu.org; Thu, 05 Sep 2013 10:59:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VHb1b-0007J9-Vo for qemu-devel@nongnu.org; Thu, 05 Sep 2013 10:59:18 -0400 Received: from mga03.intel.com ([143.182.124.21]:47315) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VHb1b-0007Il-Jh for qemu-devel@nongnu.org; Thu, 05 Sep 2013 10:59:11 -0400 From: "Love, Robert W" Date: Thu, 5 Sep 2013 14:59:08 +0000 Message-ID: <52289C3B.5080602@intel.com> References: <20130902123444.GA25765@oc2505588478.ibm.com> In-Reply-To: Content-Language: en-US Content-Type: text/plain; charset="iso-8859-1" Content-ID: Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [Qemu-devel] Testing NPIV Feature with Qemu-KVM List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: "linux-fsdevel@vger.kernel.org" , Hannes Reinecke , chandrashekar shastri , linux-scsi , qemu-devel On 13-09-05 07:15 AM, Stefan Hajnoczi wrote: > On Mon, Sep 2, 2013 at 2:34 PM, chandrashekar shastri > wrote: >> I am testing NPIV feature on upstream Qemu, I have configured the zone >> and able to see the created vport on the storage array. >> >> Since, I am learning on how to setup the NPIV, I haven't created the dif= ferent zone for >> the vport and the array, I just added in the existing zone. >> >> Now, how do pass the LUN to the qemu, from Dr. Hannes Reineckei mail thr= ead I got to know that lspci command on the host doesn't show the virtual H= BA. >> >> I didn't understand why there is limitation on that and if I specify >> /usr/libexec/qemu-kvm -enable-kvm Fedora19 -m 3000 -smp 2 -net nic -net >> \ user -vnc 127.0.0.1:0 -drive if=3Dscsi,file=3D/dev/sdj >> >> How do I make sure that qemu is using the virtual HBA or (vport)? > From my limited knowledge of NPIV, after you create the vport on the > host you'll have a new "SCSI host" which scans LUNs. That means new > SCSI devices appear on the host. > > You can use "ls -al /sys/class/scsi_host" to see the SCSI hosts that are = active. > > You can use "virsh nodedev-list --tree" to see the details of the devices= . > > This should help you find the NPIV LUNs which can be passed to QEMU. > Also, there will be a /sys/class/fc_host, associated with the scsi_host.=20 It will have a port_type, that when read, should show "NPIV VPORT". //Rob=