[virt-tools-list] IPv6 support

Gene Czarcinski gene at czarc.net
Tue Mar 19 18:22:59 UTC 2013


On 03/18/2013 05:03 PM, Gene Czarcinski wrote:
> OK, my skill with python is somewhere between zero and none but such a 
> handicap has never deterred me before.  Therefore, I am going to 
> attempt to add IPv6 support for virtual networks to virt-manager.
>
> 1.  It appears that the interface code has full IPv6 support so that 
> might provide a guide as to how to do things.
>
> 2.  If only the network code had used prefixes and stayed away from 
> netmask for IPv4, basic support for IPv6 might have been a simple.
>
> 3.  The IPy.py module is a bit out-of-date (if that matters) and lacks 
> one or two functions.  I will need to add the functionality and/or 
> replace IPy.py with the supported pyton-ipaddr module. There is also 
> an ipaddress module in python3.  Using something with support is 
> usually better but it will require changing much more code.  For a 
> while, both IPy.py and ipaddr may be in use.
>
> 4.  My initial goal to to have virt-manager/connections not "die" when 
> an IPv6 address appears in a network definition.  That and being able 
> to start, stop, delete, and enable at boot ... creation will be later.
>
> 5. Right now, libvirt wants an IPv6 address specified and not an IPv6 
> network.  The address is needed most of the time so that dnsmasq can 
> run as a dns, dhcpv6 and RA server.  vm/connections wants a IPv6 
> network specification ... that is, the prefix applied so that all the 
> "lower" bits are set to zero.
>
> 6.  I will be using the gtk3.2 branch for this development.
>
> Comment, suggestions, or whatever ??
>
OK, some initial reactions/comments ...

1.  IPy.py is going to go away and the python-ipaddr will be used in its 
place.

2.  The problem is not IPv6 so much as it is xml.  virt-manager is not 
doing a real good job of scanning the network xml because it only picks 
up the first <ip> definition.

3.  There is also the glade-gui interface and here I could use some 
advice/direction.  There are at least four ways I could do it:

   a) Add another section to the vbox and list IPv6 Configuration the 
same as IPv4.
   b) Make it a tabbed (notebook) subpanel.
   c) Use drop-downs like what is done for interface.
   d) Create a tree-display on the fly (this may have the advantage of 
being able to handle more than 2 IPs.

BTW, there are other types of IP specifications such as dhcp-host and 
the (pending) new libvirt capability to add ip-route specifications to 
the virtual-network-bridge.

Gene




More information about the virt-tools-list mailing list