From a94af686a3646c45636edbc494ab3fa77926f8f2 Mon Sep 17 00:00:00 2001
From: bobijam <bobijam>
Date: Thu, 3 Apr 2008 02:46:55 +0000
Subject: [PATCH] Branch b1_6 b=14134 i=shadow, nathan

change non-fatal error messages about contacting MGS.
---
 lustre/mgc/mgc_request.c    | 5 +++--
 lustre/obdclass/obd_mount.c | 9 +++++----
 2 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/lustre/mgc/mgc_request.c b/lustre/mgc/mgc_request.c
index 54b39c3c1a..d0341ae634 100644
--- a/lustre/mgc/mgc_request.c
+++ b/lustre/mgc/mgc_request.c
@@ -1130,8 +1130,9 @@ static int mgc_process_log(struct obd_device *mgc,
                                                    "\n", cld->cld_logname);
                                 GOTO(out_pop, rc = -ENOTCONN);
                         }
-                        LCONSOLE_WARN("Failed to get MGS log %s, using "
-                                      "local copy.\n", cld->cld_logname);
+                        CDEBUG(D_MGC, "Failed to get MGS log %s, using local "
+                                      "copy for now, will try to update later.\n",
+                               cld->cld_logname);
                 }
                 /* Now, whether we copied or not, start using the local llog.
                    If we failed to copy, we'll start using whatever the old 
diff --git a/lustre/obdclass/obd_mount.c b/lustre/obdclass/obd_mount.c
index 352caadc69..8e42a9a9ad 100644
--- a/lustre/obdclass/obd_mount.c
+++ b/lustre/obdclass/obd_mount.c
@@ -699,7 +699,7 @@ static int lustre_start_mgc(struct super_block *sb)
                                 sizeof(recov_bk), &recov_bk, NULL);
         if (rc)
                 /* nonfatal */
-                CERROR("can't set %s %d\n", KEY_INIT_RECOV_BACKUP, rc);
+                CWARN("can't set %s %d\n", KEY_INIT_RECOV_BACKUP, rc);
 
         OBD_ALLOC_PTR(data);
         if (data == NULL)
@@ -960,10 +960,8 @@ int server_register_target(struct super_block *sb)
         rc = obd_set_info_async(mgc->u.cli.cl_mgc_mgsexp,
                                 strlen("register_target"), "register_target",
                                 sizeof(*mti), mti, NULL);
-        if (rc) {
-                CERROR("registration with the MGS failed (%d)\n", rc);
+        if (rc)
                 GOTO(out, rc);
-        }
 
         /* Always update our flags */
         ldd->ldd_flags = mti->mti_flags & ~LDD_F_REWRITE_LDD;
@@ -1075,6 +1073,9 @@ static int server_start_targets(struct super_block *sb, struct vfsmount *mnt)
                                    lsi->lsi_ldd->ldd_svname);
                 GOTO(out_mgc, rc);
         }
+        /* non-fatal error of registeration with MGS */
+        if (rc)
+                CDEBUG(D_MOUNT, "Cannot register with MGS: %d\n", rc);
 
         /* Let the target look up the mount using the target's name
            (we can't pass the sb or mnt through class_process_config.) */
-- 
GitLab