From mboxrd@z Thu Jan 1 00:00:00 1970 From: Charles Duffy Subject: Re: Trouble understanding net config options Date: Wed, 15 Jul 2009 19:03:43 -0500 Message-ID: <4A5E6E5F.9010208@messageone.com> References: <20090715231219.GZ2455@nerd.dk> <20090715232414.GO2003@arachsys.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit To: kvm@vger.kernel.org Return-path: Received: from main.gmane.org ([80.91.229.2]:41798 "EHLO ciao.gmane.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753477AbZGPADo (ORCPT ); Wed, 15 Jul 2009 20:03:44 -0400 Received: from list by ciao.gmane.org with local (Exim 4.43) id 1MRERr-0001MF-W3 for kvm@vger.kernel.org; Thu, 16 Jul 2009 00:03:44 +0000 Received: from 143.166.197.6 ([143.166.197.6]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 16 Jul 2009 00:03:43 +0000 Received: from Charles_Duffy by 143.166.197.6 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 16 Jul 2009 00:03:43 +0000 In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: Michael Jinks wrote: > On Wed, Jul 15, 2009 at 6:24 PM, Chris Webb wrote: >> You want >> >> -net nic,vlan=0 -net tap,vlan=0,ifname=tap11 -net nic,vlan=1 -net tap,vlan=1,ifname=tap12 > > Progress! This works, I can bring up the guest and watch it boot, but > both of its NICs came up bound to the first bridge on the system. > > I can work around that using 'brctl delif' and 'brctl addif' on the > host system, but how would I automate it so that, say, tap11 always > goes to br1, and tap12 always goes to br0? I guess by taking out the > brctl in the kvm ifup script, and pre-setting all my bridge/tap > connections? Use the script= argument on the -net tap,vlan=1 to use a qemu-ifup script which connects the tap device to the bridge you'd prefer be used.