mirror of
https://github.com/ceph/ceph
synced 2025-01-19 01:21:49 +00:00
ceph_mon: output preforker error message
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
This commit is contained in:
parent
9e1514cff2
commit
de5717eb9a
@ -497,9 +497,17 @@ int main(int argc, const char **argv)
|
||||
Preforker prefork;
|
||||
if (!(flags & CINIT_FLAG_NO_DAEMON_ACTIONS)) {
|
||||
if (global_init_prefork(g_ceph_context, 0) >= 0) {
|
||||
prefork.prefork();
|
||||
string err_msg;
|
||||
err = prefork.prefork(err_msg);
|
||||
if (err < 0) {
|
||||
cerr << err_msg << std::endl;
|
||||
prefork.exit(err);
|
||||
}
|
||||
if (prefork.is_parent()) {
|
||||
return prefork.parent_wait();
|
||||
err = prefork.parent_wait(err_msg);
|
||||
if (err < 0)
|
||||
cerr << err_msg << std::endl;
|
||||
prefork.exit(err);
|
||||
}
|
||||
global_init_postfork_start(g_ceph_context);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user