Whamcloud - gitweb
LU-13306 mgs: use large NIDS in the nid table on the MGS 96/50896/32
authorJames Simmons <jsimmons@infradead.org>
Wed, 19 Jul 2023 18:04:15 +0000 (14:04 -0400)
committerOleg Drokin <green@whamcloud.com>
Sat, 19 Aug 2023 05:34:31 +0000 (05:34 +0000)
commitc0cb747ebe95d3fefa2a70c09c2ae0c4fa873b47
treecfd77b5fc5650d30211ef978e3f57d9080bfba81
parent7576d294582b818b20559138500cf1e58607cfc8
LU-13306 mgs: use large NIDS in the nid table on the MGS

On the MGS the NIDs detected are handled using the struct
mgs_target_info which currently only handles lnet_nid_t.
This structure also limits the number of NIDs to 32 entries.
Some sites have reported that 32 NIDs wasn't enough when
they configured virtual LNet networks for isolation.

Update the mgs_target_info to use NID strings instead.
This has the advantage of working even if struct lnet_nid
expands in the future. We place this data at the end of
the mgs_target_info as a flexible array. This requires
updating the ptlrpc packet handling to increase the size
to some new value to contain all the NIDs registered.
Also this gives us the option to use hostnames in the
future. This information is then feed into a
struct mgs_nidtbl_entry which is sent to the mgc on all
the remote nodes. With this patch only large NIDs for
small address space is translated to the original
lnet_nid_t format and sent to the various clients.
All the server targets, which are clients of the MGS,
use the large NID format. With this patch we don't
have to patch old clients when the servers are using
the larger NID format.

Expand LNetGetId() to return large NID addresses as well.
In the future we will use the ocd_connect_flags to
determine if the MSG supports large NID addresses.

Change-Id: I7083d6ecfc46cf0419a0d4a582e4bf5240f193cd
Signed-off-by: James Simmons <jsimmons@infradead.org>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/50896
Tested-by: Maloo <maloo@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Neil Brown <neilb@suse.de>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
18 files changed:
lnet/include/lnet/api.h
lnet/lnet/api-ni.c
lnet/selftest/console.c
lustre/include/lustre_disk.h
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/llite/llite_lib.c
lustre/lmv/lmv_obd.c
lustre/mgc/mgc_request_server.c
lustre/mgs/mgs_handler.c
lustre/mgs/mgs_llog.c
lustre/mgs/mgs_nids.c
lustre/obdclass/obd_mount.c
lustre/ptlrpc/nodemap_handler.c
lustre/ptlrpc/pack_generic.c
lustre/ptlrpc/wiretest.c
lustre/target/tgt_mount.c
lustre/utils/wirecheck.c
lustre/utils/wiretest.c