From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:37195) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QKhVS-000820-Ph for qemu-devel@nongnu.org; Thu, 12 May 2011 21:49:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QKhVR-0006fR-SM for qemu-devel@nongnu.org; Thu, 12 May 2011 21:49:30 -0400 Received: from mail-iw0-f173.google.com ([209.85.214.173]:38934) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QKhVR-0006fG-MY for qemu-devel@nongnu.org; Thu, 12 May 2011 21:49:29 -0400 Received: by iwl42 with SMTP id 42so2228429iwl.4 for ; Thu, 12 May 2011 18:49:29 -0700 (PDT) Message-ID: <4DCC8E21.3030405@landley.net> Date: Thu, 12 May 2011 20:49:21 -0500 From: Rob Landley MIME-Version: 1.0 References: <4DCB486F.70509@landley.net> <4DCC8523.2000501@landley.net> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] -net interface association behavior change in current -git. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Vincent Palatin Cc: blauwirbel@gmail.com, qemu-devel@nongnu.org On 05/12/2011 08:19 PM, Vincent Palatin wrote: >>> First of all, as you have 2 totally separated subnets in your setup, I >>> think your command-line should use "vlan=" parameter to isolate them, >>> else you will end up with some random routing/broadcasting (and random >>> tends to change over time). >> >> Does the kernel need some sort of vlan support compiled into it for this >> to work, or can the kernel not care? > > You don't need anything in your kernel, this is for Qemu network layer > configuration. Oh good. (The kernel has a couple different VLAN config options, plus cisco has vlan stuff in its routers... I've been trying not to get any of this complexity on me.) >>> In my understanding, the Linux kernel might assign interface number >>> depending on the order the interfaces are appearing. >> >> It's going in PCI bus order. And the _interfaces_ are still happily in >> PCI bus order both before and after this commit. What's changing is the >> association between interface and -net user or -net tap. >> >> The first one, with macaddr 11:11:11, is always eth0. But before the >> patch, eth0 is -net user, and after the patch eth0 is -net tap. > > So, did you try the vlan parameter which is supposed to associate each > interface with the proper thing (IMO the command line order should not > have anything to do with it) ? Apparently you cannot stick a vlan on -redir, and if you do the error message is a bit funky (cannot initialize -net user). Good to know... Yup, that fixed it. Thanks. By the way, does -redir only apply to -net user? Actually, reading qemu --help it looks like I should be using hostfwd= but the documentation on that is REALLY WEIRD: This option can not be given multiple times, but multiple rules may be combined. ... To combine two or more hostfwd rules, simply use a comma as a delimiter. For example, to combine the two rules mentioned in the examples above, use the following: #on the host qemu -net user,hostfwd=tcp:127.0.0.1:6001-:6000,hostfwd=tcp:5555-::23 Define "may not be given multiple times"...? Oh well, specifying one of 'em seems to work. Thanks. As you can tell, confusion is sort of my ground state, Rob