Re: [Nbd] [Qemu-devel] Transforming stdin and stdout pair into a socket
- To: qemu-devel@...530...
- Cc: nbd-general@lists.sourceforge.net, "Ciprian Dorin, Craciun" <ciprian.craciun@...17...>, linux-newbie@...25..., Anthony Liguori <anthony@...533...>
- Subject: Re: [Nbd] [Qemu-devel] Transforming stdin and stdout pair into a socket
- From: Paul Brook <paul@...534...>
- Date: Tue, 12 May 2009 00:07:23 +0100
- Message-id: <200905120007.24881.paul@...534...>
- In-reply-to: <8e04b5820905110632q1a3b9ad4u49d4f3208d994755@...18...>
- References: <8e04b5820905101119u39ae84bfp1bae24be6e057086@...18...> <4A0813D6.3050609@...533...> <8e04b5820905110632q1a3b9ad4u49d4f3208d994755@...18...>
> I've seen socat, and I could use it as you described. My only
> objection to this solution is that there is an unneeded process in the
> middle that just pipes data around...
>
> (Instead of socat, I think it would be more efficient to just write
> a simple application that uses the "new" Linux syscall "splice" that
> I've just found by mistake yesterday...)
In that case you need to fix socat to use splice() when available. I have a
hard time believing socat adds measurable overhead, especially if you're
already tunnelling over ssh.
Paul
Reply to: