qemu-discuss
[Top][All Lists]
Advanced

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

Re: [Qemu-discuss] changing from net to netdev with vde switches and dou


From: Paolo
Subject: Re: [Qemu-discuss] changing from net to netdev with vde switches and double nics
Date: Wed, 30 Aug 2017 08:03:57 +0200

Hi Thomas,

thank you for your interest in the question

> On Tue, 29 Aug 2017 11:48:20 +0200
> Thomas Huth <address@hidden> wrote:  
[cut]
> That's interesting, I think you're the first person I know in months or
> even years who really seems to be using the vlan=x parameter (with x >=
> 1)...  

I currently can't see any other way to realize this topology:
                       
NIC_0.1-----------------------|
  |                           |
  |               NIC_0.N----SWITCH_0(on HOST)<>Internet
  |                 |
GUEST_1   ...   GUEST_N                                     
  |                 |
  |               NIC_1.N-----|    
  |                          SWITCH_1(on HOST)>SambaServer(on HOST)
NIC_1.1-----------------------|

> You're right, you can not translate your setup 1:1 to -netdev anymore,
> since there are no 'vlan's (or rather hubs, since 'vlan' is rather a
> misnomer here) available with the -netdev parameter.  

This might be a problem for me, as I explain later 

> Question is: Why do you need it at all? I see your point that you want
> to have two network cards, but why does each NIC has to be wired to two
> host networks (vde *and* tap)? Isn't it sufficient if you connect each
> NIC to one VDE network?  

Easily: by ignorance. I wrote that script (about 8 years ago) with almost zero 
knowledge of networking and difference between tap, vde (and much more stuff), 
sort of a Frankenstein-style patchwork inspired by midnight readings of the 
various howtos on internet. Quite a mess and a long and painful trial-and-error 
race. Nor that today I might be regarded as an expert in networking, I didn't 
progress very much (as it's not my job anyway).

Back on topic, following your hint, I've tried just know that all I need is 
vde, and everything works fine:

 NET0="-net vde,vlan=0,sock=/var/run/vde.ctl00 -net 
nic,vlan=0,model=rtl8139,macaddr=$NIC0MAC"
 NET1="-net vde,vlan=1,sock=/var/run/vde.ctl01 -net 
nic,vlan=1,model=rtl8139,macaddr=$NIC1MAC"

Now I guess this is impossbile to achieve with netdev?

How may I tell to qemu that the guest's NIC0 has to be wired to the vde switch 
vde.ctl00 (run on host), and NIC1 to vde.ctl01?
Also hubport function is unclear to me. It reproduces the previous vlan 
concept, but it's left orphan, because no other devices seems to be made aware 
that hubport_n exists, nor looks to me that they could be wired to it.

Is there a feasible way to have the same network layout with netdev in place of 
net? Any hint on alternative ways to do it?

  Paolo



reply via email to

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