Feature #14264
async rbd_open() option
0%
Description
Image this use-case (pseudo code):
for name in rbd_list():
image = rbd_open(name)
info = rbd_stat(image)
With thousands of images this will take a lot of time. This is what currently happens inside libvirt.
Refreshing a RBD storage pool can take 5 minutes when there are thousands of images in the pool.
A async option with a callback would be useful for librbd. In the callback you can then call rbd_stat() and update libvirt's metadata.
I think this is a useful option any way if you want to scan a lot of RBD images in a cluster in a efficient way.
Associated revisions
librbd: API: async open and close
Fixes: #14264
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
History
#1 Updated by Mykola Golub about 8 years ago
Wido, are you working or planning to work on this feature? I could do it if you aren't.
#2 Updated by Wido den Hollander about 8 years ago
Mykola Golub wrote:
Wido, are you working or planning to work on this feature? I could do it if you aren't.
No, I'm not working on this. My librbd knowledge is way to limited I think.
I just wanted to get this recorded since I could really use it for libvirt: https://github.com/libvirt/libvirt/blob/master/src/storage/storage_backend_rbd.c#L333
#3 Updated by Mykola Golub about 8 years ago
#4 Updated by Kefu Chai about 8 years ago
- Status changed from New to Fix Under Review
#5 Updated by Mykola Golub about 8 years ago
I think the status can be changed to resolved.
#6 Updated by Haomai Wang about 8 years ago
- Status changed from Fix Under Review to Resolved