Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rbd: add --object-size option #5676

Closed
wants to merge 1 commit into from
Closed

Conversation

vumrao
Copy link
Contributor

@vumrao vumrao commented Aug 26, 2015

Object size can be specified when creating an image with the --order option,
as a number of bits in the size.

This patch is adding new option --object-size. This new option will specify
object size directly for example --object-size 2M.

It would be easier to use. --order is still present for backwards compatibility.
For simplicity, we are rounding up the object size to the nearest power of 2.

Fixes #12112

Signed-off-by: Vikhyat Umrao vumrao@redhat.com

@vumrao
Copy link
Contributor Author

vumrao commented Aug 26, 2015

@jdurgin Hi Josh, I have sent this patch for http://tracker.ceph.com/issues/12112.
Please let me know your inputs.

Thanks and Regards,
Vikhyat

@tchaikov tchaikov added the rbd label Aug 27, 2015

Specifies the object size expressed as a number of bits, such that
the object size is ``1 << order``. The default is 22 (4 MB).
Specifies the object size in B/K/M, The default is 4 MB.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be nice to note that the smallest object-size is 4K and that the size will be rounded up the nearest power of two.

@vumrao
Copy link
Contributor Author

vumrao commented Sep 7, 2015

@dillaman Thanks a lot.

std::round(std::log2(object_size));
^^ this one is great , thanks for pointing it out. order is coming proper.

I have also corrected man pages changes.
Let me know if any other change is needed. If not please merge it.

Thanks for your help.

Regards,
Vikhyat

Object size can be specified when creating an image with the --order option,
as a number of bits in the size.

This patch is adding new option --object-size. This new  option will specify
object size directly for example  --object-size 2M.

It would be easier to use. --order is still present for backwards compatibility.
For simplicity, we are rounding up the object size to the nearest power of 2.

Fixes ceph#12112

Signed-off-by: Vikhyat Umrao <vumrao@redhat.com>
@dillaman
Copy link

dillaman commented Sep 8, 2015

LGTM -- master branch is currently in feature freeze for Infernalis

@vumrao
Copy link
Contributor Author

vumrao commented Sep 9, 2015

@dillaman Thanks for review. Sure you can merge it when freeze will be removed.
Regards,
Vikhyat

@vumrao
Copy link
Contributor Author

vumrao commented Sep 30, 2015

I will rebase this PR on top of this PR - #5987, once it would be merged.

@jdurgin
Copy link
Member

jdurgin commented Nov 11, 2015

rbd cli refactor is merged - can you rebase this?

@vumrao
Copy link
Contributor Author

vumrao commented Nov 25, 2015

@jdurgin I discussed this PR rebase with @dillaman he gave me some inputs as lots of thing now got changed. I will start fresh in same branch.

@jdurgin
Copy link
Member

jdurgin commented Nov 25, 2015

sounds good

@vumrao
Copy link
Contributor Author

vumrao commented Dec 7, 2015

@dillaman @jdurgin As rbd cli code base is now very different keeping same branch was creating lots of issues for me. I have created new PR for this request #6830 and closing this one.

@vumrao vumrao closed this Dec 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants