From: Josh Durgin Date: Sat, 28 May 2011 00:40:28 +0000 (-0700) Subject: osd: add command to exit cleanly X-Git-Tag: v0.30~108^2~8 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=1cc78b6a864d36cbe1eda45890d7f361adb8201d;p=ceph.git osd: add command to exit cleanly This is required for gcov to work on daemons since the coverage data is written atexit, and the function that writes the data is not exported. Signed-off-by: Josh Durgin --- diff --git a/src/osd/OSD.cc b/src/osd/OSD.cc index caac74750ba54..1b19d6600eb3b 100644 --- a/src/osd/OSD.cc +++ b/src/osd/OSD.cc @@ -2388,6 +2388,11 @@ void OSD::handle_command(MMonCommand *m) dout(0) << "reset pg recovery stats" << dendl; pg_recovery_stats.reset(); } + else if (m->cmd[0] == "exit") { + dout(0) << "exiting cleanly" << dendl; + exit(0); + } + else dout(0) << "unrecognized command! " << m->cmd << dendl; done: