Whamcloud - gitweb
LU-13340 lustre: Support large nids in LCFG_ADD_UUID 96/50096/9
authorMr NeilBrown <neilb@suse.de>
Thu, 12 May 2022 04:39:16 +0000 (14:39 +1000)
committerOleg Drokin <green@whamcloud.com>
Sat, 8 Jul 2023 22:34:20 +0000 (22:34 +0000)
commite7cf1fc1f274484dbd31e227652153fd4118aeef
tree32b16da994ba28a9889568a4479de27368c8bf5a
parent7f1aa5b66b247f339a9e7c25415a9a5dd272763c
LU-13340 lustre: Support large nids in LCFG_ADD_UUID

struct lustre_cfg contains lcfg_nid which is used only for
LCFG_ADD_UUID.  This is not sufficient for large nids.

The LCFG_ADD_UUID config record has room for 4 arbitrary strings only
one of which is used ("node").  So we can use the second string to
store a larger nid.

Specifically: if lcfg_nid is zero, then the second config string
(named "nid") will store the nid in string format.  When a nid with
4-byte address is needed, that will always be stored in lcfg_nid,
never in the config string.

Signed-off-by: Mr NeilBrown <neilb@suse.de>
Change-Id: If08477df677f26e0ff450803e79dde707becde0f
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/50096
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
lustre/include/uapi/linux/lustre/lustre_cfg.h
lustre/mgs/mgs_llog.c
lustre/obdclass/obd_config.c
lustre/obdclass/obd_mount.c
lustre/target/tgt_mount.c
lustre/utils/lustre_cfg.c