[openstack-dev] [Nova] too many tokens
Joe Gordon
joe.gordon0 at gmail.com
Mon Jul 8 13:56:15 UTC 2013
On Jul 3, 2013 5:22 PM, "Ala Rezmerita" <ala.rezmerita at cloudwatt.com> wrote:
>
> Hi everyone,
>
> I have a question regarding too many token generation in nova when using
quantumclient (also related to bug reports
https://bugs.launchpad.net/nova/+bug/1192383 +
https://bugs.launchpad.net/nova-project/+bug/1191159)
>
> For instance during the periodic task heal_instance_info_cache (every
60s) nova calls quantum API method get_instance_nw_info that calls
_build_network_info_model (backtrace at the end of the mail).
>
> During the execution of this method, 4 quantum clients intances are
created (all of them use the same context object) and for each of them a
new token is generated.
>
> Is it possible to change this behavior by updating the context.auth_token
property the first time a quantumclient for a given context is created (so
that the same token will be reused among the 4 client instances) ? Is
there some security issue that can appear?
We have this issue elsewhere, too many tokens being generated because the
clients aren't caching the tokens across client instances. So why not try
to fix that instead, as solving that once and for all will fix many other
use cases as well?
I know some attempts have been made at this but clearly they are not
working for most people.
>
> Thanks
>
> Ala Rezmerita
> Cloudwatt
>
> The backtrace :
>
>
/usr/local/lib/python2.7/dist-packages/eventlet/greenthread.py(194)main()
> -> result = function(*args, **kwargs)
> /opt/stack/nova/nova/openstack/common/loopingcall.py(125)_inner()
> -> idle = self.f(*self.args, **self.kw)
> /opt/stack/nova/nova/service.py(283)periodic_tasks()
> -> return self.manager.periodic_tasks(ctxt, raise_on_error=raise_on_error)
> /opt/stack/nova/nova/manager.py(100)periodic_tasks()
> -> return self.run_periodic_tasks(context, raise_on_error=raise_on_error)
>
/opt/stack/nova/nova/openstack/common/periodic_task.py(179)run_periodic_tasks()
> -> task(self, context)
> /opt/stack/nova/nova/compute/manager.py(3654)_heal_instance_info_cache()
> -> self._get_instance_nw_info(context, instance)
> /opt/stack/nova/nova/compute/manager.py(767)_get_instance_nw_info()
> -> instance, conductor_api=self.conductor_api)
> /opt/stack/nova/nova/network/quantumv2/api.py(367)get_instance_nw_info()
> -> result = self._get_instance_nw_info(context, instance, networks)
>
/opt/stack/nova/nova/network/quantumv2/api.py(375)_get_instance_nw_info()
> -> nw_info = self._build_network_info_model(context, instance, networks)
>
/opt/stack/nova/nova/network/quantumv2/api.py(840)_build_network_info_model()
> -> client = quantumv2.get_client(context, admin=True)
> > /opt/stack/nova/nova/network/quantumv2/__init__.py(67)get_client()
>
> _______________________________________________
> OpenStack-dev mailing list
> OpenStack-dev at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20130708/0fed315c/attachment.html>
More information about the OpenStack-dev
mailing list