About set_alloc_hint op

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Now librbd is the only user for set_alloc_hint op.

  void AioWrite::add_write_ops(librados::ObjectWriteOperation &wr) {
    wr.set_alloc_hint(m_ictx->get_object_size(), m_ictx->get_object_size());
    wr.write(m_object_off, m_write_data);
  }

According above, the arguments for set_alloc_hint both are the size of
a object. It looks like there exist a misleading of the argument name
called "expected_write_size". And I would like to think
"expected_write_size" as the write size for most write ops.

KeyValueStore in recent commits use "expected_write_size" as strip
size, unfortunately librbd will issue set_alloc_hint(4MB, 4MB) but
each write op's size is serval KB.

I'm not sure "expected_object_size" and "expected_write_size" for
set_alloc_hint are properly used by librbd or maybe I misunderdstand
the op.

As for FileStore, if use XFS, set_alloc_hint will let FS allocate in
multiples of the hint size for this file. And some users may use 16MB
as the order of librbd image(like me :-| ), so it seemed a little
space ineffective.

I pushed a fix for keyvaluestore to avoid using
set_alloc_op(https://github.com/ceph/ceph/pull/1967).

-- 
Best Regards,

Wheat
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [CEPH Users]     [Ceph Large]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux