Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.sys.raspberry-pi > #10984

Re: GPSD not starting automatically

From David Taylor <david-taylor@blueyonder.co.uk.invalid>
Newsgroups comp.sys.raspberry-pi
Subject Re: GPSD not starting automatically
Date 2016-03-04 16:50 +0000
Organization A noiseless patient Spider
Message-ID <nbce7s$12m$1@dont-email.me> (permalink)
References <nb6huq$lj2$1@dont-email.me> <nb6mjp$1mi$1@dont-email.me> <nb6upj$5v4$1@dont-email.me> <nb75eu$q20$1@dont-email.me>

Show all headers | View raw


On 02/03/2016 16:47, Martin Gregorie wrote:
> On Wed, 02 Mar 2016 14:56:42 +0000, David Taylor wrote:
>
>> On 02/03/2016 12:34, Martin Gregorie wrote:
>>> On Wed, 02 Mar 2016 11:17:36 +0000, David Taylor wrote:
>>>
>>>> When first booting the RPi gpsd does /not/ autostart in spite of "-n"
>>>> being present in the options.  This used to work under Wheezy.
>>>>
>>> Where are these options of which you speak?
>>>
>>>> So I enter:  "sudo service gpsd restart"  and gpsd is then running as
>>>> normal.  I guess I'm missing something obvious, but what?  Any
>>>> thoughts about what the problem might be, and how to proceed with
>>>> further diagnosis?
>>>>
>>> Is the -n option present in both the ExecStart and ExecReload lines in
>>> the [Service] section of gpsd.service?
>>
>> The options are entered by manually editing  /etc/default/gpsd  in
>> Jessie.  I have:
>>
>> START_DAEMON="true"
>> GPSD_OPTIONS="-n  /dev/ttyAMA0"
>> DEVICES=""
>> USBAUTO="false"
>> GPSD_SOCKET="/var/run/gpsd.sock"
>>
>> although I've also tried:
>>
>> START_DAEMON="true"
>> GPSD_OPTIONS="-n"
>> DEVICES="/dev/ttyAMA0"
>> USBAUTO="false"
>> GPSD_SOCKET="/var/run/gpsd.sock"
>>
>> Where might I find gpsd.service?  That's not a file I am familiar with
>> at all, but I'd like to check it.
>
> Not having gpsd installed, I looked at crond.service to check the keynames
> in the [Service] section. There were copies in /etc/systemd/system/* and /
> usr/lib/systemd/system - if its not in either, try "locate gpsd.service".
>
> For an explanation of the content of .service files, try
>
>     man 5 systemd.service
>
> which mainly covers the [Service] section of a .service file and contains
> references to other manpages which cover the contents of the [Unit] and
> [Install] sections as well as other material.
>
> One thing I should have asked earlier: what does "systemctl status gpsd"
> show?
>
> The reason I ask is that by default systemd daemons are disabled when
> they're first installed - under Fedora anyway. This means that although
> you can start them with 'systemctl start servicename', they will not
> start automatically at boot time until you've run
> "systemctl enable servicename".
>
> This is no different from sysVinit, where you had to do exactly the same
> using syscontrol whenever you installed a new daemon in order to tell it
> which runlevels it should be active at.

Martin,

Thanks for all that!  I located the service file here:

   /lib/systemd/system/gpsd.service

It contains:

[Unit]
Description=GPS (Global Positioning System) Daemon
Requires=gpsd.socket

[Service]
EnvironmentFile=-/etc/default/gpsd
ExecStart=/usr/sbin/gpsd -N $GPSD_OPTIONS $DEVICES

[Install]
Also=gpsd.socket

I don't see why that wouldn't start the service, but I really know very 
little at this level.

Again the issue is:

- reboot
- gpsd service does/not/ start
- run cgps and exit
- gosd service is started

It's just as if the "-n" parameter is being ignored.

-- 
Cheers,
David
Web: http://www.satsignal.eu

Back to comp.sys.raspberry-pi | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

GPSD not starting automatically David Taylor <david-taylor@blueyonder.co.uk.invalid> - 2016-03-02 11:17 +0000
  Re: GPSD not starting automatically David <wibble@btintenet.com> - 2016-03-02 12:22 +0000
    Re: GPSD not starting automatically David Taylor <david-taylor@blueyonder.co.uk.invalid> - 2016-03-02 14:59 +0000
      Re: GPSD not starting automatically alister <alister.ware@ntlworld.com> - 2016-03-02 17:16 +0000
  Re: GPSD not starting automatically Martin Gregorie <martin@address-in-sig.invalid> - 2016-03-02 12:34 +0000
    Re: GPSD not starting automatically David Taylor <david-taylor@blueyonder.co.uk.invalid> - 2016-03-02 14:56 +0000
      Re: GPSD not starting automatically Martin Gregorie <martin@address-in-sig.invalid> - 2016-03-02 16:47 +0000
        Re: GPSD not starting automatically David Taylor <david-taylor@blueyonder.co.uk.invalid> - 2016-03-04 16:50 +0000
          Re: GPSD not starting automatically Tomasz Torcz <zdzichu@irc.-spamu.nie.chce-.pl> - 2016-03-04 17:14 +0000
            Re: GPSD not starting automatically David Taylor <david-taylor@blueyonder.co.uk.invalid> - 2016-03-05 20:58 +0000
              Re: GPSD not starting automatically markallenshell@gmail.com - 2016-03-05 18:34 -0800
          Re: GPSD not starting automatically Martin Gregorie <martin@address-in-sig.invalid> - 2016-03-04 17:32 +0000

csiph-web