<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">On Sat, 6 Apr 2019 16:21:50 -0700<br>Paul Theodoropoulos <<a href="mailto:paul@anastrophe.com" target="_blank">paul@anastrophe.com</a>> wrote:<br><br>> gpsd needs to start before ntpd when using shm refclock.<br><div><br></div><div>That is completely opposite from my experience.  I have two systemd service files one to start gpsd and one to start ntpd.  the ntpd service file is from ntpsec distribution. gpsd service file is from gpsd distribution and edited to remove reference to gpsd.socket and change After=chronyd.service to ntpd.service.</div><div><br></div><div>If gpsd.service is started by hand first followed ntpd.service the following error is in ntpd.log,   REFCLOCK: SHM shmget (unit 1): Permission denied for both unit 1 and 0, and shm is not in ntpq -p.   If I start in reverse order no error message and ntpq -p show shm.</div><div><br></div><div>If both services are enabled and the system rebooted gpsd starts before ntpd, as indicated by process ids and error message in ntpd.log.  The after statement in gpsd has no effect.</div><div><br></div><div>New system fresh install of Arch Linux ARM, GPSD and NTPD.</div><div>System is raspi 3+</div><div>Linux tock2 4.19.34-1-ARCH #1 SMP PREEMPT Wed Apr 10 00:14:00 UTC 2019 armv7l GNU/Linux<br></div><div><br></div><div><div>tock2 ntpsec]# git rev-parse HEAD</div><div>2513a60a5569d93d83d04c99cea9bfc1d49d3669</div></div><div><br></div><div><div>tock2 gpsd]# git rev-parse HEAD</div><div>58547c8fd4f3b582cd2d5067c0134582d563ad4b</div></div><div><br></div><div><br></div><div>When I come up with a solution I'll post the ans. Now the fun begins</div><div><br></div><div>Fred</div><div><br></div><div><br></div></div></div></div></div></div>