Project

General

Profile

Bug #22742

Updated by Nathan Cutler about 6 years ago

https://github.com/ceph/ceph/pull/20037 Created a public bucket; after resharding the acls do not seem to have been retained

<pre>
$ s3 -us create publicbucket cannedAcl=public-read-write
Request-Id: tx0000000000000000f48ff-005a5dd7d9-3732-default
Bucket successfully created.
$for i in {1..10}; do curl -X PUT http://localhost:8000/publicbucket/obj$i -d "@null" -s; done
$ s3 -us list publicbucket
Content-Type: application/xml
Request-Id: tx0000000000000000f490a-005a5dd810-3732-default
Content-Length: 2718
Key Last Modified Size
-------------------------------------------------- -------------------- -----
obj1 2018-01-16T09:46:29Z 0
obj10 2018-01-16T09:46:29Z 0
obj2 2018-01-16T09:46:29Z 0
obj3 2018-01-16T09:46:29Z 0
obj4 2018-01-16T09:46:29Z 0
obj5 2018-01-16T09:46:29Z 0
obj6 2018-01-16T09:46:29Z 0
obj7 2018-01-16T09:46:29Z 0
obj8 2018-01-16T09:46:29Z 0
obj9 2018-01-16T09:46:29Z 0

$ s3 -us getacl publicbucket filename=publicbucket.acl
Content-Type: application/xml
Request-Id: tx0000000000000000f490c-005a5dd89d-3732-default
Content-Length: 820
$ cat publicbucket.acl
OwnerID testid M. Tester
Type User Identifier Permission
------ ------------------------------------------------------------------------------------------ ------------
Group All Users READ
Group All Users WRITE
UserID testid (M. Tester) FULL_CONTROL

$ radosgw-admin bucket reshard --bucket=publicbucket --num-shards=10
2018-01-16 11:50:44.480673 7f70a509c9c0 -1 WARNING: the following dangerous and experimental features are enabled: *
2018-01-16 11:50:44.481002 7f70a509c9c0 -1 WARNING: the following dangerous and experimental features are enabled: *
2018-01-16 11:50:44.482355 7f70a509c9c0 -1 WARNING: the following dangerous and experimental features are enabled: *
*** NOTICE: operation will not remove old bucket index objects ***
*** these will need to be removed manually ***
old bucket instance id: 7bacfc31-0169-4b18-8c29-1e4c5b1e481b.14130.3
new bucket instance id: 7bacfc31-0169-4b18-8c29-1e4c5b1e481b.14161.1
total entries: 10
2018-01-16 11:50:44.892935 7f70a509c9c0 0 lockdep stop

$ s3 -us getacl publicbucket filename=publicbucket2.acl
Content-Type: application/xml
Request-Id: tx0000000000000000f490d-005a5dd90c-3732-default
Content-Length: 435
$ cat publicbucket2.acl
OwnerID testid M. Tester
Type User Identifier Permission
------ ------------------------------------------------------------------------------------------ ------------
UserID testid (M. Tester) FULL_CONTROL

$ curl http://localhost:8000/publicbucket
<?xml version="1.0" encoding="UTF-8"?><Error><Code>AccessDenied</Code><BucketName>publicbucket</BucketName><RequestId>tx0000000000000000f490e-005a5dd949-3732-default</RequestId><HostId>3732-default-default</HostId></Error>
</pre>

Back