m_filestore_max_inline_xattrs = g_conf->filestore_max_inline_xattrs;
else
m_filestore_max_inline_xattrs = fs_xattrs;
+
+ // Use override value if set
+ if (g_conf->filestore_max_xattr_value_size)
+ m_filestore_max_xattr_value_size = g_conf->filestore_max_xattr_value_size;
+ else
+ m_filestore_max_xattr_value_size = fs_xattr_max_value_size;
+
+ if (m_filestore_max_xattr_value_size < g_conf->osd_max_object_name_len) {
+ derr << "WARNING: max attr value size ("
+ << m_filestore_max_xattr_value_size
+ << ") is smaller than osd_max_object_name_len ("
+ << g_conf->osd_max_object_name_len
+ << "). Your backend filesystem appears to not support attrs large "
+ << "enough to handle the configured max rados name size. You may get "
+ << "unexpected ENAMETOOLONG errors on rados operations or buggy "
+ << "behavior"
+ << dendl;
+ }
}
+ uint64_t FileStore::estimate_objects_overhead(uint64_t num_objects)
+ {
+ uint64_t res = num_objects * blk_size / 2; //assumes that each object uses ( in average ) additional 1/2 block due to FS allocation granularity.
+ return res;
+ }
+
// -- FSSuperblock --
void FSSuperblock::encode(bufferlist &bl) const