setup 2 clusters:
MON=1 OSD=1 MDS=0 MGR=1 ../src/test/rgw/test-rgw-multisite.sh 2
using hsbench create a bucket on cluster 1:
hsbench -a 1234567890 -s pencil -u http://localhost:8001 -bp my-bucket -b 1 -r zg1 -m i
upload objects:
hsbench -a 1234567890 -s pencil -u http://localhost:8001 -bp my-bucket -b 1 -r zg1 -m p -z 4K -d 10 -op obj1
check the bilog:
bin/radosgw-admin -c run/c1/ceph.conf bilog list --bucket my-bucket000000000000 --gen 0 | grep object | wc -l
reshard:
bin/radosgw-admin -c run/c1/ceph.conf bucket reshard --bucket my-bucket000000000000 --num-shards 13 --max-entries 10000
then upload objects again:
hsbench -a 1234567890 -s pencil -u http://localhost:8001 -bp my-bucket -b 1 -r zg1 -m p -z 4K -d 10 -op obj2
and check bilog for both generarions:
bin/radosgw-admin -c run/c1/ceph.conf bilog list --bucket my-bucket000000000000 --gen 0 | grep object | wc -l
bin/radosgw-admin -c run/c1/ceph.conf bilog list --bucket my-bucket000000000000 --gen 1 | grep object | wc -l
now upload the objects again:
hsbench -a 1234567890 -s pencil -u http://localhost:8001 -bp my-bucket -b 1 -r zg1 -m p -z 4K -d 10 -op obj3
and do a reshard in a separate window while objects are uploaded:
bin/radosgw-admin -c run/c1/ceph.conf bucket reshard --bucket my-bucket000000000000 --num-shards 17 --max-entries 10000
then check bilog for all generarions:
bin/radosgw-admin -c run/c1/ceph.conf bilog list --bucket my-bucket000000000000 --gen 0 | grep object | wc -l
bin/radosgw-admin -c run/c1/ceph.conf bilog list --bucket my-bucket000000000000 --gen 1 | grep object | wc -l
bin/radosgw-admin -c run/c1/ceph.conf bilog list --bucket my-bucket000000000000 --gen 2 | grep object | wc -l