khorton / nas_fan_control

collection of scripts to control fan speed on NAS boxes
BSD 2-Clause "Simplified" License
72 stars 33 forks source link

probably works with X11DPH-T #7

Open asdf4w3t5 opened 6 months ago

asdf4w3t5 commented 6 months ago

Hello, I have this board

dmidecode -t 2
# dmidecode 3.4
Getting SMBIOS data from sysfs.
SMBIOS 3.1.1 present.

Handle 0x0002, DMI type 2, 15 bytes
Base Board Information
    Manufacturer: Supermicro
    Product Name: X11DPH-T
    Version: 1.10

I'm using several commands from your script (not the entirety of the script) but they all work. e.g.

#READ FAN MODE
#ipmitool raw 0x30 0x45 0x00

# SET FAN MODE TO "FULL"
ipmitool raw 0x30 0x45 0x01 0x01

#set zone 0 to 60%
ipmitool raw 0x30 0x70 0x66 0x01 0x00 0x60

These work fine. All the other modes work correctly too but these are what I'm using. So we can say this board works as well. In the script comments a few boards that work and wanted to add this one to the list so others know. https://github.com/khorton/nas_fan_control/blob/35e626cce0b56c44792954e87b07ca6fd9df0529/PID_fan_control.pl#L25


Also I see this is an error everywhere but just wanted to say my numbers if it helps anyone: my fans at 60% (according to ipmitool) are actually at 100%. It thinks that 3000RPM is their max even though ipmitool sensor says 25500.000 this is wrong twice over. Internally it thinks that number is "3000" not "25500.000" Because via ipmitool 50% fan speed = 1500 60% fan speed = 1800 etc Therefore we can see that it is thinking 3000rpm is the max. and to repeat again: however via ipmitool sensor it says 25500.000 lol

and manufacturer noctua of fan says 1800 is max.

so ipmitool reads the BMC wrong and then the BMC reads the fan wrong? not sure how that is double wrong but it is.

khorton commented 6 months ago

Curious - presumably ipmitool sdr also shows "25500.000".

asdf4w3t5 commented 6 months ago

It shows "1800" which is what it's running at now, Here are the columns from ipmitool sensor

Mine doesn't show the column headers but from what I read those are the max values or something on the right side there image

and the sdr command image

I just bought another fan but right now I only have 1 4pin fan lol

if it matters https://www.amazon.com/dp/B00KF7MVI2

If I am running ipmitool raw 0x30 0x70 0x66 0x01 0x00 0x60 it sets it to 1800rpm however anything above this value then goes to "1900rpm" and that is the max it'll go. I have read this is just stressing the fan possibly so I keep it at the "max rating" but to be clear it won't go up higher than that, no matter the setting. It just says those large numbers on the output but it never can be set to them

It may be normal for the X11 motherboards. I don't know other boards but this guy has an upermicro X11SSH-F board He has the headers "unc | ucr | unr" also says what they are Upper Non-critical Upper Non-Recoverable Upper Critical https://www.nodinrogers.com/post/2021-11-30-using-ipmi-on-supermicro-motherboards-to-control-fans/

Sorry I am just learning this stuff. I've never even looked at it before, usually just run on 2 pins or the bios has controls on regular desktop

khorton commented 6 months ago

The first column in the output from ipmitool sensor is the actual value. The last six columns are the low and thresholds set in the BMC. These are used to monitor the sensor for issues. It is possible to set those values to something more sensible, but I don't think it is worth the effort.

So, it looks like ipmitool is correctly reading the fan RPM. I'm not sure why if 60% command gives 1800 rp;m, 100% only gives 1900. But, it is what it is.

asdf4w3t5 commented 6 months ago

Yep, sorry if it wasn't clear when I said their "max" I meant that "unc / ucr / unr"

I got another of the same exact fan now and at 60% one is 1800 and other is 1900 at 50% both are 1600 at 55% both are 1700

very cool (not) LOL well I guess I can see why so many have headaches with this.

Thanks for the script and the info within the script though. Got me up and going.

You can close this just wanted to let you know the X11 boards seem to work with my board / other guys reporting it.

khorton commented 6 months ago

One possible area of misunderstanding - when ipmitool tells the BMC to set the Fan to a certain percentage, this is not a percent of max speed. It is a percent duty cycle. At 100% duty cycle, power is sent to the fan all the time, continuously. At 50% duty cycle, the power to the fan cycles on and off quickly, with the power ON 50% of the time, and OFF 50% of the time. The cycles happen so quickly that the fan speed is relatively constant, as it isn't OFF long enough for the fan to coast down.

The point is that the power required to turn the fan is not linear with rpm - the aerodynamic drag varies with the square of the rpm. So, an increase of duty cycle from 50% to 100% would only be expected to increase the fan speed by roughly the square root of 2, or 1.4x. So, if 50% duty cycle gives 1600 rpm, you'd expect 100% duty cycle would give roughly 2300 rpm.

Another point - the BMC rounds the fan speed off to the nearest 100 rpm. So those two fans that are reporting 1800 and 1900 might actually be 1845 and 1855.