From 889f63ad537f37cd5182d8e9bcac32be913779df Mon Sep 17 00:00:00 2001 From: Landen Date: Thu, 4 Feb 2010 15:57:49 +0800 Subject: [PATCH] b=16909 Simplify MDT/OST service start message i=nathan i=adilger --- lustre/mds/handler.c | 24 ++++++++++-------------- lustre/obdclass/obd_mount.c | 5 ----- lustre/obdfilter/filter.c | 26 +++++++++++--------------- 3 files changed, 21 insertions(+), 34 deletions(-) diff --git a/lustre/mds/handler.c b/lustre/mds/handler.c index ac2b974..fd38393 100644 --- a/lustre/mds/handler.c +++ b/lustre/mds/handler.c @@ -2067,23 +2067,19 @@ static int mds_setup(struct obd_device *obd, obd_count len, void *buf) } label = fsfilt_get_label(obd, obd->u.obt.obt_sb); - if (obd->obd_recovering) { - LCONSOLE_WARN("MDT %s now serving %s (%s%s%s), but will be in " - "recovery for at least %d:%.02d, or until %d " - "client%s reconnect%s. \n", - obd->obd_name, lustre_cfg_string(lcfg, 1), - label ?: "", label ? "/" : "", str, + LCONSOLE_INFO("%s: Now serving %s on %s with recovery %s\n", + obd->obd_name, label ?: str, lsi->lsi_lmd->lmd_dev, + obd->obd_replayable ? "enabled" : "disabled"); + + if (obd->obd_recovering) + LCONSOLE_WARN("%s: Will be in recovery for at least %d:%.02d, " + "or until %d client%s reconnect%s\n", + obd->obd_name, obd->obd_recovery_timeout / 60, obd->obd_recovery_timeout % 60, obd->obd_recoverable_clients, - (obd->obd_recoverable_clients == 1) ? "":"s", - (obd->obd_recoverable_clients == 1) ? "s":""); - } else { - LCONSOLE_INFO("MDT %s now serving %s (%s%s%s) with recovery " - "%s\n", obd->obd_name, lustre_cfg_string(lcfg, 1), - label ?: "", label ? "/" : "", str, - obd->obd_replayable ? "enabled" : "disabled"); - } + obd->obd_recoverable_clients == 1 ? "" : "s", + obd->obd_recoverable_clients == 1 ? "s": ""); /* Reduce the initial timeout on an MDS because it doesn't need such * a long timeout as an OST does. Adaptive timeouts will adjust this diff --git a/lustre/obdclass/obd_mount.c b/lustre/obdclass/obd_mount.c index c75a69c..4d80fca 100644 --- a/lustre/obdclass/obd_mount.c +++ b/lustre/obdclass/obd_mount.c @@ -1668,11 +1668,6 @@ static int server_fill_super(struct super_block *sb) if (rc) GOTO(out_mnt, rc); - LCONSOLE_WARN("Server %s on device %s has started\n", - ((lsi->lsi_lmd->lmd_flags & LMD_FLG_NOSVC) && - (IS_MDT(lsi->lsi_ldd))) ? "MGS" : lsi->lsi_ldd->ldd_svname, - lsi->lsi_lmd->lmd_dev); - RETURN(0); out_mnt: /* We jump here in case of failure while starting targets or MGS. diff --git a/lustre/obdfilter/filter.c b/lustre/obdfilter/filter.c index 86a7f5f..7823464 100644 --- a/lustre/obdfilter/filter.c +++ b/lustre/obdfilter/filter.c @@ -2014,24 +2014,20 @@ int filter_common_setup(struct obd_device *obd, obd_count len, void *buf, } label = fsfilt_get_label(obd, obd->u.obt.obt_sb); - - if (obd->obd_recovering) { - LCONSOLE_WARN("OST %s now serving %s (%s%s%s), but will be in " - "recovery for at least %d:%.02d, or until %d " - "client%s reconnect%s.\n", - obd->obd_name, lustre_cfg_string(lcfg, 1), - label ?: "", label ? "/" : "", str, + LCONSOLE_INFO("%s: Now serving %s %s%s with recovery %s\n", + obd->obd_name, label ?: str, lmi ? "on " : "", + lmi ? s2lsi(lmi->lmi_sb)->lsi_lmd->lmd_dev : "", + obd->obd_replayable ? "enabled" : "disabled"); + + if (obd->obd_recovering) + LCONSOLE_WARN("%s: Will be in recovery for at least %d:%.02d, " + "or until %d client%s reconnect%s\n", + obd->obd_name, obd->obd_recovery_timeout / 60, obd->obd_recovery_timeout % 60, obd->obd_recoverable_clients, - obd->obd_recoverable_clients == 1 ? "":"s", - obd->obd_recoverable_clients == 1 ? "s":""); - } else { - LCONSOLE_INFO("OST %s now serving %s (%s%s%s) with recovery " - "%s\n", obd->obd_name, lustre_cfg_string(lcfg, 1), - label ?: "", label ? "/" : "", str, - obd->obd_replayable ? "enabled" : "disabled"); - } + obd->obd_recoverable_clients == 1 ? "" : "s", + obd->obd_recoverable_clients == 1 ? "s": ""); RETURN(0); -- 1.8.3.1