[SOLVED] Free disk space per machine
Published: July 8, 2021 - 3:24 PM
Good morning,
I am looking to create a query that will quickly extract the free space from each machine in my fleet.
For this, there's the Freespace attribute available, which I'm trying to bring up, but it's not working:
select host_metrics->'local_drives'->>'C'->>>'FreeSpace' as "Free Space", host_metrics->'last_logged_on_user' as User, host_info->'computer_fqdn' as Name from hosts
And here's the error it's showing me
I'm not an SQL expert at all; the last time I did it was in class about 15 years ago! It seems to be a formatting issue, if I understand correctly, but I'm a bit stuck. If anyone has any ideas...
Mathieu
I am looking to create a query that will quickly extract the free space from each machine in my fleet.
For this, there's the Freespace attribute available, which I'm trying to bring up, but it's not working:
select host_metrics->'local_drives'->>'C'->>>'FreeSpace' as "Free Space", host_metrics->'last_logged_on_user' as User, host_info->'computer_fqdn' as Name from hosts
And here's the error it's showing me
I'm not an SQL expert at all; the last time I did it was in class about 15 years ago! It seems to be a formatting issue, if I understand correctly, but I'm a bit stuck. If anyone has any ideas...
Mathieu