Bug #9002
closedCreating swift key with --gen-secret in separate step from subuser creation fails
0%
Description
Customer reported on CentOS with Ceph v0.80.4
Steps to reproduce:
radosgw-admin user create --uid=testuser1 --display-name="Test User One"
radosgw-admin subuser create --uid=testuser1 --subuser=testuser1:swift --access=full
radosgw-admin key create --uid=testuser1 --subuser=testuser1:swift --key-type=swift --gen-secret
Result:
could not create key: unable to add access key, unable to store user info
WARNING: can't store user info, swift id () already mapped to another user (testuser1)
Customer discovered workaround:
radosgw-admin user create --subuser=testuser1:swift --display-name="Test User One" --key-type=swift --access=full
Updated by only debian over 9 years ago
have meet on Wheezy and Ubuntu with Ceph0.80.5 too.
it can be sucessful when use :
radosgw-admin user create --subuser=testuser:swf0001 --display-name="Test User One" --key-type=swift --access=full
and it will create correct swift user in Pool .users.swift
- rados ls -p .users.swift
testuser:swf0001
and can use the swift user: testuser:swf0001 to access the rados gateway
root@ceph-radosgw:~# curl -v -i http://192.168.123.191/auth -X GET -H "X-Auth-User:testuser:swf0001" -H "X-Auth-Key:r4sHbFyF0A5tE1mW+GSMYovwkNdoqS/nP8rd1UGO"- About to connect() to 192.168.123.191 port 80 (#0)
- Trying 192.168.123.191...
- Connected to 192.168.123.191 (192.168.123.191) port 80 (#0)
GET /auth HTTP/1.1
User-Agent: curl/7.29.0
Host: 192.168.123.191
Accept: */*
X-Auth-User:testuser:swf0001
X-Auth-Key:r4sHbFyF0A5tE1mW+GSMYovwkNdoqS/nP8rd1UGO
< HTTP/1.1 204 No Content
HTTP/1.1 204 No Content
< Date: Tue, 12 Aug 2014 14:32:34 GMT
Date: Tue, 12 Aug 2014 14:32:34 GMT
< Server: Apache/2.2.22 (Debian)
Server: Apache/2.2.22 (Debian)
< X-Storage-Url: http://192.168.123.191/swift/v1
X-Storage-Url: http://192.168.123.191/swift/v1
< X-Storage-Token: AUTH_rgwtk1000000074657374757365723a737766303030317f6874150b34862d0277eb5328350129e54690fff014e8a758339af7dc34d895ab6061b9
X-Storage-Token: AUTH_rgwtk1000000074657374757365723a737766303030317f6874150b34862d0277eb5328350129e54690fff014e8a758339af7dc34d895ab6061b9
< X-Auth-Token: AUTH_rgwtk1000000074657374757365723a737766303030317f6874150b34862d0277eb5328350129e54690fff014e8a758339af7dc34d895ab6061b9
X-Auth-Token: AUTH_rgwtk1000000074657374757365723a737766303030317f6874150b34862d0277eb5328350129e54690fff014e8a758339af7dc34d895ab6061b9
< Content-Type: application/json
Content-Type: application/json
- Connection #0 to host 192.168.123.191 left intact
Updated by Sage Weil over 9 years ago
- Status changed from New to Duplicate