简体   繁体   中英

Swift Juno complains 'Account not found'

I'm new to stack so this might be a very silly mistake. I'm trying to setup a one node swift configuration for a simple proof of concept. I did follow the instructions . However, something is missing. I keep getting this error:

root@lab-srv2544:/etc/swift# swift stat
Traceback (most recent call last):
  File "/usr/bin/swift", line 10, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/dist-packages/swiftclient/shell.py", line 1287, in main
    globals()['st_%s' % args[0]](parser, argv[1:], output)
  File "/usr/lib/python2.7/dist-packages/swiftclient/shell.py", line 492, in st_stat
    stat_result = swift.stat()
  File "/usr/lib/python2.7/dist-packages/swiftclient/service.py", line 427, in stat
    raise SwiftError('Account not found', exc=err)
swiftclient.service.SwiftError: 'Account not found'

Also, the syslog always complains about proxy-server:

Dec 12 12:16:37 lab-srv2544 proxy-server: Account HEAD returning 503 for [] (txn: tx9536949d19d14f1ab5d8d-00548b4d25) (client_ip: 127.0.0.1)
Dec 12 12:16:37 lab-srv2544 proxy-server: 127.0.0.1 127.0.0.1 12/Dec/2014/20/16/37 HEAD /v1/AUTH_71e79a29599149099aa98d5d276eaa0b HTTP/1.0 503 - python-swiftclient-2.3.0 8d2b0748804f4b34... - - - tx9536949d19d14f1ab5d8d-00548b4d25 - 0.0013 - - 1418415397.334497929 1418415397.335824013

Anyone seen this problem before?

使用“ swift”命令访问swift存储时,如果未在环境变量中设置用户ID和密码,则将其作为参数传递。

The most probable reason for this behavior is a funny order in your "pipeline" directive in /etc/swift/proxy-server.conf

To verify this hypothesis:

  • comment out your current pipeline, and write this one instead:

pipeline = authtoken cache healthcheck keystoneauth proxy-logging proxy-server

  • restart your proxy server with the command

swift-init proxy-server restart

  • Make sure the environment variables OS_USERNAME , OS_PASSWORD , OS_TENANT_NAME and OS_AUTH_URL are defined

  • try to list your containers with

swift list

If you get a list of containers then the diagnoses is correct. Get back to your proxy-server.conf and try to add one element per time to your pipeline, restarting the server each time, and testing each time, until you find the right order. For your reference see http://docs.openstack.org/developer/swift/deployment_guide.html#proxy-server-configuration

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM