Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    PowerD causes repeating syslog message

    Scheduled Pinned Locked Moved General pfSense Questions
    23 Posts 3 Posters 6.1k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • stephenw10S
      stephenw10 Netgate Administrator
      last edited by

      I see your lowest c state is c1. That might be a better way to save power. Are there any c state options in the BIOS?
      Have you actually measured the power consumption? It's probably not actually using 65W. My own experience was that the real power saving was barely measurable.

      Steve

      1 Reply Last reply Reply Quote 0
      • stephenw10S
        stephenw10 Netgate Administrator
        last edited by

        This thread might explain what's happening in your case. If so there's not a lot can be done though it's not a problem at least.
        http://freebsd.1045724.n5.nabble.com/stable-9-broken-hwpstate-calls-td5709583.html

        Steve

        1 Reply Last reply Reply Quote 0
        • M
          markn62
          last edited by

          Funny Keji, I know this sounds trivial.  Any power savings tied to a UPS is a necessary consideration.  The BIOS manual states nothing related to C1.

          Interestingly, with only the throttle hint entered since a reboot and changing PowerD to HiAdaptive for both A/C and battery I now get variable CPU speeds from 1800 to 3900 and no log errors.  Lucky combo?  I know FreeBsd 8.3 defaults to Adaptive so I would think I could have got lucky by making them match, not different.  I'll look into this further in the context of the PowerD settings, loader.conf entries and actual idle pwr usage.

          Thanks Steve and others for your help on this.  Been a healthy learning curve jumping from McAfee (formerly Snapgear) embedded products to PfSense.  A bit more involved but interesting nonetheless.

          1 Reply Last reply Reply Quote 0
          • K
            kejianshi
            last edited by

            If you have it working for a while without error and I load pfsense onto something tiny I might scam off your effort later.

            I will also be building a small ups soon - so it might help.

            1 Reply Last reply Reply Quote 0
            • M
              markn62
              last edited by

              I think I better see the problem with command powerd -v.  Any ideas what wants the odd frequencies?  Is PowerD asking for it or is it based on info PowerD gets from the BIOS?  I can't understand where these odd numbers come from.  Even figuring in a  turbo mode frequency offset (factor) it still doesn't add up.  Not to mention Turbo is disabled in BIOS. CPU freq 3900Mhz on turbo is 4100Mhz which should be the highest frequency PowerD should want.  7800 is the highest reported which is exactly double 3900, is this because it has 2 cores?  Who knows, maybe it's doing some odd math where one core is non-turbo and one is turbo and then adds together.  Puzzling.

              This weekend I'll put command debug.hwpstate_verbose="1" into /boot/loader.conf.local and reboot to see what is really going on behind the curtain.


              powerd -v
              load  7%, current freq  225 MHz (16), wanted freq 1439 MHz
              changing clock speed from 225 MHz to 1575 MHz

              load  13%, current freq  225 MHz (16), wanted freq 1394 MHz
              changing clock speed from 225 MHz to 1575 MHz

              load  15%, current freq  225 MHz (16), wanted freq 1350 MHz
              changing clock speed from 225 MHz to 1350 MHz

              load 120%, current freq  450 MHz (15), wanted freq 5400 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  70%, current freq 3900 MHz ( 0), wanted freq 7800 MHz

              load  7%, current freq  675 MHz (14), wanted freq 7556 MHz
              changing clock speed from 675 MHz to 3900 MHz

              load  10%, current freq 3900 MHz ( 0), wanted freq 7319 MHz

              load  8%, current freq  450 MHz (15), wanted freq 7090 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  28%, current freq 3900 MHz ( 0), wanted freq 7090 MHz

              load  6%, current freq  450 MHz (15), wanted freq 6868 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  13%, current freq 3900 MHz ( 0), wanted freq 6653 MHz

              load  4%, current freq  450 MHz (15), wanted freq 6445 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  12%, current freq 3900 MHz ( 0), wanted freq 6243 MHz

              load  4%, current freq  450 MHz (15), wanted freq 6047 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  21%, current freq 3900 MHz ( 0), wanted freq 5858 MHz

              load  8%, current freq 3900 MHz ( 0), wanted freq 5674 MHz

              load  34%, current freq  450 MHz (15), wanted freq 5674 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  6%, current freq 3900 MHz ( 0), wanted freq 5496 MHz

              load  17%, current freq  450 MHz (15), wanted freq 5324 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  19%, current freq 3900 MHz ( 0), wanted freq 5157 MHz

              load  19%, current freq  450 MHz (15), wanted freq 4995 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  16%, current freq 3900 MHz ( 0), wanted freq 4838 MHz

              load  16%, current freq  450 MHz (15), wanted freq 4686 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  10%, current freq 3900 MHz ( 0), wanted freq 4539 MHz

              load  0%, current freq  450 MHz (15), wanted freq 4397 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  16%, current freq 3900 MHz ( 0), wanted freq 4259 MHz

              load  0%, current freq  450 MHz (15), wanted freq 4125 MHz
              changing clock speed from 450 MHz to 3900 MHz

              load  10%, current freq 3900 MHz ( 0), wanted freq 3996 MHz

              load  20%, current freq  225 MHz (16), wanted freq 3871 MHz
              changing clock speed from 225 MHz to 3900 MHz

              load  12%, current freq 3900 MHz ( 0), wanted freq 3750 MHz

              load  38%, current freq  225 MHz (16), wanted freq 3800 MHz changing clock speed from 225 MHz to 3900 MHz


              sysctl dev.cpu.0.freq_levels

              dev.cpu.0.freq_levels: 3900/21266 3600/17212 3150/15060 3100/12350 2712/10806 2600/9225 2275/8071 2200/6075 1925/5315 1800/3977 1575/3479 1350/2982 1125/2485 900/1988 675/1491 450/994 225/497

              1 Reply Last reply Reply Quote 0
              • M
                markn62
                last edited by

                Another idea to try.  According to this blog, pwr management is suppose to be enabled in BIOS.  I have it disabled because I thought only the Windows OS used it.  Could explain the odd "wanted" frequencies powerd reports.  I'll have to try enabling it as was done here;

                https://www.ateamsystems.com/blog/Increase-FreeBSD-Performance-With-powerd?goback=%2Egde_47628_member_188127582#%21

                Quote: Using AMI's server BIOS as an example, the option is located under the Advanced tab, then go to CPU Configuration and then CPU Power Management Configuration and set Power Technology to "Energy Efficient" and then Energy/Performance Bias to "Performance".  Each BIOS is different obviously so some poking around might be needed for your servers.  The key is that both these BIOS changes need to be made and powerd needs to be enabled otherwise there is no gain (we tested it … a lot).

                1 Reply Last reply Reply Quote 0
                • stephenw10S
                  stephenw10 Netgate Administrator
                  last edited by

                  That looks like what you see if you still have ACPI throttling enabled. Did you re-enable it? Could also be p4tcc confusing things.
                  Interesting to see what the debug option reveals. With newer bioses, especially not using ACPI like yours, I guess anything could be true. Changing those bios settings can alter what the bios tells the OS about the CPU/board. You can certainly disble p-state changing entirely doing that.

                  Steve

                  1 Reply Last reply Reply Quote 0
                  • M
                    markn62
                    last edited by

                    Well I finally determined the right combo for this MSI FM2-A85XMA0-E35 mobo.  I had to enable Cool'n'Quiet (CnQ) in BIOS.  PowerD enabled with CnQ disabled was causing the log errors.  Once CnQ and PowerD was enabled, PowerD wouldn't work with ACPI throttling disabled so I removed the disable line from /boot/loader.conf.local.  But did add sysctl debug.cpufreq.lowest=1949  to keep throttling from dropping too far.

                    Not sure it will work in /boot/, but should since it works from the command line.  Really should go into sysctl.conf (without the debug) but it appears to be a temp file not to be edited.

                    So I'll know for sure next reboot if it's sticky.  I thought I read about a command that you could define specific frequencies, rather than a range, but can't find it.  I would prefer to set this as only 3900Mhz and 1900Mhz so it doesn't step down thru the others in between.

                    So anyways, happy days again.  Haven't got a chance to measure actual power use but will at my first opportunity.

                    1 Reply Last reply Reply Quote 0
                    • stephenw10S
                      stephenw10 Netgate Administrator
                      last edited by

                      Sysctls that can be added after boot can be added to the System Tunables table in System: Advanced:

                      Steve

                      1 Reply Last reply Reply Quote 0
                      • M
                        markn62
                        last edited by

                        Well how easy is that???  So this table is only for sysctl's?  Meaning I would add a new entry and put "debug.cpufreq.lowest" as the "tunable name" along with a value of 1949 and whatever description I want?  Is the value in decimal or hex?

                        1 Reply Last reply Reply Quote 0
                        • stephenw10S
                          stephenw10 Netgate Administrator
                          last edited by

                          Yes, just like you say.

                          Steve

                          1 Reply Last reply Reply Quote 0
                          • First post
                            Last post
                          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.