mirror of
https://github.com/ceph/ceph
synced 2024-12-22 03:22:00 +00:00
6725e748e9
Fixes: #1211 Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
20 lines
459 B
Bash
Executable File
20 lines
459 B
Bash
Executable File
#!/bin/sh -ex
|
|
|
|
# create a sparse file
|
|
dd if=/bin/sh of=/tmp/img bs=1k count=1 seek=10
|
|
dd if=/bin/dd of=/tmp/img bs=1k count=10 seek=100
|
|
dd if=/bin/rm of=/tmp/img bs=1k count=100 seek=1000
|
|
dd if=/bin/ls of=/tmp/img bs=1k seek=10000
|
|
dd if=/bin/ln of=/tmp/img bs=1k seek=100000
|
|
dd if=/bin/grep of=/tmp/img bs=1k seek=1000000
|
|
|
|
rbd rm testimg || true
|
|
|
|
rbd import /tmp/img testimg
|
|
rbd export testimg /tmp/img2
|
|
|
|
cmp /tmp/img /tmp/img2
|
|
|
|
rm /tmp/img /tmp/img2
|
|
|
|
echo OK |