summaryrefslogtreecommitdiffstats
path: root/src/ceph_fuse.cc
diff options
context:
space:
mode:
authorPatrick Donnelly <pdonnell@redhat.com>2017-11-29 00:01:32 +0100
committerPatrick Donnelly <pdonnell@redhat.com>2017-12-05 01:10:27 +0100
commit5b2b1d14468c290c56ee6c95ea557c99464e0098 (patch)
treeb1d1a8f4bc420ac2ddd929e343ee98baefc02016 /src/ceph_fuse.cc
parentMerge pull request #19241 from ceph/wip-doc-deprecate-cdisk (diff)
downloadceph-5b2b1d14468c290c56ee6c95ea557c99464e0098.tar.xz
ceph-5b2b1d14468c290c56ee6c95ea557c99464e0098.zip
client: quit on failed remount during dentry invalidate test
Fixes: http://tracker.ceph.com/issues/22269 Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
Diffstat (limited to 'src/ceph_fuse.cc')
-rw-r--r--src/ceph_fuse.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/ceph_fuse.cc b/src/ceph_fuse.cc
index d536365c3fb..76fedf50afe 100644
--- a/src/ceph_fuse.cc
+++ b/src/ceph_fuse.cc
@@ -161,12 +161,14 @@ int main(int argc, const char **argv, const char *envp[]) {
#if defined(__linux__)
int ver = get_linux_version();
assert(ver != 0);
- auto client_try_dentry_invalidate = g_conf->get_val<bool>(
+ bool client_try_dentry_invalidate = g_conf->get_val<bool>(
"client_try_dentry_invalidate");
bool can_invalidate_dentries =
client_try_dentry_invalidate && ver < KERNEL_VERSION(3, 18, 0);
int tr = client->test_dentry_handling(can_invalidate_dentries);
- if (tr != 0) {
+ bool client_die_on_failed_dentry_invalidate = g_conf->get_val<bool>(
+ "client_die_on_failed_dentry_invalidate");
+ if (tr != 0 && client_die_on_failed_dentry_invalidate) {
cerr << "ceph-fuse[" << getpid()
<< "]: fuse failed dentry invalidate/remount test with error "
<< cpp_strerror(tr) << ", stopping" << std::endl;