On Mon, 2013-06-03 at 08:53 +0200, Khandelwal, Shubham
wrote:> Thanks for your reply.
You are welcome. Please can you stop top posting, it makes the thread of
the conversation rather hard to follow. If you could also configure your
mailer to use the conventional "> " mode of quoting (as I have done
here) that would be appreciated.
You also appear to have dropped the list from your previous reply which
I didn't notice -- please always keep the list CCd. I have added it back
now so that everyone (and the list archives) can benefit.
> I did all the necessary steps as mentioned by you in the previous
> mail. But still libvchan is showing the same error as before
> (libxenvchan_*_init: Invalid argument and libxenvchan_*_init: No such
> file or directory ) (strace outputs attached). Below is the output for
> cat /proc/misc from both the dom's which shows the necessary modules
> present.
Did you also confirm that the device nodes were present in /dev/ and
that the minor numbers matched? misc devices are dynamic and so the
minor numbers can change (as you can see here because your dom0 and domU
minor numbers differ).
Usually this is taken care of by udev. If you are running a stripped
down userspace you may need to take care of this manually.
Looking at your dom0 server-write-error.txt doesn't appear to show an
error -- it looks like it is working to me and is waiting for a client
to send it some information. Likewise for server-read-error.txt.
On the domU side I see things like:
open("/dev/xen/evtchn", O_RDWR|O_LARGEFILE) = 4
ioctl(4, EVIOCGID, 0xbeb6b64c) = -1 ENOTTY (Inappropriate ioctl
for device)
write(4, "\377\377\377\377", 4) = -1 EINVAL (Invalid
argument)
which suggest to me that your misc device minor numbers do not match
(IOW /dev/xen/evtchn does not actually refer to the evtch device).
Ian.
(leaving entire original message quoted for the benefit of the archives)
>
>
> DOM 0
>
>
> DOM U
>
>
> 55 network_throughput
>
>
> 56 network_throughput
>
>
> 56 network_latency
>
>
> 57 network_latency
>
>
> 57 cpu_dma_latency
>
>
> 58 cpu_dma_latency
>
>
> 1 psaux
>
>
> 1 psaux
>
>
> 200 tun
>
>
> 200 tun
>
>
> 237 loop-control
>
>
> 237 loop-control
>
>
> 58 xen/privcmd
>
>
> 59 xen/privcmd
>
>
> 59 xen/gntalloc
>
>
> 60 xen/gntalloc
>
>
> 60 xen/gntdev
>
>
> 61 xen/gntdev
>
>
> 61 xen/evtchn
>
>
> 62 xen/evtchn
>
>
> 62 xen/xenbus_backend
>
>
> 63 xen/xenbus
>
>
> 63 xen/xenbus
>
>
>
>
>
>
>
>
> Also I am writing the domid in the domain 0 after booting it (command
> is ‘ /xenstore-write "/local/domain/0/domid" "0" ’) .
However it is
> showing the same error on running the commands as mentioned by me in
> the previous mail in detail.
>
>
>
> Regards
>
>
>
> Shubham Khandelwal
>
>
>
>
>
> -----Original Message-----
> From: Ian Campbell [mailto:Ian.Campbell@citrix.com]
> Sent: Friday, May 31, 2013 3:41 PM
> To: Khandelwal, Shubham
> Cc: 'Stefano Stabellini'; 'dgdegra@tycho.nsa.gov'; Datta,
Souvik
> Subject: Re: [Xen-devel] Error in running libvchan.
>
>
>
> On Tue, 2013-05-28 at 11:23 +0200, Khandelwal, Shubham wrote:
>
>
>
> I've just tried this (on x86, but I don't think that will make a
>
> difference) and I was able to get it to work. There were a few
> pitfalls
>
> though.
>
>
>
> The first was not compiling my domU kernel with
>
> CONFIG_XEN_GRANT_DEV_ALLOC, meaning that /dev/xen/gntalloc was not
>
> available. You will also need CONFIG_XEN_GNTDEV (/dev/xen/gntdev) and
>
> CONFIG_XEN_DEV_EVTCHN (/dev/xen/evtchn). Strictly you need gntalloc
> for
>
> the server and gntdev for the client and evtchn for both, but easier
>
> just to make all three available everywhere.
>
>
>
> The second was not mounting xenfs on /proc/xen within the guest.
>
>
>
> libvchan could really do with improved error logging for these failure
>
> cases...
>
>
>
> With those fixed the following works for me:
>
>
>
> domU# vchan-node1 server read 0 data/vchan
>
>
>
> dom0# domU=$(xl domid d32-1)
>
> dom0# vchan-node1 client write
> ${domid} /local/domain/${domid}/data/vchan
>
>
>
> Now I can type into the dom0 window and the data appears on the domU
>
> end. I can also invert the read/write parameter and go the other way.
>
> This demo code doesn't appear to be bidirectional.
>
>
>
> Running the server in dom0 didn't initially work for me, because
> dom0's
>
> domid node is missing. However this was easy to work around:
>
>
>
> dom0# xenstore-write /local/domain/0/domid 0
>
> dom0# domU=$(xl domid d32-1)
>
> dom0# vchan-node1 server read $(xl domid d32-1) data/vchan
>
>
>
> domU# vchan-node1 client write 0 /local/domain/0/data/vchan
>
>
>
> Then I can type in the client end and receive on the server end.
>
>
>
> Ian.
>
>
>
>
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel