Whamcloud - gitweb
LU-9119 lnet: Fix deleting peers from YAML 01/27001/3
authorsharmaso <sonia.sharma@intel.com>
Thu, 2 Mar 2017 22:00:51 +0000 (14:00 -0800)
committerOleg Drokin <oleg.drokin@intel.com>
Tue, 16 May 2017 05:48:36 +0000 (05:48 +0000)
commita003d8d6af63801c8f8431453fd0d94630122125
treefcd2656038f40999f7f143ab71212f5e87cb0f1c
parenta6d463ff0b018e902afe63801c8b2c1e9a92ddc2
LU-9119 lnet: Fix deleting peers from YAML

Deleting peers with lnetctl command
"import --del < config.yaml" throws error

The above command deletes prim_nid first
and then tries deleting the other nids which
results in error, since deleting the primary_nid
deletes the entire peer and then after that we try
to delete non-existent NIDs.

The behavior should be if the primary_nid is
present in the list of NIDs then delete the
entire peer, otherwise delete only the NIDs
specified within the peer

Test-Parameters: trivial
Signed-off-by: Sonia Sharma <sonia.sharma@intel.com>
Signed-off-by: Amir Shehata <amir.shehata@intel.com>
Change-Id: I55114fca4d332c950872bd446e02e4f0904ee716
Reviewed-on: https://review.whamcloud.com/27001
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lnet/utils/lnetconfig/liblnetconfig.c