Project

General

Profile

Actions

Bug #14949

closed

radosgw-admin link failure

Added by Flex Gao about 8 years ago. Updated about 8 years ago.

Status:
Duplicate
Priority:
Normal
Assignee:
-
Target version:
-
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
rgw
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

[root@c1-app88 ~]# radosgw-admin metadata get bucket:test2
{
    "key": "bucket:test2",
    "ver": {
        "tag": "_fRQ4LmmDOgIi-drQIKLHZTm",
        "ver": 1
    },
    "mtime": 1456662405,
    "data": {
        "bucket": {
            "name": "test2",
            "pool": ".rgw.buckets",
            "data_extra_pool": ".rgw.buckets.extra",
            "index_pool": ".rgw.buckets.index",
            "marker": "default.24601.1",
            "bucket_id": "default.24601.1" 
        },
        "owner": "flex",
        "creation_time": 1456662405,
        "linked": "true",
        "has_bucket_info": "false" 
    }
}
[root@c1-app88 ~]#  radosgw-admin bucket link --bucket=test2 --uid=flex
failure: (22) Invalid argument: empty bucket instance id

Ceph Ver: 0.94.6

Actions #1

Updated by Abhishek Lekshmanan about 8 years ago

Can you try if radosgw-admin bucket link --bucket=test2 --bucket-id default.24601.1 --uid=flex works?

Actions #2

Updated by Abhishek Lekshmanan about 8 years ago

  • Status changed from New to Need More Info
Actions #3

Updated by Flex Gao about 8 years ago

Abhishek Lekshmanan wrote:

Can you try if radosgw-admin bucket link --bucket=test2 --bucket-id default.24601.1 --uid=flex works?

Yes, add --bucket-id works fine, the metadata show owner has been changed to flex.

{
    "key": "bucket:test2",
    "ver": {
        "tag": "_l0lvSxyXYNjXNrBmRft8I-n",
        "ver": 4
    },
    "mtime": 1457762905,
    "data": {
        "bucket": {
            "name": "test2",
            "pool": ".rgw.buckets",
            "data_extra_pool": ".rgw.buckets.extra",
            "index_pool": ".rgw.buckets.index",
            "marker": "default.54196.2",
            "bucket_id": "default.54196.2" 
        },
        "owner": "flex",
        "creation_time": 1457762860,
        "linked": "true",
        "has_bucket_info": "false" 
    }
}

But i still cannot use flex's s3 key to show bucket info

[root@c1-app1 ~]# s3cmd -c flex.cfg info s3://test2
ERROR: Access to bucket 'test2' was denied
ERROR: S3 error: 403 (AccessDenied)
Actions #4

Updated by Flex Gao about 8 years ago

Bucket test2 is created by user iceberg, i used link to change its owner to flex.

The bucket ACL has been updated:

[root@c1-app1 ~]# s3cmd -c iceberg.cfg info s3://test2
s3://test2/ (bucket):
   Location:  us-east-1
   Payer:     none
   Expiration Rule: none
   policy:    <?xml version="1.0" encoding="UTF-8"?><ListBucketResult xmlns="http://s3.amazonaws.com/doc/2006-03-01/"><Name>test2</Name><Prefix></Prefix><Marker></Marker><MaxKeys>1000</MaxKeys><IsTruncated>false</IsTruncated></ListBucketResult>
   cors:      none
   ACL:       flex: FULL_CONTROL
   ACL:       iceberg: FULL_CONTROL
Actions #5

Updated by Abhishek Lekshmanan about 8 years ago

This is related to http://tracker.ceph.com/issues/11076, a fix for which was recently merged in master (Backports marked for hammer as well). Unfortunately for the version you're using, you may have to change the acls for the bucket as well.

Actions #6

Updated by Yehuda Sadeh about 8 years ago

  • Status changed from Need More Info to Duplicate

Duplicate of #11076

Actions

Also available in: Atom PDF