Psense time way out of sync



  • Running 1.2-rc2 under w2k3 server and vmware server 1.0.3. Hardware is an AMD system x2 be-2300. Time server is setup and at boot, time is correct but then the clock goes a lot faster than real time. Tried to add the following command with no avail :
    kern.timecounter.hardware=TSC

    Any insight on this matter? TIA!



  • I haven't run into this problem myself, although I do use pfSense under vmware for testing.  I have come across several posts about the FreeBSD clock running slower or faster with vmware.  The recommendation to correct is to place the following into /boot/loader.conf:

    
    hint.apic.0.disabled=1
    
    

    HTH.

    Denny



  • Thanks! i´ll try that out. I suppose the added line "kern.timecounter.hardware=TSC" should be deleted then?



  • The installer already sets hint.apic.0.disabled=1 if vmware is detected.



  • @sullrich:

    The installer already sets hint.apic.0.disabled=1 if vmware is detected.

    I noticed that =(

    Any other suggestions? Time showed is merely double of real time



  • Does this also occur with a FreeBSD 6.2 guest (if it does then it confirms that it's a basic FreeBSD related issue)?

    Can you/have you locked pfSense to a single processor?

    Have you checked the VMWare forums for any related FreeBSD posts?  A quick search found http://www.vmware.com/community/thread.jspa?messageID=374609񛝑



  • This is a common issue with FreeBSD and VMware, but our installer has an auto-detect VMware function that uses appropriate settings (disabling APIC, slowing down the system timer, etc.). I've never seen VMware problems with FreeBSD using the settings we automatically use on VMware.



  • @Cry:

    Does this also occur with a FreeBSD 6.2 guest (if it does then it confirms that it's a basic FreeBSD related issue)?

    Can you/have you locked pfSense to a single processor?

    Have you checked the VMWare forums for any related FreeBSD posts?  A quick search found http://www.vmware.com/community/thread.jspa?messageID=374609񛝑

    • I don´t have any other guests under vmware. I could try though but my knowledge of *bsd is very limited, to say atleast  ::)

    • Pfsense is locked to one processor.

    • I´ve done a whole lot of searching to no avail :( Given thread was read by me earlier and the last reply in that thread is already implemented. kernel hz is 100hz by default and timecounter is set to "kern.timecounter.hardware=i8254" in /etc/sysctl.conf
      kern.timecounter.hardware=TSC is deleted

    An interesting sidenote could be that i´ve moved to pfsense from m0n0wall because also m0n0wall skewed in time. The big difference is that m0nn0wall stopped routing packets after approx. 3h uptime. This doesn´t happen with pfsense, strange imo since they both share a lot of codebase?!



  • is there perhaps the possibility to also add MS-Virtual PC and MS-Virtual Server to the autodetection of the installer ?
    pfsense runs fine with these two, i use pfsense in test-environment in this constellation…



  • @trendchiller:

    is there perhaps the possibility to also add MS-Virtual PC and MS-Virtual Server to the autodetection of the installer ?
    pfsense runs fine with these two, i use pfsense in test-environment in this constellation…

    Are there specific tweaks necessary for it to run properly in MSVPC and MSVS? If so, let us know exactly what they are, and this should be possible.



  • I'm having this same time issue. Is there any way to force PFSense to get the time from the NTP server? Then maybe schedule that job to run every once in a while.



  • I had a similar symptom with VM guests (various OS's) on my 2003 SP2 vmware server 1.04 host running on an Athlon X2 3800+.  After a lot of troubleshooting and research it turned out (in my case) to be an issue with the host OS and processor, rather than the guest.  So I do not believe this is particularly a pfSense/FreeBSD issue.

    In case it helps here's what I did to get the clocks in my VM guests to keep pretty accurate time without external syncs:

    1. Install the appropriate AMD drivers for the Processor under "AMD Athlon™ 64 X2 Dual Core Processor Driver Version 1.3.2.0053 for Windows XP and Windows Server 2003 (x86 and x64)" from:
      http://www.amd.com/us-en/Processors/TechnicalResources/0,,30_182_871_13118,00.html
    2. Reboot
    3. Install a MS hotfix to correct for XP SP2 issues with the Cool & Quiet features &  on the procs:
      http://www.microsoft.com/downloads/details.aspx?FamilyId=C2AB5A48-8240-4934-BBD8-34FB8A0FCE3B&displaylang=en
    4. Reboot
    5. Install "AMD Dual-Core Optimizer" from the same AMD page:
      http://www.amd.com/us-en/Processors/TechnicalResources/0,,30_182_871_13118,00.html
    6. Reboot

    I'm not sure if the reboots are necessary but after several iterations of installing and removing the components I finally got it to work for me when I did reboot after each install.  The only thing wrong now is that XP reports the CPU speed as 1 GHZ vs the 2 GHZ actual, even in msinfo32, but that was a problem before I installed any of the AMD drivers in the system.  Using the "AMD Power Monitor Version 1.1.5" from that same page I confirmed the speed/power throttling is working and it does max out at 2 GHZ when demand increases.

    If this is the same issue being faced here I believe the other option is to disable cool & quiet in the BIOS power saving setup on the host, which will run the proc and fans in the system at max speed and power regardless of system load.  Due to the nature of the PC in question that was not a viable option for me, so I fiddled around until I got it working with power management enabled.

    Hope that helps in some way.

    Additional References:
    http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2041
    http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2039
    http://forums.auran.com/fury/forum/showthread.php?t=775




Log in to reply