<html><head></head><body bgcolor="#FFFFFF"><div>The admin_token config is being used to bypass to normal authentication process, thereby avoiding the issue.</div><div><br></div><div>Can you paste the rest of your authtoken config? Also, try token-get against 5000, and then try the resulting token as your admin_token value.<br><br>-Dolph Mathews</div><div><br>On May 12, 2012, at 12:01 PM, Shashi Kanth Boddula <<a href="mailto:shashi.bsd@gmail.com">shashi.bsd@gmail.com</a>> wrote:<br><br></div><div></div><blockquote type="cite"><div># keystone user-list<br>+----------------------------------+---------+-------+--------+<br>|                id                | enabled | email |  name  |<br>+----------------------------------+---------+-------+--------+<br>
| 76a3cb1e5e7a427d8272838fc0a759fc | True    | None  | nova   |<br>| a19e7f6975984e7fa6c8774d688d690b | True    | None  | admin  |<br>| c92f9e064b884d5c8c140c98c4bb5fe2 | True    | None  | swift  |<br>| ebc043e91a304342ac091854b05a383b | True    | None  | glance |<br>
+----------------------------------+---------+-------+--------+<br><br># glance index<br>Failed to show index. Got error:<br>You are not authenticated.<br>Details: 401 Unauthorized<br><br>This server could not verify that you are authorized to access the document you requested. Either you supplied the wrong credentials (e.g., bad password), or your browser does not understand how to supply the credentials required.<br>
<br> Authentication required  <br><br><br># keystone --os_username=glance --os_password=glance --os_tenant_name=service --os_auth_url=<a href="http://127.0.0.1:35357/v2.0">http://127.0.0.1:35357/v2.0</a> token-get<br>'Client' object has no attribute 'service_catalog'<br>
<br><br>But i am not getting this problem if i specify admin_token and auth_token in api/registry file<br><br>admin_token = 012345SECRET99TOKEN012345<br>auth_token = 012345SECRET99TOKEN012345<br><br>If i add the above two lines, then it started working.<br>
<br>The same case with swift also, "swift stat" command was not working, but if i add the above two lines, then it started working. <br><br>But the openstack documents did not specify to add these lines in glance and swift config files.<br>
<br>What could be the problem ?<br><br>Thanks in advance.<br><br><div class="gmail_quote">On Sat, May 12, 2012 at 4:24 PM, Dolph Mathews <span dir="ltr"><<a href="mailto:dolph.mathews@gmail.com" target="_blank">dolph.mathews@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I think the key is this line:<div class="im"><div><br></div><div><span>2012-05-11 10:03:11 18461     INFO [keystone.middleware.auth_</span><span>token] Keystone rejected admin token {'X-Auth-Token': u'</span><span>6f220a2e7e324bf4bd7a96040f3643</span><span>16'}, resetting</span> </div>

<div><br></div></div><div>It looks like your auth_token middleware isn't properly authenticating itself with keystone. Verify that you can receive an admin token from the admin endpoint using whatever credentials you've configured the auth_token middleware to use via [filter:authtoken], (notice I'm using the admin endpoint here):</div>

<div><br></div><div>$ keystone --os_username=glance --os_password=glance --os_tenant=service --os_auth_url=<a href="http://127.0.0.1:35357/v2.0" target="_blank">http://127.0.0.1:35357/v2.0</a> token-get<br><br>I'm guessing this authentication is either failing, or doesn't have the necessary admin privileges to validate other tokens? As shake.chen points out, user-list will probably fail for this reason.</div>
<span class="HOEnZb"><font color="#888888">
<div><br></div></font></span><div><span class="HOEnZb"><font color="#888888">-Dolph</font></span><div><div class="h5"><br><br><div class="gmail_quote">On Sat, May 12, 2012 at 3:03 AM, Shake Chen <span dir="ltr"><<a href="mailto:shake.chen@gmail.com" target="_blank">shake.chen@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">you can check your keystone whether work correctly.<br><br>keystone user-list<br><br><br><br><div class="gmail_quote">
<div>
<div>On Fri, May 11, 2012 at 12:42 PM, Shashi Kanth Boddula <span dir="ltr"><<a href="mailto:shashi.bsd@gmail.com" target="_blank">shashi.bsd@gmail.com</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>Ubuntu 12.04 Essex.<br><br># glance index<br>Failed to show index. Got error:<br>You are not authenticated.<br>

Details: 401 Unauthorized<br>
<br>This server could not verify that you are authorized to access the document you requested. Either you supplied the wrong credentials (e.g., bad password), or your browser does not understand how to supply the credentials required.<br>



<br> Authentication required  <br><br># glance --os_username=glance --os_password=glance --os_tenant=service --os_auth_url=<a href="http://127.0.0.1:5000/v2.0" target="_blank">http://127.0.0.1:5000/v2.0</a> index<br><br>


Failed to show index. Got error:<br>
You are not authenticated.<br>Details: 401 Unauthorized<br><br>This server could not verify that you are authorized to access the document you requested. Either you supplied the wrong credentials (e.g., bad password), or your browser does not understand how to supply the credentials required.<br>



<br> Authentication required  <br><br><br>---------------------------------------<br><br>In the keystone log file i see the error bellow.<br><br><br>2012-05-11 10:03:11 18461     INFO [keystone.middleware.auth_token] Retrying validation<br>



2012-05-11 10:03:11 18461     INFO [keystone.middleware.auth_token] Keystone rejected admin token {'X-Auth-Token': u'6f220a2e7e324bf4bd7a96040f364316'}, resetting<br>2012-05-11 10:03:11 18461  WARNING [keystone.middleware.auth_token] Invalid user token: 238dc305de1e418b8b81bee4f648f984. Keystone response: {u'error': {u'message': u'The request you have made requires authentication.', u'code': 401, u'title': u'Not Authorized'}}.<br>



2012-05-11 10:03:11 18461     INFO [keystone.middleware.auth_token] Invalid user token - rejecting request<br><br><br><br>Not understanding where could be the problem.<br><br>glace user is mapped to admin role in the service tenant.<br>



<br>glance endpoint is created.<br><br>I have specified glance user name, password and the service tenant in glance-api/registry files, and keystone authentication specified.<br><br><br>Anyone tell me what could be the problem?  Thank you.<span><font color="#888888"><br>



<br><br clear="all"><br>-- <br>Thanks & Regards,<br>Shashi Kanth<br><br>
</font></span><br></div></div>_______________________________________________<br>
Mailing list: <a href="https://launchpad.net/%7Eopenstack" target="_blank">https://launchpad.net/~openstack</a><br>
Post to     : <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><br>
Unsubscribe : <a href="https://launchpad.net/%7Eopenstack" target="_blank">https://launchpad.net/~openstack</a><br>
More help   : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
<br></blockquote></div><span><font color="#888888"><br><br clear="all"><br>-- <br>Shake Chen<br><br><br>
</font></span><br>_______________________________________________<br>
Mailing list: <a href="https://launchpad.net/%7Eopenstack" target="_blank">https://launchpad.net/~openstack</a><br>
Post to     : <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><br>
Unsubscribe : <a href="https://launchpad.net/%7Eopenstack" target="_blank">https://launchpad.net/~openstack</a><br>
More help   : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
<br></blockquote></div><br></div></div></div>
</blockquote></div><br><br clear="all"><br>-- <br>Thanks & Regards,<br>Shashi Kanth<br><br>
</div></blockquote></body></html>