WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] Re: [PATCH resend] allow connecting to xenconsole from remot

To: Muli Ben-Yehuda <muli@xxxxxxxxxx>
Subject: [Xen-devel] Re: [PATCH resend] allow connecting to xenconsole from remote hosts
From: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Date: Tue, 26 Sep 2006 16:50:37 +0100
Cc: Jimi Xenidis <jimix@xxxxxxxxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, Anthony Liguori <anthony@xxxxxxxxxxxxx>, Orran Y Krieger <okrieg@xxxxxxxxxx>
Delivery-date: Tue, 26 Sep 2006 08:50:19 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20060926152635.GA22797@xxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: Acbhg4JRwPJ0/E12EduAkQAX8io7RQ==
Thread-topic: [PATCH resend] allow connecting to xenconsole from remote hosts
User-agent: Microsoft-Entourage/11.2.5.060620
On 26/9/06 16:26, "Muli Ben-Yehuda" <muli@xxxxxxxxxx> wrote:

> The attached patch makes xenconsole send and receive console messages
> over a remote connection, instead of via stdin/stdout - if given the
> --remote switch. It is useful for proxy'ing real console message or
> other protocol messages (such as gdb) between dom0 and a remote
> host. We're currently using it for proxying gdb between gdbstub in a
> partition that talks gdb over the console page to a remote host
> running gdb.
> 
> Changed since last version:
> - fixed compile warning - type of 'buf' in handle_read_fd() should be
>   char*, not unsigned char*.
> 
> Signed-off-by: Muli Ben-Yehuda <muli@xxxxxxxxxx>

I should have spotted this before, but I'm unsure whether the message buffer
ring stuff is really needed. On the write (to the guest) side, we only read
from the tty_fd (or socket in your case) if there is space in the shared
console ring. On the read (from the guest) side, we already have a buffer
(see e.g., buffer_append() in console/daemon/io.c). It may not be the best
buffer code, and we may want to change it in future to support logging to
files, but it does work! So can you not just send a minimal patch to add
socket support? It should be really small (like 10s of lines).

 -- Keir



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel