Wrong numbers showing in hostgroup overview

I see a strange problem when comparing the hostgroups overview from an admin user with a non-admin user.

The admin user (in group [Administrators] with permissions = "*") can see all the hosts (171) and services (1577) assigned to a hostgroup:

The non-admin user however only gets a very small number of hosts (2) and services (2) in the overview. But when clicking on the Host Group, the right hand side shows the same list of hosts (clearly more than 2 hosts):

Is there a problem in the calculation in the Hostgroup overview?

This is on Icingaweb2 2.7.3.

Hello @Napsty
Please review your Role permission in icingaweb2. If the role filter for non-admin is configured this way then what you are see is correct.

Can you share the roles.ini (/etc/icingaweb2/roles.ini) file?

Here the relevant group from the roles file:

[LAN]
users = "relevantuser"
permissions  = "monitoring/command/*,module/*"
monitoring/filter/objects = "(hostgroup_name=TEAM-LAN|servicegroup_name=TEAM-LAN)"

As you can see in the screenshots, the hostgroup_name matches.
By using the search in Icingaweb2, this user (relevantuser) can also see all hosts from this hostgroup. Also the “Tactical Overview” shows the correct amount of hosts (174) and services:

Only the “Hostgroups” Overview (/icingaweb2/monitoring/list/hostgroups) shows wrong counts.

Interesting. I reverted back to monitoring module version 2.7.1 and the host group count seems correct now:

Is there a known bug in 2.7.3 which causes this?

Hello @Napsty
I did a test on my icingaweb2 (ver 2.7.3) and noticed the count was wrong also.

I mirrored the filter you have and under my admin user there are 15 host count under the hostgroup. Under a user account assigned to this icingaweb2 role to the same hostgroup the count is 12 BUT if I manually count the host there were 15.

Regards
Alex

Thanks for validating @aclark6996!
Do you have a 2.8 installation, too? Are the numbers appearing correctly in 2.8?
The icingaweb2 setup (in this affected environment) still runs on Xenial, so I can’t just upgrade to 2.8.

No, I am not on web version 2.8. I have not had the time to complete the upgrade.

Icinga2 10.5-1
Icingaweb2 2.7.3

Have just checked in my test env:

Looks good.

test-User:

[test]
users = "test"
monitoring/filter/objects = "hostgroup_name=hp-ilo"
permissions = "module/monitoring,monitoring/command/*"

module/* in the permissions works as well.

Which version are you using @log1c?

Icinga Web 2 Version
2.8.1
Git Commit
233bd29e4104125b4e5ef631e8c16dde33dadd9a
PHP-Version
7.2.24-0ubuntu0.18.04.6

thx. good to know that it seems solved in Icinga 2.8.1 (tbv). Will have to upgrade then.