conf: add mapall upcall to xCAT group bindings#624
Conversation
Signed-off-by: Stephane Thiell <sthiell@stanford.edu>
kcgthb
left a comment
There was a problem hiding this comment.
Actually, I'm not really sure about this one. 🤔
mapall works great when the cost of resolving all groups is the same, or close, to the cost of resoling one group.
But that's not the case for xCAT. There could be a number of xCAT groups that have little reason to ever be invoked via clush, and resolving all members of groups (especially dynamic groups) could be pretty costly on large systems with many groups. And in that case, resolving all groups knowing that the vast majority will never be used, doesn't seem like a very significant optimization.
There's a cluster I know where resolving all members of every single group takes much more time than cache_time :D
# time lsdef -t group -i members >/dev/null
real 3m32.317s
user 0m0.327s
sys 0m0.079s
This is largely due to the fact that resolving members of a dynamic group is an expensive SQL query in the xCAT DB (the membership is... dynamic, not defined statically) and those SQL queries are pretty much serialized, I believe.
So on a system with many dynamic groups (like this:
# lsdef -c -t group -i grouptype | awk -F: '{print $NF}' | sort | uniq -c
31 grouptype=
272 grouptype=dynamic
I'm not sure that a mapall call could be a real improvement, pretty much the opposite. :\
|
That's exactly the kind of data we are looking for. Do you have other scenarios, where the config is simpler? What is the perf difference in that situation? Let's drop it. It could always be added later if that useful. |
|
Thanks for the feedback! Agreed, that doesn't make sense to use |
Adopt the new
mapallupcall in the xCAT example group bindings: onelsdef -t group -i memberscall replaces onelsdefcall per group, for both static and dynamic groups. Group names containing:are skipped and remain resolvable throughmap.doc/sphinx/config.rstupdated to match.