<div dir="ltr">Thanks for all your advices and opinions.<div><br></div><div>We'll try to solve the PKI issue and hope it can come back in the future.</div><div><br></div><div>About the fernet token, we'll test it with the new config options and show you the result later. Hope it performs well.</div><div><br></div><div>At last, we still have one question:</div><div>For public cloud, it is very common that multi regions are deployed. And the distance is usually very far between the regions. So the transport delay is really a problem. Fernet token requires the data must be the same. Because of the slow connection and high time delay, in our opinion, it is <span style="color:rgb(51,51,51);font-family:arial;font-size:13px">unrealistic that let the keystones from different regions to use the same keystone datacenter. Any idea about this problem? Thanks.</span></div><div><br></div><div><p class="MsoNormal" style="font-size:14px"><span lang="EN-US" style="font-size:10.5pt;color:red"> <br></span></p></div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-02-21 8:58 GMT-05:00 Dolph Mathews <span dir="ltr"><<a href="mailto:dolph.mathews@gmail.com" target="_blank">dolph.mathews@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">It appears that you don't have caching enabled, then. Without enabling caching, Fernet performance is well known to be terrible, which would explain your benchmark results. If you run a similar benchmark with caching, I'd be eager to see the new configuration and benchmark results.<div><div class="h5"><br><br><div class="gmail_quote"><div dir="ltr">On Fri, Feb 17, 2017 at 8:16 AM 王玺源 <<a href="mailto:wangxiyuan1007@gmail.com" target="_blank">wangxiyuan1007@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="m_-6087673166057692387gmail_msg"><div class="m_-6087673166057692387gmail_msg">Hi Dolph:</div></div><div class="m_-6087673166057692387gmail_msg"><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt">We made the keystone.conf same with the example.</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt">[token]</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt">provider = fernet</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"> </span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt">[fernet_tokens]   //all configuration is default</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt">#</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># From keystone</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt">#</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"> </span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># Directory containing Fernet token keys. (string value)</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt">#key_repository = /etc/keystone/fernet-keys/</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"> </span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># This controls how many keys are held in rotation by keystone-manage</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># fernet_rotate before they are discarded. The default value of 3 means that</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># keystone will maintain one staged key, one primary key, and one secondary</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># key. Increasing this value means that additional secondary keys will be kept</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># in the rotation. (integer value)</span></p><p class="MsoNormal m_-6087673166057692387gmail_msg" style="color:rgb(49,49,49);word-spacing:1px"><span lang="EN-US" class="m_-6087673166057692387gmail_msg" style="font-size:10pt"># max_active_keys = 3</span></p><div class="gmail_quote m_-6087673166057692387gmail_msg"><div class="m_-6087673166057692387gmail_msg">Dolph Mathews <<a href="mailto:dolph.mathews@gmail.com" class="m_-6087673166057692387gmail_msg" target="_blank">dolph.mathews@gmail.com</a>><wbr>于2017年2月17日 周五上午7:22写道:<br class="m_-6087673166057692387gmail_msg"></div></div></div><div class="m_-6087673166057692387gmail_msg"><div class="gmail_quote m_-6087673166057692387gmail_msg"><blockquote class="gmail_quote m_-6087673166057692387gmail_msg" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="m_-6087673166057692387gmail_msg">Thank you for the data and your test scripts! As Lance and Stanek already alluded, Fernet performance is very sensitive to keystone's configuration. Can your share your keystone.conf as well?<div class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg"></div><div class="m_-6087673166057692387gmail_msg">I'll also be in Atlanta and would love to talk Fernet performance, even if we don't have a formal time slot on the schedule.</div></div><br class="m_-6087673166057692387gmail_msg"><div class="gmail_quote m_-6087673166057692387gmail_msg"><div class="m_-6087673166057692387gmail_msg">On Wed, Feb 15, 2017 at 9:08 AM Lance Bragstad <<a href="mailto:lbragstad@gmail.com" class="m_-6087673166057692387gmail_msg" target="_blank">lbragstad@gmail.com</a>> wrote:<br class="m_-6087673166057692387gmail_msg"></div><blockquote class="gmail_quote m_-6087673166057692387gmail_msg" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="m_-6087673166057692387gmail_msg">In addition to what David said, have you played around with caching in keystone [0]? After the initial implementation of fernet landed, we attempted to make it the default token provider. We ended up reverting the default back to uuid because we hit several issues. Around the Liberty and Mitaka timeframe, we reworked the caching implementation to fix those issues and improve overall performance of all token formats, especially fernet.<div class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg"></div><div class="m_-6087673166057692387gmail_msg">We have a few different performance perspectives available, too. Some were run nearly 2 years ago [1] and some are run today [2]. Since the Newton release, we've made drastic improvements to the overall structure of the token provider [3] [4] [5]. At the very least, it should make understanding keystone's approach to tokens easier. Maintaining out-of-tree token providers should also be easier since we cleaned up a lot of the interfaces that affect developers maintaining their own providers.</div><div class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg"></div><div class="m_-6087673166057692387gmail_msg">We can try and set something up at the PTG. We are getting pretty tight for time slots, but I'm sure we can find some time to work through the issues you're seeing (also, feel free to hop into #openstack-keystone on freenode if you want to visit prior to the PTG).<div class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg"></div><div class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg"></div><div class="m_-6087673166057692387gmail_msg">[0] <a href="https://docs.openstack.org/developer/keystone/configuration.html#caching-layer" class="m_-6087673166057692387gmail_msg" target="_blank">https://docs.openstack.<wbr>org/developer/keystone/<wbr>configuration.html#caching-<wbr>layer</a></div></div><div class="m_-6087673166057692387gmail_msg">[1] <a href="http://dolphm.com/benchmarking-openstack-keystone-token-formats/" class="m_-6087673166057692387gmail_msg" target="_blank">http://dolphm.com/<wbr>benchmarking-openstack-<wbr>keystone-token-formats/</a></div><div class="m_-6087673166057692387gmail_msg">[2] <a href="https://github.com/lbragstad/keystone-performance" class="m_-6087673166057692387gmail_msg" target="_blank">https://github.com/<wbr>lbragstad/keystone-performance</a></div><div class="m_-6087673166057692387gmail_msg">[3] <a href="https://review.openstack.org/#/q/status:merged+project:openstack/keystone+branch:master+topic:make-fernet-default" class="m_-6087673166057692387gmail_msg" target="_blank">https://review.openstack.<wbr>org/#/q/status:merged+project:<wbr>openstack/keystone+branch:<wbr>master+topic:make-fernet-<wbr>default</a></div><div class="m_-6087673166057692387gmail_msg">[4] <a href="https://review.openstack.org/#/q/status:merged+project:openstack/keystone+branch:master+topic:cleanup-token-provider" class="m_-6087673166057692387gmail_msg" target="_blank">https://review.openstack.<wbr>org/#/q/status:merged+project:<wbr>openstack/keystone+branch:<wbr>master+topic:cleanup-token-<wbr>provider</a></div><div class="m_-6087673166057692387gmail_msg">[5] <a href="http://specs.openstack.org/openstack/keystone-specs/specs/keystone/ocata/token-provider-cleanup.html" class="m_-6087673166057692387gmail_msg" target="_blank">http://specs.openstack.<wbr>org/openstack/keystone-specs/<wbr>specs/keystone/ocata/token-<wbr>provider-cleanup.html</a></div></div><div class="gmail_extra m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg"><div class="gmail_quote m_-6087673166057692387gmail_msg">On Wed, Feb 15, 2017 at 8:44 AM, David Stanek <span class="m_-6087673166057692387gmail_msg"><<a href="mailto:dstanek@dstanek.com" class="m_-6087673166057692387gmail_msg" target="_blank">dstanek@dstanek.com</a>></span> wrote:<br class="m_-6087673166057692387gmail_msg"><blockquote class="gmail_quote m_-6087673166057692387gmail_msg" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="m_-6087673166057692387gmail_msg">On 15-Feb 18:16, 王玺源 wrote:<br class="m_-6087673166057692387gmail_msg">
> Hello everyone,<br class="m_-6087673166057692387gmail_msg">
>   PKI/PKIZ token has been removed from keystone in Ocata. But recently our<br class="m_-6087673166057692387gmail_msg">
> production team did some test about PKI and Fernet token (With Keystone<br class="m_-6087673166057692387gmail_msg">
> Mitaka). They found that in large-scale production environment, Fernet<br class="m_-6087673166057692387gmail_msg">
> token's performance is not as good as PKI. Here is the test data:<br class="m_-6087673166057692387gmail_msg">
><br class="m_-6087673166057692387gmail_msg">
> <a href="https://docs.google.com/document/d/12cL9bq9EARjZw9IS3YxVmYsGfdauM25NzZcdzPE0fvY/edit?usp=sharing" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">https://docs.google.com/<wbr>document/d/<wbr>12cL9bq9EARjZw9IS3YxVmYsGfdauM<wbr>25NzZcdzPE0fvY/edit?usp=<wbr>sharing</a><br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
</span>This is nice to see. Thanks.<br class="m_-6087673166057692387gmail_msg">
<span class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
><br class="m_-6087673166057692387gmail_msg">
> From the data, we can see that:<br class="m_-6087673166057692387gmail_msg">
> 1. In large-scale concurrency test, PKI is much faster than Fernet.<br class="m_-6087673166057692387gmail_msg">
> 2. PKI token revoke can't immediately make the token invalid. So it has the<br class="m_-6087673166057692387gmail_msg">
> revoke issue.  <a href="https://wiki.openstack.org/wiki/OSSN/OSSN-0062" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">https://wiki.openstack.org/<wbr>wiki/OSSN/OSSN-0062</a><br class="m_-6087673166057692387gmail_msg">
><br class="m_-6087673166057692387gmail_msg">
> But in our production team's opinion, the revoke issue is a small problem,<br class="m_-6087673166057692387gmail_msg">
> and can be avoided by some periphery ways. (More detail solution could be<br class="m_-6087673166057692387gmail_msg">
> explained by them in the follow email).<br class="m_-6087673166057692387gmail_msg">
> They think that the performance issue is the most important thing. Maybe<br class="m_-6087673166057692387gmail_msg">
> you can see that in some production environment, performance is the first<br class="m_-6087673166057692387gmail_msg">
> thing to be considered.<br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
</span>I'd like to hear solutions to this if you have already come up with<br class="m_-6087673166057692387gmail_msg">
them. This issue, however, isn't the only one that led us to remove PKI<br class="m_-6087673166057692387gmail_msg">
tokens.<br class="m_-6087673166057692387gmail_msg">
<span class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg">
><br class="m_-6087673166057692387gmail_msg">
> So here I'd like to ask you, especially the keystone experts:<br class="m_-6087673166057692387gmail_msg">
> 1. Is there any chance to bring PKI/PKIZ back to Keystone?<br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
</span>I would guess that, at least in the immediate future, we would not want<br class="m_-6087673166057692387gmail_msg">
to put it back into keystone until someone can fix the issues. Also<br class="m_-6087673166057692387gmail_msg">
ideally running the token provider in production.<br class="m_-6087673166057692387gmail_msg">
<span class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
> 2. Has Fernet token improved the performance during these releases? Or any<br class="m_-6087673166057692387gmail_msg">
> road map so that we can make sure Fernet is better than PKI in all side.<br class="m_-6087673166057692387gmail_msg">
> Otherwise, I don't think that remove PKI in Ocata is the right way. Or<br class="m_-6087673166057692387gmail_msg">
> even, we can keep the PKI token in Keystone for more one or two cycles,<br class="m_-6087673166057692387gmail_msg">
> then remove it once Fernet is stable enough.<br class="m_-6087673166057692387gmail_msg">
> 3. Since I'll be in Atalanta next week, if it is possible, I'd like to<br class="m_-6087673166057692387gmail_msg">
> bring this topic to Keystone PTG. can I?<br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
</span>Sure. We have a pretty packed calendar, but I'm sure you could steal a<br class="m_-6087673166057692387gmail_msg">
few minutes somewhere.<br class="m_-6087673166057692387gmail_msg">
<span class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
><br class="m_-6087673166057692387gmail_msg">
> It is a real production problem and I really need your feedback.<br class="m_-6087673166057692387gmail_msg">
><br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
</span>Have you tried playing with the crypt_strength[1]? If the slowness is<br class="m_-6087673166057692387gmail_msg">
the crypto (which it was in the past) then you can tune it a little bit.<br class="m_-6087673166057692387gmail_msg">
Another option might be to keep the same token flow and find a faster<br class="m_-6087673166057692387gmail_msg">
method for hashing a token.<br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
1. <a href="http://git.openstack.org/cgit/openstack/keystone/tree/etc/keystone.conf.sample#n67" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">http://git.openstack.org/cgit/<wbr>openstack/keystone/tree/etc/<wbr>keystone.conf.sample#n67</a><br class="m_-6087673166057692387gmail_msg">
<span class="m_-6087673166057692387m_7081920356098650683m_8988156122541353013m_1400072414767181363HOEnZb m_-6087673166057692387gmail_msg"><font color="#888888" class="m_-6087673166057692387gmail_msg"><br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
--<br class="m_-6087673166057692387gmail_msg">
david stanek<br class="m_-6087673166057692387gmail_msg">
web: <a href="https://dstanek.com" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">https://dstanek.com</a><br class="m_-6087673166057692387gmail_msg">
twitter: <a href="https://twitter.com/dstanek" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">https://twitter.com/dstanek</a><br class="m_-6087673166057692387gmail_msg">
<br class="m_-6087673166057692387gmail_msg">
______________________________<wbr>______________________________<wbr>______________<br class="m_-6087673166057692387gmail_msg">
OpenStack Development Mailing List (not for usage questions)<br class="m_-6087673166057692387gmail_msg">
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">OpenStack-dev-request@lists.<wbr>openstack.org?subject:<wbr>unsubscribe</a><br class="m_-6087673166057692387gmail_msg">
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">http://lists.openstack.org/<wbr>cgi-bin/mailman/listinfo/<wbr>openstack-dev</a><br class="m_-6087673166057692387gmail_msg">
</font></span></blockquote></div><br class="m_-6087673166057692387gmail_msg"></div>
______________________________<wbr>______________________________<wbr>______________<br class="m_-6087673166057692387gmail_msg">
OpenStack Development Mailing List (not for usage questions)<br class="m_-6087673166057692387gmail_msg">
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">OpenStack-dev-request@lists.<wbr>openstack.org?subject:<wbr>unsubscribe</a><br class="m_-6087673166057692387gmail_msg">
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">http://lists.openstack.org/<wbr>cgi-bin/mailman/listinfo/<wbr>openstack-dev</a><br class="m_-6087673166057692387gmail_msg">
</blockquote></div><div class="m_-6087673166057692387gmail_msg">-- <br class="m_-6087673166057692387gmail_msg"></div><div data-smartmail="gmail_signature" class="m_-6087673166057692387gmail_msg"><div class="m_-6087673166057692387gmail_msg">-Dolph</div></div>
______________________________<wbr>______________________________<wbr>______________<br class="m_-6087673166057692387gmail_msg">
OpenStack Development Mailing List (not for usage questions)<br class="m_-6087673166057692387gmail_msg">
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">OpenStack-dev-request@lists.<wbr>openstack.org?subject:<wbr>unsubscribe</a><br class="m_-6087673166057692387gmail_msg">
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">http://lists.openstack.org/<wbr>cgi-bin/mailman/listinfo/<wbr>openstack-dev</a><br class="m_-6087673166057692387gmail_msg">
</blockquote></div></div>
______________________________<wbr>______________________________<wbr>______________<br class="m_-6087673166057692387gmail_msg">
OpenStack Development Mailing List (not for usage questions)<br class="m_-6087673166057692387gmail_msg">
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">OpenStack-dev-request@lists.<wbr>openstack.org?subject:<wbr>unsubscribe</a><br class="m_-6087673166057692387gmail_msg">
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" class="m_-6087673166057692387gmail_msg" target="_blank">http://lists.openstack.org/<wbr>cgi-bin/mailman/listinfo/<wbr>openstack-dev</a><br class="m_-6087673166057692387gmail_msg">
</blockquote></div></div></div></div><span class="HOEnZb"><font color="#888888"><div dir="ltr">-- <br></div><div data-smartmail="gmail_signature"><div dir="ltr">-Dolph</div></div>
</font></span><br>______________________________<wbr>______________________________<wbr>______________<br>
OpenStack Development Mailing List (not for usage questions)<br>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" target="_blank">OpenStack-dev-request@lists.<wbr>openstack.org?subject:<wbr>unsubscribe</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" target="_blank">http://lists.openstack.org/<wbr>cgi-bin/mailman/listinfo/<wbr>openstack-dev</a><br>
<br></blockquote></div><br></div>