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

NTP Server Time

Problems Installing or Upgrading pfSense Software
7
15
3.4k
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.
  • W
    Wizard220
    last edited by Oct 18, 2017, 10:45 AM

    Hello All

    I am having a issue under 2.4 with the NTP server time.  It seems no matter the time zone the ntp clock is 4 hours off, ie, it is 4 hours ahead of my time.  I am in the America/Newyork time zone.  I have tried several time zones under the system > general settings and the ntp clock is always 4 hours ahead of my time.

    The ntp server time works like it should under 2.3.4_1 build but seems to be broken under 2.4

    On a side note under the system info widget my current time is showing correctly but using the NTP Server Time widget the time is 4 hours off.  I have added more NTP time servers to the pool and the ones I added are from NIST Washington DC.

    1 Reply Last reply Reply Quote 0
    • J
      johnpoz LAYER 8 Global Moderator
      last edited by Oct 18, 2017, 12:27 PM Oct 18, 2017, 12:23 PM

      So your saying the system widget shows your EDT timezone, and the widget also shows EDT or its showing the wrong timezone?

      Did you reboot after changing a timezone?
      https://doc.pfsense.org/index.php/Time_is_not_correct,_but_the_time_zone_appears_to_be_set_properly
      Processes on FreeBSD (and thus pfSense) only pick up time changes when they are started. If the firewall has not been rebooted since the last time zone change, doing so will ensure that all running processes are using the correct time zone

      Keep in mind widget use to pull computer time vs the actual server time.

      https://doc.pfsense.org/index.php/2.4_New_Features_and_Changes#NTP
      https://redmine.pfsense.org/issues/7245

      An intelligent man is sometimes forced to be drunk to spend time with his fools
      If you get confused: Listen to the Music Play
      Please don't Chat/PM me for help, unless mod related
      SG-4860 24.11 | Lab VMs 2.7.2, 24.11

      1 Reply Last reply Reply Quote 0
      • W
        Wizard220
        last edited by Oct 18, 2017, 10:49 PM

        The System widget shows the correct date/time and time zone.  The NTP widget shows the correct time zone but is 4 hours AHEAD of the correct time.  Now I did some tests and here is what I found:

        1- When running 2.3.4_p build of pfsense all the dates, times and time zones works like they should.  Both the system and NTP server widgets are correct and all works.

        2- When running 2.4.0 the SYSTEM widget is good but the NTP widget is incorrect.  No matter what time zone I use it is always showing 4 hours ahead of my time zone EDT.  Now it was mentioned about the date and time in bios so I did some checking and found that pfsense 2.4.0 was infact going into my bios and changing the time.  The date is correct but the time was ALWAYS being set 4 hours ahead.  I did reboots and bios checks and have resetted the time to the correct time but when pfsense boots my bios clock would be reset to 4 hours ahead.

        3- under 2.3.4 bios clock was not messed with aka all is good to go.  Under 2.4.0 the bios clock would get messed with and be set 4 hours ahead.

        Don't know what is going on with the new pfsense 2.4.X builds but 2.3.4 worked and that is what I am now running.  Also under 2.4.X I was getting stuck widget process on boot and 2.3.4 I do not get any errors on boot.

        I will revisit 2.4.X once the bugs are worked out and it has some time under it's belt.  Not knocking it, really do like it but since I do not have a router to use for a just in case situation I need something reliable and 2.3.4 is rock solid to me.

        1 Reply Last reply Reply Quote 0
        • J
          johnpoz LAYER 8 Global Moderator
          last edited by Oct 19, 2017, 8:24 AM

          dude if the time was off by 4 hours.. It would show in the system.. Its a stupid widget..

          What does it show for time when you ssh in? and do date

          An intelligent man is sometimes forced to be drunk to spend time with his fools
          If you get confused: Listen to the Music Play
          Please don't Chat/PM me for help, unless mod related
          SG-4860 24.11 | Lab VMs 2.7.2, 24.11

          1 Reply Last reply Reply Quote 0
          • W
            Wizard220
            last edited by Oct 19, 2017, 1:45 PM

            Sorry can't answer what the date/time would be if I SSH into the box.  Not running 2.4.X anymore, running 2.3.4.  I no longer am having any time issues since reverting back to 2.3.4.  But something is up with 2.4.X since it is going into my bios and changing the time.  Date is correct but the time is being messed with.

            1 Reply Last reply Reply Quote 0
            • J
              johnpoz LAYER 8 Global Moderator
              last edited by Oct 19, 2017, 3:56 PM

              If that was actually the case then forums would be blowing up with people reporting such a problem.

              Your saying your bios time is being changed to be in the wrong timezone.. But the system widget shows the correct timezone and time.  But the ntp status widget shows correct timezone but 4 hours off.. So 4 hours ahead of EDT.. ie New York… So UTC -1 What is that the freaking Azores?

              Makes zero sense dude really...

              An intelligent man is sometimes forced to be drunk to spend time with his fools
              If you get confused: Listen to the Music Play
              Please don't Chat/PM me for help, unless mod related
              SG-4860 24.11 | Lab VMs 2.7.2, 24.11

              1 Reply Last reply Reply Quote 0
              • A
                Ayelborne
                last edited by Oct 19, 2017, 4:31 PM Oct 19, 2017, 4:19 PM

                I saw this same problem when updating 2.4.1 this morning.  No issue with BIOS time being incorrect/reset, but NTP widget time is incorrect.  Seems to be related to this redmine item:

                https://redmine.pfsense.org/issues/7714#change-34352

                1 Reply Last reply Reply Quote 0
                • J
                  johnpoz LAYER 8 Global Moderator
                  last edited by Oct 19, 2017, 4:56 PM Oct 19, 2017, 4:46 PM

                  Yeah I would say its related for sure..

                  // Have to convet the date to UTC time to match the PHP clock not the local client clock.

                  You an see that comment in the code..  So my guess is the OP clients timezone was off.  Not sure how he was saying his bios time was being shifted… bios time should be in UTC... But depending on the OS - windows for example sometimes there can be problems when bios is UTC, etc.    Believe there was a reg edit at one time for windows 7, etc.

                  its always difficult getting to the bottom of stuff when the OP doesn't post any actual info to work with... Like the status of his ntp server via ntpq etc.  And what the system shows with date command.

                  What the php time is.. put a simple phpinfo.php file in /usr/local/www and then call it in your browser to see what php has the timezone set to, etc.

                  An intelligent man is sometimes forced to be drunk to spend time with his fools
                  If you get confused: Listen to the Music Play
                  Please don't Chat/PM me for help, unless mod related
                  SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                  1 Reply Last reply Reply Quote 0
                  • P
                    pfSense4ME
                    last edited by Oct 19, 2017, 4:51 PM

                    @ Johnpoz
                    Your saying your bios time is being changed to be in the wrong timezone.. But the system widget shows the correct timezone and time.  But the ntp status widget shows correct timezone but 4 hours off.. So 4 hours ahead of EDT.. ie New York… So UTC -1 What is that the freaking Azores?

                    Makes zero sense dude really...

                    Actually, it kind of does...  I just think the poster is not doing a good job of explaining.  Maybe I can shed some light on the issue and stay clear of the mud.  Here goes nothing...

                    I have several computers, some desktops, some laptops, some servers, all from different manufactures (IE: Dell, HP, ASUS, etc). being used as workstations or servers depending on their role.  Some of the systems have Microsoft (necessary evil as a result of my job) loaded as the OS while others have Linux (or BSD, etc.  Example: pfSense on a Dell 7010, pfSense based on BSD. You get the idea.)  OK here's where it gets funky:

                    On all of the systems if I access the BIOS and set time to the correct time for my timezone (Eastern) say for example 1:00PM prior to the installation of an OS.  Then depending on the OS I install the BIOS time may "float".  Let me explain.  If I install the Windows OS, set the time and timezone within the OS, shut the system down or restart/reboot and access the BIOS, the time in the BIOS will show the same as the what is in Windows.  However, if I install a Linux or BSD OS, set the date within the OS, shut the system down or restart/reboot and access the BIOS, the time in the BIOS will "float" ahead 4 hours (in my case as I'm in eastern TZ and the DST vs EST is now at -4 hours GMT).  End result is the BIOS time "floats" to compensate for the actual time, being reported in the OS (IE: BIOS time now shows 5:00PM but because of my Eastern -4 hour GMT we get back to 1:00PM actual time reported within the OS).  Thus giving the appearance the system is using a different TZ in the BIOS as a factor to calculate the time.  It's totally weird!  Why non Windows OSes do this I don't know, but from my findings they do regardless of the manufacturer (Dell, HP, ASUS, etc).  I generally use Linux (actually prefer) more so than Windows so it's baffling to me why Linux (or BSD, etc) does it this way.  And yes, when first transitioning away from Windows I went crazy fighting the BIOS time vs. the Linux OS time, now I don't even bother.  What I do wish is that the non-Windows community would "fix" their time value (internal vs BIOS) so as to work more in keeping with the way Windows does it in order to avoid all this confusion.  My findings are based on using steel systems and not virtual systems.  I don't know if that makes a difference or not.

                    Hopefully what I described above makes some sense.

                    1 Reply Last reply Reply Quote 0
                    • J
                      johnpoz LAYER 8 Global Moderator
                      last edited by Oct 19, 2017, 4:58 PM

                      Yeah see my edit I was working before you posted.  In the linux world you normally set your bios time to UTC… This is standard practice..

                      An intelligent man is sometimes forced to be drunk to spend time with his fools
                      If you get confused: Listen to the Music Play
                      Please don't Chat/PM me for help, unless mod related
                      SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                      1 Reply Last reply Reply Quote 0
                      • P
                        pete
                        last edited by Oct 19, 2017, 6:29 PM Oct 19, 2017, 6:26 PM

                        Mine is looking OK here.

                        That can I make a request that the NTP time widget include the GPS/PPS time stuff?

                        How do insert an image in the middle of my text and remove it from the bottom of my post?

                        I am used to using forum tools or just

                        ![NTP Dashboard.jpg](/public/imported_attachments/1/NTP Dashboard.jpg)
                        ![NTP Dashboard.jpg_thumb](/public/imported_attachments/1/NTP Dashboard.jpg_thumb)
                        NTPStatus.jpg
                        NTPStatus.jpg_thumb

                        • Pete

                        Auto mater
                        23.09.1-RELEASE (amd64)
                        built on Mon Dec 11 12:24:00 CST 2023
                        FreeBSD 14.0-CURRENT
                        PFSense + Qotom - Master
                        PFSense + Jetway - Backup
                        PFSense + Jetway - Backup
                        PFSense + Generic - Backup

                        1 Reply Last reply Reply Quote 0
                        • J
                          johnpoz LAYER 8 Global Moderator
                          last edited by Oct 19, 2017, 6:43 PM

                          "How do insert an image in the middle of my text and remove it from the bottom of my post?"

                          You can't with attachments.  If you want an image inline with your post you would have to put in img tag and link to image hosted somewhere.

                          An intelligent man is sometimes forced to be drunk to spend time with his fools
                          If you get confused: Listen to the Music Play
                          Please don't Chat/PM me for help, unless mod related
                          SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                          1 Reply Last reply Reply Quote 0
                          • P
                            pete
                            last edited by Oct 19, 2017, 8:48 PM

                            Thank you John.

                            Is there a way to display the GPS/PPS stuff in the NTP widget on the dashboard?

                            • Pete

                            Auto mater
                            23.09.1-RELEASE (amd64)
                            built on Mon Dec 11 12:24:00 CST 2023
                            FreeBSD 14.0-CURRENT
                            PFSense + Qotom - Master
                            PFSense + Jetway - Backup
                            PFSense + Jetway - Backup
                            PFSense + Generic - Backup

                            1 Reply Last reply Reply Quote 0
                            • J
                              jahonix
                              last edited by Oct 20, 2017, 9:30 PM

                              @pete:

                              How do insert an image in the middle of my text and remove it from the bottom of my post?

                              Where's the problem with that?

                              I used the URL from one of your attached pictures and used it here with the {img} tag.

                              1 Reply Last reply Reply Quote 0
                              • J
                                jclear
                                last edited by Oct 21, 2017, 11:31 AM

                                A bit of history:  Back in 1980 the IBM PC came with MSDOS on 160K floppies.  No room for TZ files.  So MSDOS set its time directly from the CMOS clock.  So generally you'd set that to local or "wall clock" time.  When folks started porting the UTC based *nix to the PC, provision was made to deal will wall clock CMOS time so as to be able to dual boot nicely.  For FreeBSD, the presence or absence of /etc/wall_cmos_clock was used to tell the kernel if the CMOS time was local or UTC.  See FreeBSD's adjkerntz(8).  Can't tell you how Linux does it, but presumably it has it's own method to coexist with DOS.

                                Checking  my pFsense install ( fresh 2.3.x on an APU2) I don't see /etc/wall_cmos_clock, so presumably the pFsense default is to have the CMOS set to UTC.  But perhaps the OP put pFsense originally on a box with local time in cmos and does have that file.

                                Now I haven't yet migrated my servers from FreeBSD 10 to 11, so don't know if FreeBSD made changes to the process.  But possibly it has changed and pFsense 2.4 picked that up, and maybe that config is confusing the NTP Widget.  Although why the NTP widget is looking at anything other than a NTP query and displaying UTC (NTP doesn't deal with local times at all) is beyond me.  But given OP's NTP peer status his system is probably running time correctly.  It would be worth looking at the system log after a boot to see if the "ntpdate" was jumping the time by 4 hours (assuming pFsense overrides the limiter).  That would be a good indication of confusion between what the kernel thinks is in the CMOS and what actually is.

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