Fixes #5117: fix detection of generated roles per servers