Temperature Reading on AMD
-
SOLVED https://forum.pfsense.org/index.php?topic=108262.msg610964#msg610964
I purchased a Fitlet i-A10 micro PC which comes with an AMD A10 Micro-6700T, quad core 1.2GHz chip. I loaded pfSense amd64 and it's working beautifully. However, I wanted to check the CPU temperature, since it is passively cooled. Under System > Advanced > Miscellaneous > Thermal Sensors, I enabled the "AMD K8, K10, and K11 CPU on-die thermal sensor (amdtemp)" option and rebooted. However, the Dashboard Widget doesn't show information:
From the shell, I checked "kldload amdtemp" and the module is definitely being loaded. I ran "sysctl -a |grep temperature" but I don't see any output. Is it possible that this chip isn't supported by the current version of amdtemp.ko? If so, is there an updated one somewhere?
Or, is there any other way to get the chip temperature?
Thanks!
-
have u defined the warnings and critical temp?
try using intel profile too and see what happens -
have u defined the warnings and critical temp?
try using intel profile too and see what happensI tried the Intel profile, it didn't work. Where do you set warnings?
-
click the sensors widget option and there u have the values.
![Screen Shot 2016-03-15 at 01.25.49.png](/public/imported_attachments/1/Screen Shot 2016-03-15 at 01.25.49.png)
![Screen Shot 2016-03-15 at 01.25.49.png_thumb](/public/imported_attachments/1/Screen Shot 2016-03-15 at 01.25.49.png_thumb) -
Yes, those values are set.
-
Or, is there any other way to get the chip temperature?
Is there perhaps inside of the PC BIOS an option to disable and enable the Sensors?
You should have a look inside of the BIOS for such or similar options to turn on or off. -
@BlueKobold:
Is there perhaps inside of the PC BIOS an option to disable and enable the Sensors?
You should have a look inside of the BIOS for such or similar options to turn on or off.Thanks for the idea. I checked in BIOS, and unfortunately, there were no CPU sensor options.
-
:( need new mobo :)
-
I purchased a Fitlet i-A10 micro PC which comes with an AMD A10 Micro-6700T, quad core 1.2GHz chip. I loaded pfSense amd64 and it's working beautifully. However, I wanted to check the CPU temperature, since it is passively cooled. Under System > Advanced > Miscellaneous > Thermal Sensors, I enabled the "AMD K8, K10, and K11 CPU on-die thermal sensor (amdtemp)" option and rebooted. However, the Dashboard Widget doesn't show information:
From the shell, I checked "kldload amdtemp" and the module is definitely being loaded. I ran "sysctl -a |grep temperature" but I don't see any output. Is it possible that this chip isn't supported by the current version of amdtemp.ko? If so, is there an updated one somewhere?
Or, is there any other way to get the chip temperature?
Thanks!
Bummer. FWIW, I'm running an AM1 platform build and using amdtemp and while I do get temperature data, it's seemingly unrelated to reality.
-
I ended up finally getting it to work! I contacted Fit-PC support (they make the Fitlet iA10) and they mentioned that amdtemp.c had to be built with 2 extra lines in it. Here is the URL that details the fix in the code. Basically, 2 lines have to be added to amdtemp.c, then the kernel has to be recompiled with the new amdtemp. I tried recompiling amdtemp.c by itself, but couldn't figure it out. I'll include the steps I followed in case anyone else wants to try, and I'll see if I can attach the new amdtemp.ko files.
-
Install FreeBSD 10.1 amd64 on a machine (I put it in a VM) and get it connected to the network
-
Download the kernel source
# fetch ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/10.1-RELEASE/src.txz # tar -C / -xzvf src.txz
-
Add two extra lines of code to /usr/src/sys/dev/amdtemp/amdtemp.c per the article above (see attached as well)
-
Modify custom kernel config to compile new amdtemp
# cd /usr/src/sys/amd64/conf # cp GENERIC CUSTOM # vi /usr/src/sys/amd64/conf/CUSTOM add line to end of CUSTOM file: device amdtemp
- Build the kernel (this takes awhile based on machine CPU)
# cd /usr/src # make buildkernel KERNCONF="CUSTOM"
- Install new kernel files
make installkernel KERNCONF="CUSTOM"
-
You should now have a new amdtemp.ko file in /boot/kernel on your FreeBSD 10.1 installation
-
Copy new amdtemp.ko file to pfSense with scp, sftp, usb or some other method (copy file to /boot/modules)
-
If you can get into the pfSense shell, you can load the module
# kldload /boot/modules/amdtemp.ko
- Enable AMD temp sensor in pfSense console: System > Advanced > Miscellaneous : Thermal Sensors section
Now if you add the Thermal Sensor applet to the dashboard, it should show up:
If you don't want to go through all that, attached are the updated amdtemp.ko files. I'm including the files for FreeBSD 10.1 and 10.2 (for when pfSense upgrades). Just rename the file amdtemp.ko.10.1.jpg to amdtemp.ko for example.
-
-
You might want to submit this upstream to FreeBSD, so the change/fix can be included in their code, and will then flow downstream to pfSense and other projects that use FreeBSD.
BTW, pfSense 2.3 will be using the just released FreeBSD 10.3, not 10.2.
-
when is 2.3 due out?
-
According to the FreeBSD Release Page, 10.3 was going to be released at the end of March 2016. But only RC3 is available now. Once stable is released, I'd imagine pfSense 2.3 work could really ramp up. Aren't they working on a console redesign/modernization too?
-
According to the FreeBSD Release Page, 10.3 was going to be released at the end of March 2016. But only RC3 is available now. Once stable is released, I'd imagine pfSense 2.3 work could really ramp up. Aren't they working on a console redesign/modernization too?
Just to answer your question, not meaning to steer this topic astray…
pfSense 2.3 is in RC stage right now... it's VERY sharp looking (I've been running the betas for over a month on my primary box)... The FreeBSD version line in the pfSense RC is "FreeBSD 10.3-RELEASE". So it may not be stable yet, but it's very close I'm sure.
-
I just upgraded to pfSense 2.3 tonight (which was easy, flawless, and without issue). However, the temp sensor readout broke again. It looks like the amdtemp fix didn't make it into FreeBSD 10.3. So I recompiled the FreeBSD 10.3 kernel and got a new amdtemp.ko file.
-
Unload the module first: kldunload amdtemp.ko
-
Rename the attached file to amdtemp.ko and copy it to /boot/kernel/amdtemp.ko and /boot/modules/amdtemp.ko
-
Load the module: kldload amdtemp.ko
-
Test sensor from command line: sysctl -a | grep temperature
-
Enjoy the new Temp Sensor readout
-
-
I just upgraded to pfSense 2.3 tonight (which was easy, flawless, and without issue). However, the temp sensor readout broke again. It looks like the amdtemp fix didn't make it into FreeBSD 10.3. So I recompiled the FreeBSD 10.3 kernel and got a new amdtemp.ko file.
-
Unload the module first: kldunload amdtemp.ko
-
Rename the attached file to amdtemp.ko and copy it to /boot/kernel/amdtemp.ko and /boot/modules/amdtemp.ko
-
Load the module: kldload amdtemp.ko
-
Enjoy the new Temp Sensor readout
How is your CPU temp so low ?
I have the fitlet-X and it idles at 54 C. -
-
I purchased the heatsink for the i-A10, and also have it sitting on a "rack" I built with a low RPM, 80mm fan blowing on it ;D
-
LOL nice !
Was kinda hoping you had some BIOS trickery going on to cool it so much.
I already installed the heatsink, it did cool it a bit, but…meh.
54-56 isn't too bad. I'm hoping it doesn't mess with the mSata SSD in there.I guess I could hack a usb powered fan, but that would negate the low-power aspect of this machine.
-
I think it should be good up to 70°C. The fan is connected to a USB port on the wifi access point, so the power consumption doesn't count against the Fitlet :P
-
Any performance figures for this interesting cpu setup? Routing throughput & openvpn?
-
Thanks Fahrenhe1t for the help :). Mine is working great now… It's nice to have temp readings...
-
Any performance figures for this interesting cpu setup? Routing throughput & openvpn?
I have a Netgear Nighthawk router plugged into the Fitlet pfSense box using bridge mode. I use that as my wifi access point.
Between two wired boxes connected locally there, using iPerf3, I get close to theoretical max throughput:
$ iperf3 -c fitlet -f m -n 1024M iPerf Client Connecting to host fitlet, port 5201 [ 5] local 192.168.x.x port 54552 connected to 192.168.x.x port 5201 [ ID] Interval Transfer Bandwidth [ 5] 0.00-1.00 sec 113 MBytes 947 Mbits/sec [ 5] 1.00-2.00 sec 112 MBytes 940 Mbits/sec [ 5] 2.00-3.00 sec 112 MBytes 940 Mbits/sec [ 5] 3.00-4.00 sec 112 MBytes 940 Mbits/sec [ 5] 4.00-5.00 sec 112 MBytes 940 Mbits/sec [ 5] 5.00-6.00 sec 112 MBytes 940 Mbits/sec [ 5] 6.00-7.00 sec 112 MBytes 940 Mbits/sec [ 5] 7.00-8.00 sec 112 MBytes 940 Mbits/sec [ 5] 8.00-9.00 sec 112 MBytes 940 Mbits/sec [ 5] 9.00-9.13 sec 14.4 MBytes 940 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ ID] Interval Transfer Bandwidth [ 5] 0.00-9.13 sec 1.00 GBytes 941 Mbits/sec sender [ 5] 0.00-9.13 sec 1024 MBytes 941 Mbits/sec receiver
I don't have a stellar Internet connection (Comcast, 170Mbps down/12Mbps up) but I'm able to get those speeds through pfSense with xfinity speedtest:
I have OpenVPN setup…I'll try and get on wifi somewhere else and do an iPerf while VPN'd in.
-
That test tells us the switching speed of your night hawk :)
If possible you should setup an additional interface on the firewall on its own subnet, plug a pc into that and measure with another pc on the lan/different subnet.
You could then probably enable an openvpn server on this new interface, connect to that from a pc/openvpn-client then do a speed test to a client on the lan. -
Just sent you a PM.
-
Using AT&T 4G, I VPN'd back home. I have iPerf3 running on another box internally and ran a test. I got 3.61 Mbits/sec.
Connecting to a wifi network with 10mbps up and down, I ran the test again and got 8.47mbps. I'll see if I can find a faster wifi network to test on.
**Update, got 17.9mbps connecting back to VPN on a friend's wifi with 40down/20up.
-
Just upgraded to 2.3.1 and temp widget is broken again… :(
redid your procedure and it's back... :) -
Just upgraded to 2.3.1 and temp widget is broken again… :(
redid your procedure and it's back... :)Thanks for the heads up, mine just did the same thing on 2.3.1 (not to be confused with 2.3_1 :o)
-
haven't done 2.3.1_1 yet…
-
I just did, and had to reload amdtemp.ko. I ended up writing a shell script to copy the files and enable the service.
-
Wish they would include your mod. 2.3.2 time….
-
Wish they would include your mod. 2.3.2 time….
Same. I think FreeBSD has to include it in their release though. Someone else already submitted a bug (https://lists.freebsd.org/pipermail/freebsd-bugs/2016-February/066274.html); not sure how to get FreeBSD to include the fix in a release though…
-
Fahrenhe1t, I'm running pfSense 2.3.2p1 w/ A6-5400K CPU with set to AMD and dashboard temps read 0C to 1C, varies. No where close to accurate. So tried your recompiled 10.3 amdtemp.ko file. Didn't change anything. My two other boxes with Intel CPU and A6-6400K work fine without a modified amdtemp.ko file. Ideas, mistakes I may have made?
-
Fahrenhe1t, I'm running pfSense 2.3.2p1 w/ A6-5400K CPU with set to AMD and dashboard temps read 0C to 1C, varies. No where close to accurate. So tried your recompiled 10.3 amdtemp.ko file. Didn't change anything. My two other boxes with Intel CPU and A6-6400K work fine without a modified amdtemp.ko file. Ideas, mistakes I may have made?
Strange! From the command line, what does the OS report if you run this: sysctl -a | grep temperature
-
dev.cpu.1.temperature: 0.0C
dev.cpu.0.temperature: 0.0CSame as before the modified file was copied to the box.
-
BIOS reports 33C
-
Do you know if the temperature is able to be read from a different operating system?
Maybe you could boot Ubuntu from USB on your pfSense box (without installing it), install the lm-sensors package, then run: sudo sensors
If it returns accurate CPU temperature, then you know it's a problem with FreeBSD not detecting your CPU properly.It looks like the A6-5400K CPU was released in 2012. If I had to guess, I bet FreeBSD (and the and specifically amdtemp.ko) doesn't detect the CPU properly. The CPU ID would have to be determined, the new sensor line would have to be added to the amdtemp source code, then it would have to be recompiled with the new CPU information. I'm just guessing though.
-
Thats a good idea but then I still have a broken temperature status. Your right the cpu is a bit old. I think I'll cut my time losses and try an A6-7470K. If it works I'll keep the 5400 as a back up.
-
Actually, I think the CPU is fine, it's just that amdtemp.ko isn't always updated with "new" CPU's. If you don't have any luck with the new CPU, I might be able to try and compile a new amdtemp.ko, you'd just have to tell me what the CPU ID is. In the source code, the CPU ID's look like this:
#define DEVICEID_AMD_MISC14 0x1703 #define DEVICEID_AMD_MISC15 0x1603 #define DEVICEID_AMD_MISC16 0x1533 #define DEVICEID_AMD_MISC16_X3 0X1583
The last one is the ID for my A10 Micro-6700T. I have no idea how that can be found though.
-
The newer cpu reports the same. I'll look for the DEVICEID.
-
The only ID I find is 630F81. Not sure where those txt strings come from in the amdtemp.ko file.