n8felton
04/13/2022, 5:12 PMSELECT version, COUNT(version) FROM os_version GROUP BY version;
that will tell me something like this for the whole fleet.
+---------+----------------+
| version | COUNT(version) |
+---------+----------------+
| 12.2.1 | 18 |
| 12.3.1 | 186 |
+---------+----------------+
Tomas Touceda
04/13/2022, 5:13 PMzwass
04/13/2022, 6:12 PMfleetctl query --labels 'All Hosts' --query 'SELECT version FROM os_version' --timeout 15s | jq '.rows[0].version' | sort | uniq -c
56% responded (91% online) | 10/18 targeted hosts (10/11 online)
Stopped by timeout
1 "11.6.3"
2 "12.2.1"
1 "12.3"
4 "12.3.1"
2 "20.04.3 LTS (Focal Fossa)"
1 "CentOS Stream release 8"
Kathy Satterlee
04/13/2022, 6:22 PMfleetctl get hosts --json | jq '.spec .os_version' | sort | uniq -c
zwass
04/13/2022, 7:22 PMn8felton
04/13/2022, 7:36 PMGET /api/latest/fleet/hosts/count
as well