Whamcloud - gitweb
LU-18963 lnet: remove erroneous lnet_inet_enumerate() CWARN 42/59042/3
authorTimothy Day <timday@amazon.com>
Wed, 30 Apr 2025 14:59:49 +0000 (14:59 +0000)
committerOleg Drokin <green@whamcloud.com>
Wed, 21 May 2025 05:17:58 +0000 (05:17 +0000)
Upon finding a DOWN interface, LNet will emit a message like
"lnet: Ignoring interface eth0: it's down". However, this is
not true - LNet doesn't ignore eth0; it chooses to spam the
kernel log.

On an instance with a large number of network interfaces,
many of them may be down. And many of them could be designated
for Lustre. As a result, this error could be printed hundreds
of times. But the error doesn't provide actionable advice to
the user; they aren't attempting to set up those interfaces and
hence don't care about them.

Downgrade this warning to a CDEBUG. lnet_inet_select() will emit
an appropriate warning, if needed.

Test-Parameters: trivial
Signed-off-by: Timothy Day <timday@amazon.com>
Change-Id: I17942c2eeb37ffa5c6b7d9c107e9eae108105115
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/59042
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Frank Sehr <fsehr@whamcloud.com>
Reviewed-by: Chris Horn <chris.horn@hpe.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/lnet/config.c
lnet/lnet/lib-socket.c

index 501d7c0..67f6db8 100644 (file)
@@ -1548,14 +1548,13 @@ int lnet_inet_select(struct lnet_ni *ni,
                return if_idx;
 
        if (addr_set)
-               CERROR("%s: failed to find IP address %s\n",
+               CERROR("%s: failed to find UP interface with IP address %s\n",
                       libcfs_lnd2modname(ni->ni_nid.nid_type),
                       libcfs_nidstr(&ni->ni_nid));
        else if (ni->ni_interface)
-               CERROR("%s: failed to find interface %s%s%s\n",
+               CERROR("%s: failed to find UP interface %s\n",
                       libcfs_lnd2modname(ni->ni_nid.nid_type),
-                      ni->ni_interface, addr_set ? "@" : "",
-                      addr_set ? libcfs_nidstr(&ni->ni_nid) : "");
+                      ni->ni_interface);
 
        return -EINVAL;
 }
index ed00356..f427640 100644 (file)
@@ -564,8 +564,8 @@ int lnet_inet_enumerate(struct lnet_inetdev **dev_list, struct net *ns,
                        continue;
 
                if (!(flags & IFF_UP)) {
-                       CWARN("lnet: Ignoring interface %s: it's down\n",
-                             dev->name);
+                       CDEBUG(D_NET, "Ignoring interface %s: it's down\n",
+                              dev->name);
                        continue;
                }