OPNsense
  • Home
  • Help
  • Search
  • Login
  • Register

  • OPNsense Forum »
  • Archive »
  • 18.7 Legacy Series »
  • 18.7.6 issues with NTP & GPS
« previous next »
  • Print
Pages: [1]

Author Topic: 18.7.6 issues with NTP & GPS  (Read 13046 times)

va176thunderbolt

  • Newbie
  • *
  • Posts: 46
  • Karma: 4
  • Nothing is more permanent than a temp solution
    • View Profile
18.7.6 issues with NTP & GPS
« on: October 30, 2018, 05:41:05 am »
I have a GPS attached serially and configured in NTP as a time source. Works great - sync's right up. However, when I go into Services/Network Time/Status, I get a php error:

[30-Oct-2018 09:38:37 Etc/GMT-5] PHP Warning:  A non-numeric value encountered in /usr/local/www/status_ntpd.php on line 100
[30-Oct-2018 09:38:37 Etc/GMT-5] PHP Warning:  A non-numeric value encountered in /usr/local/www/status_ntpd.php on line 102
[30-Oct-2018 09:38:37 Etc/GMT-5] PHP Warning:  A non-numeric value encountered in /usr/local/www/status_ntpd.php on line 103
[30-Oct-2018 09:38:37 Etc/GMT-5] PHP Warning:  A non-numeric value encountered in /usr/local/www/status_ntpd.php on line 105

The Dashboard Network Time widget  also chokes.

I've submitted a couple of error reports, and I'd be happy to allow someone access if they needed to test/troubleshoot on my box.

Adam
Logged
AMD Ryzen 3 1200
GA-A320M-S2H
8GB DDR4
Intel X550-T2 10GB
32GB Industrial SSD

Shuttle SZ270R8
Intel i5-6500
8gb ram
120gb ssd
Intel x540-t2 10gb nic

franco

  • Administrator
  • Hero Member
  • *****
  • Posts: 13671
  • Karma: 1175
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #1 on: October 30, 2018, 12:25:50 pm »
Hi Adam,

Would you mind providing the output of:

# /usr/local/sbin/ntpq -c clockvar


Thanks,
Franco
Logged

va176thunderbolt

  • Newbie
  • *
  • Posts: 46
  • Karma: 4
  • Nothing is more permanent than a temp solution
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #2 on: October 30, 2018, 12:30:10 pm »
adam@gw:~ % sudo /usr/local/sbin/ntpq -c clockvar
Password:
associd=0 status=00f2 15 events, clk_bad_format,
device="NMEA GPS Clock",
timecode="$GPRMC,112850,A,____.____,_,_____.____,_,000.0,190.7,301018,007.0,W*__",
poll=21419, noreply=8, badformat=261, baddata=0, fudgetime2=600.000,
stratum=0, refid=GPS, flags=13
adam@gw:~ %
Logged
AMD Ryzen 3 1200
GA-A320M-S2H
8GB DDR4
Intel X550-T2 10GB
32GB Industrial SSD

Shuttle SZ270R8
Intel i5-6500
8gb ram
120gb ssd
Intel x540-t2 10gb nic

franco

  • Administrator
  • Hero Member
  • *****
  • Posts: 13671
  • Karma: 1175
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #3 on: October 30, 2018, 12:33:14 pm »
Super, thanks! Will fix for 18.7.7.

https://github.com/opnsense/core/issues/2861


Cheers,
Franco
Logged

franco

  • Administrator
  • Hero Member
  • *****
  • Posts: 13671
  • Karma: 1175
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #4 on: October 30, 2018, 12:47:46 pm »
Is ____.____ the actual output or did you blank it? I'm asking because it can't parse latitude and longitude and I'm unsure how to parse correctly what is actually returned. I don't need the exact values, just the info whether each "_" is literally a number or not.


Cheers,
Franco
Logged

va176thunderbolt

  • Newbie
  • *
  • Posts: 46
  • Karma: 4
  • Nothing is more permanent than a temp solution
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #5 on: October 30, 2018, 12:51:26 pm »
That is the actual output.
Logged
AMD Ryzen 3 1200
GA-A320M-S2H
8GB DDR4
Intel X550-T2 10GB
32GB Industrial SSD

Shuttle SZ270R8
Intel i5-6500
8gb ram
120gb ssd
Intel x540-t2 10gb nic

franco

  • Administrator
  • Hero Member
  • *****
  • Posts: 13671
  • Karma: 1175
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #6 on: October 30, 2018, 01:18:22 pm »
Ok, so there may also be an issue with the GPS tracker itself.

In any case, will fix the malformed parsing. Thanks!
Logged

va176thunderbolt

  • Newbie
  • *
  • Posts: 46
  • Karma: 4
  • Nothing is more permanent than a temp solution
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #7 on: October 30, 2018, 01:26:06 pm »
Thanks Franco!
Logged
AMD Ryzen 3 1200
GA-A320M-S2H
8GB DDR4
Intel X550-T2 10GB
32GB Industrial SSD

Shuttle SZ270R8
Intel i5-6500
8gb ram
120gb ssd
Intel x540-t2 10gb nic

franco

  • Administrator
  • Hero Member
  • *****
  • Posts: 13671
  • Karma: 1175
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #8 on: November 11, 2018, 10:51:33 am »
Hi Adam,

Here is the patch with additional corrections for other GPS devices and GUI sanity:

https://github.com/opnsense/core/commit/0b58f2f48

Can you confirm it works for you?  Under the circumstances of the output it will show N/A for latitude and longitude since the GPS doesn't return any values.

# opnsense-patch 0b58f2f48


Cheers,
Franco
Logged

kapara

  • Jr. Member
  • **
  • Posts: 99
  • Karma: 3
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #9 on: April 26, 2019, 04:07:49 am »
Curious if this was resolved and also what GPS device you used via serial.
Logged

franco

  • Administrator
  • Hero Member
  • *****
  • Posts: 13671
  • Karma: 1175
    • View Profile
Re: 18.7.6 issues with NTP & GPS
« Reply #10 on: April 26, 2019, 05:24:36 am »
While the patch should speak for itself on the resolved front I don't know what the device was. Maybe Adam can shed some light on it.


Cheers,
Franco
Logged

  • Print
Pages: [1]
« previous next »
  • OPNsense Forum »
  • Archive »
  • 18.7 Legacy Series »
  • 18.7.6 issues with NTP & GPS
 

OPNsense is an OSS project © Deciso B.V. 2015 - 2023 All rights reserved
  • SMF 2.0.19 | SMF © 2021, Simple Machines
    Privacy Policy
    | XHTML | RSS | WAP2