Whamcloud - gitweb
LU-14668 lnet: Lock primary NID logic 30/51130/2
authorAmir Shehata <ashehata@whamcloud.com>
Wed, 5 May 2021 18:35:06 +0000 (11:35 -0700)
committerOleg Drokin <green@whamcloud.com>
Wed, 2 Aug 2023 06:19:34 +0000 (06:19 +0000)
commitb341288179d9b3ad594b461586d826d6811db5a1
treec5bdf11e6f51e9e3db9b789dc6cf40007d913e36
parent1c882aebeaac4970c78a3616f1dd96d0920d133f
LU-14668 lnet: Lock primary NID logic

If a peer is created by Lustre make sure to lock that peer's
primary NID. This peer can be discovered in the background.
There is no need to block until discovery is complete, as Lustre
can continue on with the primary NID it provided.

Discovery will populate the peer with other interfaces the peer has
but will not change the peer's primary NID. It can also delete
peer's NIDs which Lustre told it about (not the Primary NID).

If a peer has been manually discovered via
   lnetctl discover <nid>
command, then make sure to delete the manually discovered
peer and recreate it with the Lustre NID information
provided for us.

Lustre-change: https://review.whamcloud.com/50106
Lustre-commit: aacb16191a72bc6db1155030849efb0d6971a572

Signed-off-by: Amir Shehata <ashehata@whamcloud.com>
Change-Id: I8fc8a69caccca047e3085bb33d026a3f09fb359b
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/51130
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Frank Sehr <fsehr@whamcloud.com>
Reviewed-by: Cyril Bordage <cbordage@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/lnet/peer.c