diff options
author | Sage Weil <sage.weil@dreamhost.com> | 2012-01-28 09:38:46 -0800 |
---|---|---|
committer | Sage Weil <sage.weil@dreamhost.com> | 2012-01-28 10:56:14 -0800 |
commit | f9620d7d6db27af4041169cfc1bbd18b08c819ab (patch) | |
tree | 9542d2ec18a616398fb14b36e2a736109a587ec8 | |
parent | d43387c3257f55dfb386797f0fc4d81d28ed3d86 (diff) | |
download | ceph-f9620d7d6db27af4041169cfc1bbd18b08c819ab.tar.gz |
client: do not send release to down mds
We can have a session with state where the mds is not up; don't blindly
send a message or we can get
./mds/MDSMap.h: In function 'const entity_inst_t MDSMap::get_inst(int)', in thread '0x7f092aad1910'
./mds/MDSMap.h: 465: FAILED assert(up.count(m))
ceph version 0.35-6-g6eb8862 (commit:6eb8862e91d142451e256aaa02b34c81a4f21dea)
1: (ceph::__ceph_assert_fail(char const*, char const*, int, char const*)+0x70) [0x71f11a]
2: (MDSMap::get_inst(int)+0x4b) [0x6dc191]
3: (Client::flush_cap_releases()+0x94) [0x677e60]
4: (Client::tick()+0x1f0) [0x690adc]
5: (C_C_Tick::finish(int)+0x1c) [0x6f3fbe]
6: (SafeTimer::timer_thread()+0x2c5) [0x6fbfe5]
7: (SafeTimerThread::entry()+0x19) [0x6fe399]
8: (Thread::_entry_func(void*)+0x20) [0x72e944]
9: /lib/libpthread.so.0 [0x7f092dea573a]
10: (clone()+0x6d) [0x7f092cba169d]
with a map like
$ ./ceph mds dump 85
2012-01-28 09:37:19.251946 mon <- [mds,dump,85]
2012-01-28 09:37:19.252618 mon.1 -> 'dumped mdsmap epoch 85' (0)
epoch 85
flags 0
created 2012-01-28 09:24:42.411202
modified 2012-01-28 09:28:45.093301
tableserver 0
root 0
session_timeout 60
session_autoclose 300
last_failure 0
last_failure_osd_epoch 18
compat compat={},rocompat={},incompat={1=base v0.20,2=client writeable ranges,3=default file layouts on dirs,4=dir inode in separate object}
max_mds 1
in 0
up {}
failed 0
stopped
data_pools [0]
metadata_pool 1
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
-rw-r--r-- | src/client/Client.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/Client.cc b/src/client/Client.cc index c0cebcb9b22..dcf522e13d2 100644 --- a/src/client/Client.cc +++ b/src/client/Client.cc @@ -3396,7 +3396,7 @@ void Client::flush_cap_releases() for (map<int,MetaSession*>::iterator p = mds_sessions.begin(); p != mds_sessions.end(); p++) { - if (p->second->release) { + if (p->second->release && mdsmap->is_up(p->first)) { messenger->send_message(p->second->release, mdsmap->get_inst(p->first)); p->second->release = 0; } |