From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FWJv8-0007oa-7o for qemu-devel@nongnu.org; Wed, 19 Apr 2006 17:09:06 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FWJv6-0007oO-RY for Qemu-devel@nongnu.org; Wed, 19 Apr 2006 17:09:05 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FWJv6-0007oL-NQ for Qemu-devel@nongnu.org; Wed, 19 Apr 2006 17:09:04 -0400 Received: from [71.36.29.88] (helo=mail.redfish-solutions.com) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1FWJwH-0008LP-Rv for Qemu-devel@nongnu.org; Wed, 19 Apr 2006 17:10:18 -0400 Received: from [10.42.2.147] ([167.234.164.206]) (authenticated bits=0) by mail.redfish-solutions.com (8.13.1/8.13.1) with ESMTP id k3JL8uiv023212 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Wed, 19 Apr 2006 15:08:59 -0600 Message-ID: <4446A848.6000203@redfish-solutions.com> Date: Wed, 19 Apr 2006 15:14:48 -0600 From: Philip Prindeville MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Noob question on Linux networking Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Qemu-devel@nongnu.org Hi. I was looking at the way that Qemu works under Linux, and was surprised by the complexity required to configure networking. I worked on a software harness on SunOS 3.5 17 years ago, and things seemed to be a bit simpler then.... You could create a "software" network interface cloned from a real physical interface (as long as it was a broadcast or multipoint network) and create a new, unique address to that interface. For instance, you could clone an ethernet interface, give it a new IP address, and even set up new services running just on that interface... This assumed that the Ethernet driver and hardware supported having multiple MAC addresses that it recognized as its own (usually implemented in a CAM as a key and mask... the mask would be applied to the destination address and compared to the key... usually the mask would be 48-bits of ones, i.e. match the entire key)... which most but not all controllers could do. These days, I think just about any controller will allow you do this, even a lowly RealTek-8129. So... my question is, why not create a mac-level interface alias, generate a separate unique mac address, and have Qemu use this as the client OS's interface? Then the client OS could see all of the same things as the host OS, and they should even be able to ping each other (well, it depends... some Ethernet interfaces "hear" themselves when they transmit... some don't). What would be involved in doing this? Not sure that current Linux kernel drivers support creating additional destination addresses through a standardized interface... I'll look into it. -Philip