[Openstack] Swift stat Account HEAD failed

Samuel Merritt sam at swiftstack.com
Thu Oct 24 17:22:29 UTC 2013


On 10/24/13 7:13 AM, Therese Persson wrote:
> Hello,
>
> I have encountered a problem regarding Swift in my one node installation
> of OpenStack on Ubuntu 12.04.
>
> When I try to run the command “swift stat” I get the following error:
>
> Account HEAD failed:
> http://XXX.XXX.XXX.XXX:8888/v1/AUTH_519c6e2d263049adba404441f18aab60 400
> Bad Request
>
> And in /var/log/syslog :
>
> Oct 24 15:45:37 kds-openstack-01 account-server 10.10.10.51 - -
> [24/Oct/2013:13:45:37 +0000] "HEAD
> /cciss/c0d2p1/182082/AUTH_519c6e2d263049adba404441f18aab60" 400 72
> "tx6dd78c64bf6b4ceca3a568c04628fad3" "-" "-" 0.0002 ""

My guess is that you have a slash in the device name in the ring. This 
won't work. The Swift account server (and container and object servers) 
expects requested paths to be of the form /$device/$partition/$account; 
when you put a slash in there, the account server sees 4 path components 
and rejects the request with a 400.

I'd recommend changing your device names in the ring and your mount 
points. If you were to set your device name to "c0d2p1" instead of 
"cciss/c0d2p1" and then mount it at /srv/node/c0d2p1, things would 
probably start working.

There's no need to keep the device name in the mount point, either. You 
could mount /dev/cciss/c0d2p1 at /srv/node/Fred if you wanted, and as 
long as the device was named Fred in the ring, Swift would be happy.

> [snip]

> This is my /etc/swift/swift.conf file:
>
> [swift-hash]
>
> # random unique string that can never change (DO NOT LOSE)
>
> swift_hash_path_suffix = fLIbertYgibbitZ

Letting people know this is not a good idea. I hope that this is either 
a fake value or that this cluster is not publicly accessible.

(I say this not to scold you, but to warn other readers of the list: 
don't share swift_hash_path_prefix or swift_hash_path_suffix!)





More information about the Openstack mailing list