public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Liang Guo <bluestonechina@gmail.com>
Cc: "kvm@vger.kernel.org" <kvm@vger.kernel.org>
Subject: Re: User mode network cause other network doesn't work any more
Date: Fri, 02 Sep 2011 17:42:52 +0200	[thread overview]
Message-ID: <4E60F97C.5040703@siemens.com> (raw)
In-Reply-To: <CAJwrgW68Ud1uRJTnhftYJ10GFrg+7i17MpXbMtoSt0V2mEUGvA@mail.gmail.com>

On 2011-09-02 17:41, Liang Guo wrote:
> On Fri, Sep 2, 2011 at 10:42 PM, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>> On 2011-09-02 15:59, Liang Guo wrote:
>>> Hi,
>>>
>>> When I run kvm with following option:
>>>
>>>          -net nic -net vde,sock=/var/run/vde2/vde3.ctl
>>>
>>> the guest OS's network work as expected, I can ping/ssh from/to host OS,
>>> but when I run kvm with:
>>>
>>>         -net nic -net user -net nic -net vde,sock=/var/run/vde2/vde3.ctl
>>
>> That's probably the classic mistake: You create one virtual LAN inside
>> QEMU this way. Attached to this LAN are all four peers (two NICs, slirp
>> and VDE).
> Thank you pointing this out, I thought '-net nic' and '-net user|tap|vd' was
> connected with their sequence.
> 
>>
>> What you likely want are two backend/frontend pairs:
>> -net nic,netdev=net1 -net user,id=net1 \
>> -net nic,netdev=net2 -net vde,sock=/var/run/vde2/vde3.ctl,id=net2
>>
>> Jan
> I can reach my object with
> 
> -netdev user,id=eth0  -device virtio-net-pci,netdev=eth0 \
> -netdev vde,sock=/var/run/vde2/vde3.ctl,id=eth1 -device
> virtio-net-pci,netdev=eth1
> 
> or
> 
> -net nic,vlan=1 -net user,vlan=1 \
> -net nic,vlan=2 -net vde,sock=/var/run/vde2/vde3.ctl,vlan=2

Err, yeah, I also confused the syntax. :)

Jan

-- 
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux

      reply	other threads:[~2011-09-02 15:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-02 13:59 User mode network cause other network doesn't work any more Liang Guo
2011-09-02 14:42 ` Jan Kiszka
2011-09-02 15:41   ` Liang Guo
2011-09-02 15:42     ` Jan Kiszka [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E60F97C.5040703@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=bluestonechina@gmail.com \
    --cc=kvm@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox