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

    Dashboard Thermal Sensors use "unfriendly names" for Core >= 4

    Scheduled Pinned Locked Moved 2.1.1 Snapshot Feedback and Problems - RETIRED
    12 Posts 3 Posters 3.9k 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.
    • J
      jasonlitka
      last edited by

      I reported this in redmine (#3337, https://redmine.pfsense.org/issues/3337) 4 months back and it slipped my mind until today when I spun up a new box with 8 cores.

      Is there any chance that this bug could be fixed for 2.1.1?

      I can break anything.

      1 Reply Last reply Reply Quote 0
      • J
        jasonlitka
        last edited by

        Thank you!

        I can break anything.

        1 Reply Last reply Reply Quote 0
        • rbgargaR
          rbgarga Developer Netgate Administrator
          last edited by

          @Jason:

          Thank you!

          Did the fix work?

          Renato Botelho

          1 Reply Last reply Reply Quote 0
          • J
            jasonlitka
            last edited by

            @Renato:

            @Jason:

            Thank you!

            Did the fix work?

            Hmmm…  Actually, no.  It still shows "dev.cpu.#.temperature" for cores 4-7.

            I can break anything.

            1 Reply Last reply Reply Quote 0
            • rbgargaR
              rbgarga Developer Netgate Administrator
              last edited by

              Are you using the latest 2.1.1 snapshot? Did you clean browser's cache?

              Renato Botelho

              1 Reply Last reply Reply Quote 0
              • J
                jasonlitka
                last edited by

                @Renato:

                Are you using the latest 2.1.1 snapshot? Did you clean browser's cache?

                Yes (Sun Mar 23 12:34:36 EDT 2014) and yes.  I also checked the JS file and your changes are in there.

                I can break anything.

                1 Reply Last reply Reply Quote 0
                • rbgargaR
                  rbgarga Developer Netgate Administrator
                  last edited by

                  @Jason:

                  @Renato:

                  Are you using the latest 2.1.1 snapshot? Did you clean browser's cache?

                  Yes (Sun Mar 23 12:34:36 EDT 2014) and yes.  I also checked the JS file and your changes are in there.

                  The odd thing is, the new code do not make any distinction for zones less or greater than 4, so, if this code is wrong, you should see the unfriendly name for all Cores instead of seeing it only for Cores > 4. It sounds to me like something is still cached. It works fine on my tests here.

                  Renato Botelho

                  1 Reply Last reply Reply Quote 0
                  • J
                    jasonlitka
                    last edited by

                    I just updated to (Mon Mar 24 14:54:23 EDT 2014) and still no joy.  I've tried clearing the cache on Chrome, switching to IE, and even using another computer which has never accessed pfSense.

                    Is there another section of code that needs to change?

                    I can break anything.

                    1 Reply Last reply Reply Quote 0
                    • rbgargaR
                      rbgarga Developer Netgate Administrator
                      last edited by

                      I don't think so, it still shows correct zones <= 4?

                      Renato Botelho

                      1 Reply Last reply Reply Quote 0
                      • J
                        jasonlitka
                        last edited by

                        I figured it out.  Before I installed the updated snapshot I had applied the patch manually using "System > Patches".  This apparently left a thermal_sensors.js.orig file sitting around with the original code in it and was, for some reason, being included on the page.  Since it was loaded after the updated one it overrode the fixed function with the old one.  Once I deleted the .orig file the names started displaying properly.

                        I guess the question now is, why was a .orig file being included?

                        I can break anything.

                        1 Reply Last reply Reply Quote 0
                        • P
                          phil.davis
                          last edited by

                          Yes, I noticed this also when I had a little play. I had copied the original to thermal_sensors.save.js and had the same issue wondering why changed code in thermal_sensors.js did not do anything.
                          /usr/local/www/index.php has this code:

                          	//build list of javascript include files
                          $jsincludefiles = array();
                          $directory = "widgets/javascript/";
                          $dirhandle = opendir($directory);
                          $filename = "";
                          while (false !== ($filename = readdir($dirhandle))) {
                          $jsincludefiles[] = $filename;
                          }
                          foreach($jsincludefiles as $jsincludename) {
                          if(!stristr($jsincludename, ".js"))
                          continue;
                          echo "\n";
                          }
                          
                          

                          which includes all the files in that directory that have ".js" anywhere in the name.
                          Lesson is that when fiddling with the system, put backup copies of stuff you are messing with into some other directory well away from where any run-time code will ever look for it. (Or be the hacker from hell and just dump the new code over the top of what you had:)

                          As the Greek philosopher Isosceles used to say, "There are 3 sides to every triangle."
                          If I helped you, then help someone else - buy someone a gift from the INF catalog http://secure.inf.org/gifts/usd/

                          1 Reply Last reply Reply Quote 0
                          • rbgargaR
                            rbgarga Developer Netgate Administrator
                            last edited by

                            Fixed, only files that ends with .js will be considered.

                            Renato Botelho

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