[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: [libvirt] VirtualBox libvirt support sample XML file
- From: Pritesh Kothari <Pritesh Kothari Sun COM>
- To: libvir-list redhat com, "Daniel P. Berrange" <berrange redhat com>
- Cc:
- Subject: Re: [libvirt] VirtualBox libvirt support sample XML file
- Date: Thu, 16 Apr 2009 13:42:11 +0200
Hi Daniel,
> > <!--INTERNAL NETWORK -->
> > <interface type='network'>
> > <source network='int_net'/>
> > <model type='am79c970a'/>
> > </interface>
> >
> > <!-- HOST ONLY NETWORK -->
> > <interface type='ethernet'>
> > <source dev='vboxnet0'/>
> > <mac address='78:16:3e:4d:c7:9e'/>
> > <model type='82543gc'/>
> > </interface>
>
> The Bridge & NAT mappings you've defined here seem to make
> good sense.
>
> I'm not so sure about the INTERNAL and HOST ONLY modes
> though.
>
> With the <interface type='network'> configuration, the
> source network is expected to refer to a network visible
> and managed via the virNetwork* APIs.
>
> In QEMU / Xen drivers, we have a generic network driver
> impl that uses a bridge device, dnsmasq & iptables to
> allow guests to talk to each other, optionaly talk to the
> host, and then optionally have NAT connectivity to the
> outside world. This is the src/network_driver.c impl of
> the virNetwork* APIs.
>
> Conceptually the virNetwork APIs & their functionality ought
> to map nicely onto the both the INTERNAL and HOST ONLY
> networks modes virtual box has.
>
> The HOST ONLY mode, would map to a config without a
> <forward> tag (so guests & host can talk to each other).
> The INTERNAL mode, wouldmap toa config without an
> <ip> tag (so guests can talk to each other, but not host)
>
>
> What I'm not clear on is where / how VirtualBox configures its
> HOST ONLY and INTERNAL networks ? Does it have APIs for managing
> these 2 configs as objects in their own right ? Or are they managed
> implicilty via the VM config. The RPC stub code you posted earlier
> does not appear to have any APIs for directly configuring the
> HOST ONLY / INTERNAL network configs, independantly of the VM config
> I might be mis-reading something though..
>
> I'm inclined to suggest that virtual box driver should provide its own
> impl of the virNetwork internal driver API, in order to allow direct
> managemnet of the HOST ONLY & INTENRAL networks. Then for VM NICs,
> both those would be done via a <interface type='network'> element.
I am not sure if "Host only" and "internal" network deserves a full
implementation of the virNetwork internal driver API because they are not
exposed as separate objects, instead each network card can be individually
specified as having "Host only" or "Internal" network configuration and
VirtualBox handles rest, so all i need is a way to specify which network type
to use and an IPAddr if possible and thus I had map-ed them as above.
Currently the only way I can think of simplifying it is adding "Host Only"
and "Internal" to the XML parsing and using it.
Regards,
Pritesh
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]