Comment 0 for bug 1182830

Version of Nova Grizzly.
I tried to configure controller node and compute node work together using pure IPv6.

 Edit nova.conf file and quantum.conf file,
 Set the host-address( for example: qpid_hostname, glance_api_servers ...) to [2001:db8::22](the ip-address of the controller node)

 When to boot an instance then the compute node to get images, there was an ERROR in
     file: nova/image/ ,
     function: get_api_servers():
                           o = urlparse.urlparse(api_server)
                           port = o.port or 80
                           host = o.netloc.split(":", 1)[0]

     It reported an ERROR if the argument "api_server" is a ipv6 address( for example: [])

In /nova/openstack/common/, there is a function parse_host_port() which could pares the ipv6 address correctly.
So I tried to use this function instead of the current bug code. But after that the variable "host" is "2001:db8::22" without '[]' that caused other problems, for example in
   file: /glanceclient/common/http/py
   Class HTTPClient()
       _init_(self, endpoint, **kwargs)

   the endpoint is "http://2001:db8::22:9292" without '[]'

Anyway, The current code could not parse ipv6 address correctly. There were also similar problems in other places of the code.