I got tired of dealing with Celsius readings. While I have nothing against Celsius, my small part of the world uses Fahrenheit and I haven’t yet got the Celsius values to register in my head.
I edited the file at /opt/librenms/includes/polling/functions.inc.php and inserted this bit of code around line 178. if ($class == "Temperature") {$sensor_value = ($sensor_value * 1.8) + 32;}
I haven’t tested it extensively but after an hour of running with 84 diverse devices in our LibreNMS instance it hasn’t broke anything yet.
This converts all temperatures from Celsius to Fahrenheit when they are collected and stores them as Fahrenheit. It does not fix all the places in the web UI that use the °C designation. For my needs I only needed to edit the file /opt/librens/includes/html/pages/device/overview/sensors/temperature.inc.php and change the “C” to an “F”. That makes the readings look right in the device overviews. The charts still show a C but I’m just living with that at the moment, I know all values are F so it’s ok.