On 9/19/2019 7:42 PM, Charles Curley wrote: > The stock gpsd package runs fine on buster. The default is that it only > listens on the loopback interface. I would like it to listen on other > interfaces so that other computers can monitor the GPS data. The gpsd > list has been less than enlightening. > > (Warning: long lines ahead. Your mail client may wrap them into utter > unreadability.) > > I did find > https://stackoverflow.com/questions/42240757/access-gpsd-port-2947-over-network, > and implemented the first solution, the over-ride in gpsd.socket. That > did not work, in fact local clients were blocked from the daemon as > well as remote clients. > > I then backed out those changes, and re-enabled my prior setup: > > [Unit] > Description=GPS (Global Positioning System) Daemon Sockets > > [Socket] > ListenStream=/var/run/gpsd.sock > ListenStream=[::1]:2947 > # ListenStream=127.0.0.1:2947 > ListenStream=0.0.0.0:2947 > SocketMode=0600 > # BindIPv6Only=ipv6-only > > # # per > https://stackoverflow.com/questions/42240757/access-gpsd-port-2947-over-network > # # First blank ListenStream clears the system defaults > # ListenStream= > # ListenStream=2947 > # ListenStream=/var/run/gpsd.sock > > > [Install] > WantedBy=sockets.target > > With the old configuration re-enabled, I can now get a connection from > a remote client. This makes no sense. > > I made all changes effective with: > > systemctl daemon-reload > systemctl restart gpsd > > And if necessary, re-plugging the GPS receiver. > > > In addition, I also found out that running "systemctl disable gpsd" > does not in fact disable it: > > root@hawk:/etc/systemd/system# systemctl stop gpsd ; systemctl disable > gpsd ; systemctl status gpsd > Warning: Stopping gpsd.service, but it can still be activated by: > gpsd.socket > Synchronizing state of gpsd.service with SysV service script with > /lib/systemd/systemd-sysv-install. > Executing: /lib/systemd/systemd-sysv-install disable gpsd > insserv: warning: current start runlevel(s) (empty) of script `gpsd' > overrides LSB defaults (2 3 4 5). > insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script > `gpsd' overrides LSB defaults (0 1 6). > insserv: warning: current start runlevel(s) (empty) of script `gpsd' > overrides LSB defaults (2 3 4 5). > insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script > `gpsd' overrides LSB defaults (0 1 6). > ● gpsd.service - GPS (Global Positioning System) Daemon > Loaded: loaded (/lib/systemd/system/gpsd.service; disabled; vendor > preset: enabled) > Active: active (running) since Thu 2019-09-19 11:23:50 MDT; 515ms ago
This is expected, 'desable' will prevent the service from starting at boot. To kill a service you need to use 'stop'.: $ systemctl stop <SERVICE-NAME> -- John Doe