From: Greg Farnum Date: Thu, 24 Apr 2014 22:34:24 +0000 (-0700) Subject: FileStore: set XATTR_NO_SPILL_OUT when creating new files. X-Git-Tag: v0.80.2~27 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b758fd5f0ebcccdb1641a852d40ee880bad01107;p=ceph.git FileStore: set XATTR_NO_SPILL_OUT when creating new files. Fixes: #8205 Backport: firefly Signed-off-by: Greg Farnum (cherry picked from commit e3b995e1567f3ccc6d00ae27ab2aa99ca157228a) --- diff --git a/src/os/FileStore.cc b/src/os/FileStore.cc index 2fc762a047d..f73d9308580 100644 --- a/src/os/FileStore.cc +++ b/src/os/FileStore.cc @@ -275,6 +275,14 @@ int FileStore::lfn_open(coll_t cid, << ") in index: " << cpp_strerror(-r) << dendl; goto fail; } + r = chain_fsetxattr(fd, XATTR_SPILL_OUT_NAME, + XATTR_NO_SPILL_OUT, sizeof(XATTR_NO_SPILL_OUT)); + if (r < 0) { + VOID_TEMP_FAILURE_RETRY(::close(fd)); + derr << "error setting spillout xattr for oid " << oid << " (" << (*path)->path() + << "):" << cpp_strerror(-r) << dendl; + goto fail; + } } }