All of lore.kernel.org
 help / color / mirror / Atom feed
From: Erdem Bayer <ebayer@ttnet.net.tr>
To: Keir Fraser <Keir.Fraser@cl.cam.ac.uk>, xen-devel@lists.xensource.com
Subject: Re: nat does not work with hvm
Date: Wed, 25 Apr 2007 17:10:49 +0300	[thread overview]
Message-ID: <462F6169.2060606@ttnet.net.tr> (raw)
In-Reply-To: <C2466939.5DAB%Keir.Fraser@cl.cam.ac.uk>

Hi

Keir Fraser wrote On 14-04-2007 13:19:
>
> Vif-nat isn't run in this case.
>
> Well actually it is run in 3.0.4 (but not in the very latest xen-unstable
> repository, so not in the forthcoming Xen 3.0.5). But it'll get run on the
> wrong interface. The vif2.0, or whatever, interfaces aren't used by qemu.
> qemu creates its own tap interface and the qemu-ifup script is executed to
> configure that tap interface.
>
>  -- Keir
>
>   

In xen-unstable vif-nat scripts still runs with qemu-ifup script, when a 
hvm domain is booted. There are some problems with that. First of all, 
an un-needed vif interface is created and configured with the values 
from the hvm configuration file, and you can not write a qemu-ifup 
script that takes same info from config file. (for example you cannot 
configure the ip address of your tap interface because that ip is taken 
by vif interface, wrongly.)

Also I strongly believe that a qemu-ifdown script is needed. For example 
if you write some iptables rules in qemu-ifup, then these rules should 
be deleted from iptables when the domain goes down.

Please correct me if I am wrong. I think there should be only one 
network script per config, (ex: vif-nat, vif-bridge, etc) and that 
script should determine whether the domain is a hvm or a modified one 
and make necessary configuration accordingly. This way there is no need 
for seperate scripts for qemu and vif and when a qemu domain shuts down, 
it's settings can be de-configured properly. Or as an alternative there 
should be two script for each config (ex. vif-nat-qemu + vif-nat-other) 
and but only one of them should be executed.

So the question is: What is the plan about implementing other types of 
network scripts in qemu domains? Is this discussed or planned? If not I 
want to make the necessary changes. I figured that tools/ioemu/vl.c is 
responsible for creating a hvm domain and execute the correct network 
script. But I could not figure out what piece of code is responsible for 
calling the network script with necessary parameters when a modified 
guest boots. Also are these changes that I propose are acceptable (or 
reasonable at least)? I would appreciate if you share your knowledge and 
ideas about this matter.

Thanks
Erdem

  parent reply	other threads:[~2007-04-25 14:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <C2466939.5DAB%Keir.Fraser@cl.cam.ac.uk>
2007-04-17 11:32 ` nat does not work with hvm Erdem Bayer
2007-04-17 14:42   ` Keir Fraser
2007-04-25 14:10 ` Erdem Bayer [this message]
2007-04-14  6:24 Erdem Bayer
2007-04-14  9:37 ` Keir Fraser
2007-04-14  6:56   ` Erdem Bayer
2007-04-14 10:08     ` Keir Fraser

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=462F6169.2060606@ttnet.net.tr \
    --to=ebayer@ttnet.net.tr \
    --cc=Keir.Fraser@cl.cam.ac.uk \
    --cc=xen-devel@lists.xensource.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.