From: Juergen Gross <jgross@suse.com>
To: Kristian Hagsted Rasmussen <kristian@hagsted.dk>,
Olaf Hering <olaf@aepfle.de>,
"xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: Re: pvSCSI test
Date: Mon, 09 Feb 2015 07:02:56 +0100 [thread overview]
Message-ID: <54D84D90.9010700@suse.com> (raw)
In-Reply-To: <511f26c74cce4b7e9defa4c74ddecc51@hagsted-cserver.hagsted.dk>
On 02/06/2015 09:33 PM, Kristian Hagsted Rasmussen wrote:
>
> On Friday, February 6, 2015 15:25, Juergen Gross <jgross@suse.com> wrote:
>> To: Kristian Hagsted Rasmussen; Olaf Hering; xen-devel@lists.xensource.com
>> Subject: Re: [Xen-devel] pvSCSI test
>>
>
>>> After some more fiddling around, I believe the configuration should be okay. My /etc/target/xen-pvscsi_start.sh look like this:
>>>
>>> modprobe xen-scsiback
>>> mkdir /sys/kernel/config/target/xen-pvscsi
>>> mkdir -p /sys/kernel/config/target/xen-pvscsi/naa.600140512a981c66/tpgt_0
>>> echo naa.6001405708ab297e > /sys/kernel/config/target/xen-pvscsi/naa.600140512a981c66/tpgt_0/nexus
>>> #### xen-pvscsi Target Ports
>>> mkdir -p /sys/kernel/config/target/xen-pvscsi/naa.600140512a981c66/tpgt_0/lun/lun_0
>>> ln -s /sys/kernel/config/target/xen-pvscsi/naa.600140512a981c66/tpgt_0/lun/lun_0/../../../../../../target/core/iblock_0/3_0_0_0 /sys/kernel/config/target/xen-pvscsi/naa.600140512a981c66/tpgt_0/lun/lun_0/xen-pvscsi_port
>>
>> iblock_0?
>
> Sorry the result is the same if I use pscsi, I just tried iblock as it was a harddisk I tried to pass through and lio documentation advice against using pscsi for hard drives.
>
> I just now tried to pass through a bluray drive on another machine, however I get the exact same error. What I noticed, however, was that the error only appears if the DomU kernel supports xen-scsifront. I hazzard a guess that this is because the backend only tries to connect to the device if the frontend makes a call for it.
>
> In xenstore I have the following entry for vscsi under /local/domain/0/backend:
> vscsi = ""
> 3 = ""
> 0 = ""
> frontend = "/local/domain/3/device/vscsi/0"
> frontend-id = "3"
> online = "1"
> state = "4"
> feature-host = "0"
> vscsi-devs = ""
> dev-0 = ""
> p-dev = "3:0:0:0"
> v-dev = "0:0:0:0"
> state = "6"
> feature-sg-grant = "128"
>
> As I am no expert I am not sure about this, but shouldn't there be a path to the device, more then just the p-dev statement?
No, that's okay. The connection between p-dev and the drive is done
via the target infrastructure.
Something seems to be wrong with your link in configfs: the target
seems not to be active. Could you please check the link to be correct?
Please check whether the pscsi (or iblock) entry is active. This can
be done via the "ls" command in targetcli for example.
When I tested the pscsi entry in configfs switched to "active" when I
linked the xen-pvscsi entry to it.
> Do I have to manually add the device to xenstore?
I never did it. :-)
Juergen
>
> If you do not feel for answering more of my questions please feel free to say so, I am just interested in this work and really look forward to its inclusion in xen.
>
> /Kristian
>
>> You are not using pscsi, but iblock. Is that on purpose? I have tested
>> pscsi and fileio only.
>>
>> What does lsscsi tell you after adding the device via targetcli? I
>> suppose you see a new scsi target you should use instead of 3:0:0:0
>> (that's what I did in the fileio case).
>>
>>> #### Attributes for xen-pvscsi Target Portal Group
>>> #### Parameters for xen-pvscsi Target Portal Group
>>> echo "3:0:0:0" > /sys/kernel/config/target/xen-pvscsi/naa.600140512a981c66/tpgt_0/param/alias
>>>
>>> And
>>> cat /sys/kernel/config/target/xen-pvscsi/naa.600140512a981c66/tpgt_0/param/alias
>>> returns 3:0:0:0 as expected.
>>>
>>> If I understand this correctly, it is xen-scsiback that reads the target configuration from ConfigFS and hence the problem that xen-pvscsi cannot find the device has nothing to do with which toolstack is used?
>>
>> Yes and no. In theory the backend would accept anything from xenstore
>> which it can find in configfs. The toolstack however will only write
>> values into the xenstore it believes are valid SCSI devices.
>>
>>> If you are willing to part with the script you used together with targetcli, I would be more then happy to try that out.
>>
>> I did my first tests with fileio on a machine I have no longer access
>> to. after I got it running I changed to my local test machine and pscsi.
>> Here I did the targetcli stuff manually and verified afterwards that
>> the single steps I put in my script were working. So the script I gave
>> you is basically the documentation of the manual setup I used.
>>
>> Juergen
>>
next prev parent reply other threads:[~2015-02-09 6:02 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <bd907a705c8747b1991a3b7c69fd3b8e@hagsted-cserver.hagsted.dk>
2015-02-04 4:41 ` pvSCSI test Juergen Gross
2015-02-06 9:32 ` Kristian Hagsted Rasmussen
2015-02-06 9:57 ` Juergen Gross
2015-02-06 14:02 ` Kristian Hagsted Rasmussen
2015-02-06 14:25 ` Juergen Gross
2015-02-06 20:33 ` Kristian Hagsted Rasmussen
2015-02-09 6:02 ` Juergen Gross [this message]
2015-02-12 16:43 ` Kristian Hagsted Rasmussen
2015-02-16 6:32 ` Juergen Gross
2015-02-16 19:45 ` Kristian Hagsted Rasmussen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54D84D90.9010700@suse.com \
--to=jgross@suse.com \
--cc=kristian@hagsted.dk \
--cc=olaf@aepfle.de \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.