qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] about DHCP server in qemu


From: Jim C. Brown
Subject: Re: [Qemu-devel] about DHCP server in qemu
Date: Fri, 30 Sep 2005 17:59:38 -0400
User-agent: Mutt/1.4i

On Fri, Sep 30, 2005 at 11:28:53AM -0700, John R. Hogerhuis wrote:
> Nearly? Oh come on... you know it ain't possible, period.
> 

What are you refering to? The ability of a single qemu to ping thru slirp,
or the ability of multiple qemus to ping each other using their guest ips?

The former can be done, as explained below, but it is probably more trouble
than its worth. The latter can not be done at all *IF* the guests have to
communicate thru the slirp layer. However, if the slirp layer is just used to
talk to the host and the LAN/internet and you have something else that deals
with guest-to-guest, then this can be done. slirpvde comes to mind here.

> Ping (ICMP) operates at the IP level. An unprivileged socket, which is
> what user-net (slirp) uses can only send/receive packets at the ported
> protocols level, which means UDP or TCP.
> 

Actually, it is really easy to add ping support to qemu using sockets. The only
issue here is privilege. (You need to be root in order to be able to use an
ICMP socket.)

An alternative would be to use "/sbin/ping -c 1" and parse its output in order
to simulate an actual ICMP connection. This is considerably harder, but 
definitely
possible.

-- 
Infinite complexity begets infinite beauty.
Infinite precision begets infinite perfection.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]