Andreas Piening
06/08/2022, 8:41 PMosquery
shell with /opt/orbit/bin/osqueryd/linux/stable/osqueryd -S
and run the following query:
SELECT path, type, ROUND((blocks_available * blocks_size * 10e-10), 2) AS free_gb, ROUND ((blocks_available * 1.0 / blocks * 1.0) * 100, 2) AS free_perc FROM mounts WHERE path = '/';
I receive floating point values with 1-2 digits after the decimal point as expected. However, the same query in fleet
gives me strange values like 29.370000000000001
for the column free_perc
. Same is true when I do this query on the console with fleetctl
. There is something wrong with parsing floating point results I guess.