Can you elaborate please Diotalevi. Some modern tree math terminology (badly) refers to 'siblings' and 'children'
the same. You want to find to all nodes that share the same parent? That is what siblings are. If so the method you have, traverse to the parent and enumerate all children is optimal. In a B-Tree there will only be 2 possible children, so just the fact of having more than one link tells you a sibling exists. Node depth alone is not enough, it could be the evil twin on the other side of the tree.