[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-03-13 Thread J. Eric Ivancich
A PR that adds experimental support for restoring a bucket index was merged into main. It’ll need back ports to reef, quincy, and pacific. https://tracker.ceph.com/issues/59053 Currently it does not work

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-23 Thread J. Eric Ivancich
Off the top of my head: 1. The command would take a bucket marker and a bucket names as arguments. It might also need some additional metadata to fill in gaps. 2. Scan the data pool for head objects that refer to that bucket marker. 3. Based on the number of such objects found, create a bucket

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-23 Thread Robert Sander
Hi, On 22.02.23 17:45, J. Eric Ivancich wrote: You also asked why there’s not a command to scan the data pool and recreate the bucket index. I think the concept would work as all head objects include the bucket marker in their names. There might be some corner cases where it’d partially

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-22 Thread J. Eric Ivancich
Everything you say is to be expected. I was not aware `reshard` could be run when the prior shards are removed, but apparently it can, and it creates new bucket index shards that are empty. Normally `reshard` reads entries from the old shards and copies their data to the new shards but since

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-22 Thread Robert Sander
On 22.02.23 14:42, David Orman wrote: If it's a test cluster, you could try: root@ceph01:/# radosgw-admin bucket check -h |grep -A1 check-objects --check-objects bucket check: rebuilds bucket index according to actual objects state After a "bi

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-22 Thread David Orman
If it's a test cluster, you could try: root@ceph01:/# radosgw-admin bucket check -h |grep -A1 check-objects --check-objects bucket check: rebuilds bucket index according to actual objects state On Wed, Feb 22, 2023, at 02:22, Robert Sander wrote: > On

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-22 Thread Robert Sander
On 21.02.23 22:52, Richard Bade wrote: A colleague and I ran into this a few weeks ago. The way we managed to get access back to delete the bucket properly (using radosgw-admin bucket rm) was to reshard the bucket. This created a new bucket index and therefore it was then possible to delete

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-21 Thread Richard Bade
Hi Robert, A colleague and I ran into this a few weeks ago. The way we managed to get access back to delete the bucket properly (using radosgw-admin bucket rm) was to reshard the bucket. This created a new bucket index and therefore it was then possible to delete it. If you are looking to get

[ceph-users] Re: Undo "radosgw-admin bi purge"

2023-02-21 Thread J. Eric Ivancich
When the admin runs “bi purge” they have the option of supplying a bucket_id with the “--bucket-id” command-line argument. This was useful back when resharding did not automatically remove the older bucket index shards (which it now does), which had a different bucket_id from the current bucket