Changed the keymap comparison for the nodemap hash to the fix that
Andreas suggested, and fixed a bug with the idmap tree that resulted
in an incorrect deletion of idmaps.
Signed-off-by: Joshua Walgenbach <jjw@iu.edu>
Change-Id: I464fa8c97cf77b57e7a0918a2bb5aee935bfc891
Reviewed-on: http://review.whamcloud.com/10147
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Andrew Perepechko <andrew_perepechko@xyratex.com>
static int nodemap_hs_keycmp(const void *key,
cfs_hlist_node_t *compared_hnode)
{
- struct lu_nodemap *nodemap;
+ char *nodemap_name;
- nodemap = nodemap_hs_key(compared_hnode);
+ nodemap_name = nodemap_hs_key(compared_hnode);
- return !strcmp(key, nodemap->nm_name);
+ return !strcmp(key, nodemap_name);
}
static void *nodemap_hs_hashobject(cfs_hlist_node_t *hnode)
* replacing to precent split brain idmaps
*/
while (*fwd_node) {
+ fwd_parent = *fwd_node;
cur = rb_entry(*fwd_node, struct lu_idmap,
id_client_to_fs);
break;
}
- fwd_parent = *fwd_node;
}
if (!replace) {
while (*bck_node) {
+ bck_parent = *bck_node;
cur = rb_entry(*bck_node, struct lu_idmap,
id_fs_to_client);
break;
}
- bck_parent = *bck_node;
}
}
HOSTNAME_CHECKSUM=$(hostname | sum | awk '{ print $1 }')
SUBNET_CHECKSUM=$(expr $HOSTNAME_CHECKSUM % 250 + 1)
-NODEMAP_COUNT=10
+NODEMAP_COUNT=16
NODEMAP_RANGE_COUNT=3
NODEMAP_IPADDR_COUNT=30
-NODEMAP_MAX_ID=600
+NODEMAP_MAX_ID=128
require_dsh_mds || exit 0
require_dsh_ost || exit 0