
On Thu, May 12, 2016 at 10:31:34AM +0200, Andrea Bolognani wrote:
On Thu, 2016-05-12 at 09:58 +0200, Jiri Denemark wrote:
On Wed, May 11, 2016 at 11:57:36 -0400, Laine Stump wrote:
I reverted these three patches that introduced and enabled a "peer" attribute for type='ethernet' interface <ip> elements prior to the release of 1.3.4 with the intent of fixing/re-posting them after release, but forgot until today:
https://www.redhat.com/archives/libvir-list/2016-April/msg01995.html
I have patches for most of the bugs, but the one problem that still doesn't have resolution is the naming of the "peer" attribute. In my opinion, having the two address attributes named "address" and "peer" makes it ambiguous which address is for the guest side and which for the host side (especially since the attribute that has been named "peer" would be set to the "address" in the netlink command, and the attribute named "address" would be set to "peer" in the netlink command :-O).
Since "address" is an existing attribute, and already used for the guest side IP address in lxc type='bridge' interfaces, it must remain as-is. In order to make it obvious that the new address is for the host side of the tap (or veth pair in the case of lxc), I propose calling it either "host", or "hostAddress", e.g:
<ip address='192.168.123.43' host='192.168.123.1' prefix='25'/>
or
<ip address='192.168.123.4' hostAddress='192.168.123.1' prefix='25'/>
IMO "host" is better. After all it's an attribute of "ip" element so it's obvious we're talking about addresses here.
I like "hostAddress" better myself :)
Is there any real chance the "prefix" attribute will need to be specified for the host as well? Because in that case we would clearly have to go with "hostPrefix", and using "host" instead of "hostAddress" would look quite ugly.
Both IP addresses are required to be in the same subnet and thus have the same prefix Regards, Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|