package gpsd 2.39-5 failed to install/upgrade: subprocess installed post-installation script returned error exit status 10

Bug #468915 reported by Walter_Wittel
82
This bug affects 16 people
Affects Status Importance Assigned to Milestone
gpsd (Ubuntu)
Fix Released
Undecided
Bernd Zeimetz

Bug Description

Binary package hint: gpsd

Got the same errors during the (worst upgrade I have ever experienced) jaunty->karmic upgrade process. I tried a reinstall from Synaptic and got same errors:

The configuration must at least specify either a device that gpsd should connect to, or a control socket (using the -F option). USB autodetection requires /var/run/gpsd.sock as control socket.

Here is my old /etc/default/gpsd file (still there):

# Default settings for gpsd.
# Please do not edit this file directly - use `dpkg-reconfigure gpsd' to
# change the options.
START_DAEMON="true"
DAEMON_OPTS=""
DEVICES="/dev/ttyUSB0"
USBAUTO="true"

apt-cache policy gpsd reports:
gpsd:
  Installed: 2.39-5
  Candidate: 2.39-5
  Version table:
 *** 2.39-5 0
        500 http://mirror.its.uidaho.edu karmic/universe Packages
        100 /var/lib/dpkg/status

In case it doesn't get attached:
Linux waltld7 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:04:26 UTC 2009 i686 GNU/Linux

ProblemType: Package
AptOrdering:
 gpsd-clients: Install
 gpsd: Configure
 ttf-mscorefonts-installer: Configure
 gpsd-clients: Configure
Architecture: i386
Date: Sun Nov 1 08:18:19 2009
DistroRelease: Ubuntu 9.10
ErrorMessage: subprocess installed post-installation script returned error exit status 10
Package: gpsd 2.39-5
ProcVersionSignature: Ubuntu 2.6.31-14.48-generic
SourcePackage: gpsd
Title: package gpsd 2.39-5 failed to install/upgrade: subprocess installed post-installation script returned error exit status 10
Uname: Linux 2.6.31-14-generic i686

Revision history for this message
Walter_Wittel (wittelw) wrote :
Revision history for this message
Walter_Wittel (wittelw) wrote :

I did a complete removal (Synaptic) then reinstalled (which returned error 1).

I get an error if I try to reconfigure per instructions in the old gpsd configuration (but maybe these no longer apply):

walter@waltld7:~$ sudo dpkg-reconfigure gpsd
/usr/sbin/dpkg-reconfigure: gpsd is broken or not fully installed

Revision history for this message
Bernd Zeimetz (bzed) wrote : Re: [Bug 468915] Re: package gpsd 2.39-5 failed to install/upgrade: subprocess installed post-installation script returned error exit status 10

Walter_Wittel wrote:
> I did a complete removal (Synaptic) then reinstalled (which returned
> error 1).
>
> I get an error if I try to reconfigure per instructions in the old gpsd
> configuration (but maybe these no longer apply):
>
> walter@waltld7:~$ sudo dpkg-reconfigure gpsd
> /usr/sbin/dpkg-reconfigure: gpsd is broken or not fully installed
>

Try to delete /etc/default/gpsd or follow the instructions (hint: specify the
docket path in the daemon options). I'll make the config process more simple in
the next upload.

--
 Bernd Zeimetz Debian GNU/Linux Developer
 http://bzed.de http://www.debian.org
 GPG Fingerprints: 06C8 C9A2 EAAD E37E 5B2C BE93 067A AD04 C93B FF79
                   ECA1 E3F2 8E11 2432 D485 DD95 EB36 171A 6FF9 435F

Revision history for this message
Walter_Wittel (wittelw) wrote :

Thanks Bernd. I tried that but still got the error:

E: gpsd: subprocess installed post-installation script returned error exit status 1

I had also run computer janitor (about 4 or 5 iterations) which removed a bunch of other stuff but it still fails to install. I had the USB GPS dongle plugged in in case that was necessary to configure.

I attached my zipped dpkg.log (includes earlier failures etc. also) in case it helps. If other info would be helpful let me know.

I would be happy to try some other things as time permits if you have other suggestions. Thanks!

Revision history for this message
Bernd Zeimetz (bzed) wrote :

What did you use to upgrad the packages? Old-fashined console tools like apt-get
ot aptitude or something with a GUI?

--
 Bernd Zeimetz Debian GNU/Linux Developer
 http://bzed.de http://www.debian.org
 GPG Fingerprints: 06C8 C9A2 EAAD E37E 5B2C BE93 067A AD04 C93B FF79
                   ECA1 E3F2 8E11 2432 D485 DD95 EB36 171A 6FF9 435F

Revision history for this message
Walter_Wittel (wittelw) wrote :

Following the jaunty->karmic upgrade (via Update Manager), I used the Synaptic GUI to reinstall (failed), then remove completely and reinstall (also failed). I used the GUI Computer Janitor to remove all suggested packages (took several iterations as once some were gone others were suggested). I then tried again with Synaptic to install (gpsd was already gone from a previous remove completely, as was the /etc/default/gpsd file). This also failed.

I just tried:
sudo apt-get update
sudo apt-get purge gpsd gpsd-clients
sudo apt-get install gpsd gpsd-clients

and got the same failure:
The following NEW packages will be installed:
  gpsd gpsd-clients
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B/200kB of archives.
After this operation, 561kB of additional disk space will be used.
Preconfiguring packages ...
Selecting previously deselected package gpsd.
(Reading database ... 180905 files and directories currently installed.)
Unpacking gpsd (from .../archives/gpsd_2.39-5_i386.deb) ...
Selecting previously deselected package gpsd-clients.
Unpacking gpsd-clients (from .../gpsd-clients_2.39-5_i386.deb) ...
Processing triggers for man-db ...
Processing triggers for sreadahead ...
Processing triggers for menu ...
Setting up gpsd (2.39-5) ...
 * Starting GPS (Global Positioning System) daemon gpsd [fail]
invoke-rc.d: initscript gpsd, action "start" failed.
dpkg: error processing gpsd (--configure):
 subprocess installed post-installation script returned error exit status 1
Setting up gpsd-clients (2.39-5) ...

Processing triggers for menu ...
Errors were encountered while processing:
 gpsd
E: Sub-process /usr/bin/dpkg returned an error code (1)

Hope this helps.

Revision history for this message
Bernd Zeimetz (bzed) wrote :

Walter_Wittel wrote:
> I just tried:
> sudo apt-get update
> sudo apt-get purge gpsd gpsd-clients
> sudo apt-get install gpsd gpsd-clients

[...]
> Setting up gpsd (2.39-5) ...
> * Starting GPS (Global Positioning System) daemon gpsd [fail]
> invoke-rc.d: initscript gpsd, action "start" failed.

This is *weird*.
Could you add a
set -x
at the second line of
/etc/init.d/gpsd
and run
dpkg --configure --pending
and then show me the output?

Thanks,

Bernd

--
 Bernd Zeimetz Debian GNU/Linux Developer
 http://bzed.de http://www.debian.org
 GPG Fingerprints: 06C8 C9A2 EAAD E37E 5B2C BE93 067A AD04 C93B FF79
                   ECA1 E3F2 8E11 2432 D485 DD95 EB36 171A 6FF9 435F

Revision history for this message
Walter_Wittel (wittelw) wrote :

I added set -x on a line following the set -e (rather than replacing that) and got the following output:

walter@waltld7:/etc/init.d$ sudo dpkg --configure --pending
Setting up gpsd (2.39-5) ...
+ PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
+ DAEMON=/usr/sbin/gpsd
+ DESC=GPS (Global Positioning System) daemon
+ PIDFILE=/var/run/gpsd.pid
+ dirname /etc/init.d/gpsd
+ cd /etc/init.d
+ pwd -P
+ basename /etc/init.d/gpsd
+ SELF=/etc/init.d/gpsd
+ test -x /usr/sbin/gpsd
+ . /lib/lsb/init-functions
+ FANCYTTY=
+ [ -e /etc/lsb-base-logging.sh ]
+ . /etc/lsb-base-logging.sh
+ [ -f /etc/default/gpsd ]
+ . /etc/default/gpsd
+ START_DAEMON=true
+ DAEMON_OPTS=-F /var/run/gpsd.sock
+ DEVICES=
+ USBAUTO=true
+ [ xtrue = xtrue ]
+ log_daemon_msg Starting GPS (Global Positioning System) daemon gpsd
+ [ -z Starting GPS (Global Positioning System) daemon ]
+ log_use_usplash
+ [ n = y ]
+ type usplash_write
+ usplash_write TEXT Starting GPS (Global Positioning System) daemon gpsd
+ log_to_console log_daemon_msg Starting GPS (Global Positioning System) daemon gpsd
+ [ n != y ]
+ [ no != yes ]
+ readlink /proc/self/fd/0
+ stdin=pipe:[21403]
+ [ pipe:[21403] != pipe:[21403] ]
+ return 0
+ log_use_fancy_output
+ TPUT=/usr/bin/tput
+ EXPR=/usr/bin/expr
+ [ -t 1 ]
+ [ xxterm != x ]
+ [ xxterm != xdumb ]
+ [ -x /usr/bin/tput ]
+ [ -x /usr/bin/expr ]
+ /usr/bin/tput hpa 60
+ /usr/bin/tput setaf 1
+ [ -z ]
+ FANCYTTY=1
+ true
+ /usr/bin/tput xenl
+ /usr/bin/tput cols
+ COLS=80
+ [ 80 ]
+ [ 80 -gt 6 ]
+ /usr/bin/expr 80 - 7
+ COL=73
+ printf * Starting GPS (Global Positioning System) daemon gpsd
 * Starting GPS (Global Positioning System) daemon gpsd + /usr/bin/expr 80 - 1
+ /usr/bin/tput hpa 79
                                                                               + printf
 + start-stop-daemon --start --quiet --exec /usr/sbin/gpsd -- -F /var/run/gpsd.sock -P /var/run/gpsd.pid
+ log_end_msg 1
+ [ -z 1 ]
+ log_use_usplash
+ [ n = y ]
+ type usplash_write
+ [ 1 -eq 0 ]
+ usplash_write FAILURE failed
+ log_to_console log_end_msg 1
+ [ n != y ]
+ [ no != yes ]
+ readlink /proc/self/fd/0
+ stdin=pipe:[21403]
+ [ pipe:[21403] != pipe:[21403] ]
+ return 0
+ [ 73 ]
+ [ -x /usr/bin/tput ]
+ printf \r
+ /usr/bin/tput hpa 73
                                                                         + [ 1 -eq 0 ]
+ printf [
[+ /usr/bin/tput setaf 1
+ printf fail
fail+ /usr/bin/tput op
+ echo ]
]
+ return 1
invoke-rc.d: initscript gpsd, action "start" failed.
dpkg: error processing gpsd (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 gpsd
walter@waltld7:/etc/init.d$

Revision history for this message
Bernd Zeimetz (bzed) wrote :

Walter_Wittel wrote:
                                                                               +
printf
> + start-stop-daemon --start --quiet --exec /usr/sbin/gpsd -- -F /var/run/gpsd.sock -P /var/run/gpsd.pid

This looks pretty much right.
Could you run
/usr/sbin/gpsd -D 2 -N -F /var/run/gpsd.sock -P /var/run/gpsd.pid
on the console and see if gpsd starts properly - it should stay in the the
foreground and produce a lot of debug output.
If that works well - could the problem reside in usplash? Seems you're using
that, and I remember that it had a similar bug in Debian. Not exactly sure any
more, though.

--
 Bernd Zeimetz Debian GNU/Linux Developer
 http://bzed.de http://www.debian.org
 GPG Fingerprints: 06C8 C9A2 EAAD E37E 5B2C BE93 067A AD04 C93B FF79
                   ECA1 E3F2 8E11 2432 D485 DD95 EB36 171A 6FF9 435F

Revision history for this message
Ossy Gómez (mandocon) wrote :

Hi, guys. This is what worked for me, not only for gpsd, but for open-jdk too, another hard to fix issue I had after upgrading to karmic.
I executed aptitude in a terminal. Then I executed a query for gpsd, just to know what depended on it. Then I uninstalled those first. Did the same for open-jdk. After another failed attempt to uninstall, exited aptitude and created gpsd.sock using "sudo vim /var/run/gpsd.sock". Just inserted a space character and wrote the file. /etc/default/gpsd already existed.
Back to aptitude, completely uninstalled whatever packages were annoying me. Success.
Being late last night, turned off my computer. This morning I tried reinstalling gpsd through Synaptic. All went smooth and fine.
Hope this work for you too.
Oswaldo Gomez
-----Original Message-----
From: "Bernd Zeimetz" <email address hidden>
To: <email address hidden>
Sent: 02/11/2009 06:37 a.m.
Subject: Re: [Bug 468915] Re: package gpsd 2.39-5 failed to install/upgrade: subprocess installed post-installation script returned error exit status 10

Walter_Wittel wrote:
                                                                               +
printf
> + start-stop-daemon --start --quiet --exec /usr/sbin/gpsd -- -F /var/run/gpsd.sock -P /var/run/gpsd.pid

This looks pretty much right.
Could you run
/usr/sbin/gpsd -D 2 -N -F /var/run/gpsd.sock -P /var/run/gpsd.pid
on the console and see if gpsd starts properly - it should stay in the the
foreground and produce a lot of debug output.
If that works well - could the problem reside in usplash? Seems you're using
that, and I remember that it had a similar bug in Debian. Not exactly sure any
more, though.

--
 Bernd Zeimetz Debian GNU/Linux Developer
 http://bzed.de http://www.debian.org
 GPG Fingerprints: 06C8 C9A2 EAAD E37E 5B2C BE93 067A AD04 C93B FF79
                   ECA1 E3F2 8E11 2432 D485 DD95 EB36 171A 6FF9 435F

--
package gpsd 2.39-5 failed to install/upgrade: subprocess installed post-installation script returned error exit status 10
https://bugs.launchpad.net/bugs/468915
You received this bug notification because you are a direct subscriber
of the bug.

Revision history for this message
Walter_Wittel (wittelw) wrote :

@Bernd:

walter@waltld7:~$ /usr/sbin/gpsd -D 2 -N -F /var/run/gpsd.sock -P /var/run/gpsd.pid
gpsd: can't listen on local socket /var/run/gpsd.sock
gpsd: control socket create failed, netlib error -1

Also tried as root:
gpsd: launching (Version 2.39)
gpsd: Can't bind to port gpsd
gpsd: Maybe gpsd is already running!

@Ossy:
I will try your suggestion when I have more time tonight after work.

Thanks to both for your help.

Revision history for this message
Bernd Zeimetz (bzed) wrote :

Walter_Wittel wrote:
> @Bernd:
>
> walter@waltld7:~$ /usr/sbin/gpsd -D 2 -N -F /var/run/gpsd.sock -P /var/run/gpsd.pid
> gpsd: can't listen on local socket /var/run/gpsd.sock
> gpsd: control socket create failed, netlib error -1

This is weird.... Could you please check and ensure that there is no gpsd
instance running at the moment? Maybe it failed to stop a running instance
during the upgrade.
ps -C gpsd -fww
should give you a list. If there is one running, please kill it and give dpkg
--reconfigure --pending a try again.
If there was none running it really sounds like some Ubuntu breakage as this
doesn't happen on Debian. Then please do the following:

- Install the package strace
- Run the following:
strace -vfF -o /tmp/gpsd.strace usr/sbin/gpsd -D 2 -N -F /var/run/gpsd.sock -P
/var/run/gpsd.pid
- Send me the created file /tmp/gpsd.strace
- Send me the output of cat /proc/mounts

Thanks for your help!

Bernd

--
 Bernd Zeimetz Debian GNU/Linux Developer
 http://bzed.de http://www.debian.org
 GPG Fingerprints: 06C8 C9A2 EAAD E37E 5B2C BE93 067A AD04 C93B FF79
                   ECA1 E3F2 8E11 2432 D485 DD95 EB36 171A 6FF9 435F

Revision history for this message
Walter_Wittel (wittelw) wrote :

Hi Bernd,

I'll describe what I did (hopefully the correct order / steps / etc.):

gpsd was running so I killed it and then ran dpkg --configure --pending and it looks like it succeeded (dpkg-configure.txt in the attached zipped file).

I then ran:
walter@waltld7:~$ sudo strace -vfF -o /tmp/gpsd.strace /usr/sbin/gpsd -D 2 -N -F /var/run/gpsd.sock -P /var/run/gpsd.pid

gpsd seemed to be running, and I could plug my GPS (Pharos GPS-500 SIRF III) and from the terminal it seemed to detect and connect, but produced "gpsd: Satellite data no good (3 of 3)." errors. I had (after some learning curve to get it configured) had this working under jaunty.

I unplugged the GPS and typed ctrl-c to stop (gpsd.strace in attached file). Also Road Map 1.2.1 didn't seem to be able to get any useful GPS data from the device (not in attached strace), but i have not recompiled that application since upgrading to karmic and maybe there is something else unrelated going on.

I also added the output of cat /proc/mounts (proc-mounts.txt) to the attached zip file.

Hopefully this will help you figure out what happened during the upgrade. I would be happy to try more stuff if would be helpful or perhaps fix the unrelated problem I seem to have with my Pharos GPS. Thanks once again! Walter

Revision history for this message
Walter_Wittel (wittelw) wrote :

I did get Road Map to compile again but still the same result (gps not showing any data). Also I tried xgps and it didn't show any satellites or skyview. So I don't know if this is a upgrade / config issue or changes related to supported devices.

Bernd Zeimetz (bzed)
Changed in gpsd (Ubuntu):
assignee: nobody → Bernd Zeimetz (bzed)
status: New → In Progress
Revision history for this message
Bernd Zeimetz (bzed) wrote :

Fixed in Debian/unstable 2.39-7

Changed in gpsd (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (4.0 KiB)

This bug was fixed in the package gpsd - 2.39-8ubuntu1

---------------
gpsd (2.39-8ubuntu1) lucid; urgency=low

  * Sync from Debian 2.39-8, this version is known to work. Please
    get in contact with me or Bernd before touching it again.

gpsd (2.39-8) unstable; urgency=low

  * [a9e9d167] Export needed variables for the hotplug script. (Closes:
    #556956) - thanks to Luca Niccoli
  * [254f1da4] Add a missing % which caused USB autostart to fail.
    (Closes: #556954) - thanks to Luca Niccoli
  * [2990d2cc] Updating debconf translation: pt.po (Closes: #556250) -
    thanks to "Traduz - Portuguese Translation Team"
  * [dc6305e7] Updating debconf translation: sv.po (Closes: #556580) -
    thanks to Martin Bagge
  * [6066918d] Add missing : in po files and unfuzzy them.

gpsd (2.39-7) unstable; urgency=low

  [ Bernd Zeimetz ]
  * [bda49bd9] Bumping Standards-Version to 3.8.3. No changes needed.
  * [cdf3c74c] Fix hotplug script environment patch to ensure that
    'None' is not passed as gpsd option.
  * [67cde41b] Don't check for "$START_DAEMON" = "true" in
    gpsd.hotplug.wrapper anymore.
  * [c4fb8bab] Go trough all debconf questions if the daemon is started
    at boot *or* USB autodetection is enabled.
  * [f929f33f] Add dbus to 'Suggests' of gpsd.
  * [9dd1656f] Rewriting gpsd.init completely. The new start-stop-daemon
    options should ensure that gpsd is stopped definitely, hopefully
    this fixes an upgrade problem which was reported on Launchpad. (LP:
    #468915) - thanks to Walter Wittel
  * [376285e7] Updating gpsd.templates after review. - thanks to Justin
    B Rye
  * [e5d5e1f7] Updating po files for new gpsd.templates.
  * [6e23af3e] Update po files after running debconf-updatepo.
  * [691c564c] Add missing : to the control path question.
  * [8da65d0a] Running debconf-updatepo again.

  [ Esko Arajärvi ]
  * [77a66dc2] Updating debconf translation: fi.po (Closes: #554478)

  [ Kenshi Muto ]
  * [389d8f08] Updating debconf translation: ja.po (Closes: #554576)

  [ dooteo ]
  * [400eada8] Updating debconf translation: eu.po (Closes: #554540)

  [ Ivan Masár ]
  * [67146d71] Updating debconf translation: sk.po (Closes: #554681)

  [ Luca Monducci ]
  * [c52ba7fa] Updating debconf translation: it.po (Closes: #555117)

  [ Eddy Petrișor ]
  * [afb4ef0b] Updating debconf translation: ro.po (Closes: #555464)

  [ Thomas Mueller ]
  * [9f7c21e9] Updating debconf translation: de.po (Closes: #555840)

  [ Miroslav Kure ]
  * [e4246738] Updating debconf translation: cs.po (Closes: #555894)

  [ Francisco Javier Cuadrado ]
  * [3a72944f] Updating debconf translation: es.po (Closes: #556035)

  [ Yuri Kozlov ]
  * [4beef045] Updating debconf translation: ru.po (Closes: #556193)

  [ marce ]
  * [325806a3] Updating debconf translation: gl.po (Closes: #555453)

gpsd (2.39-6) experimental; urgency=low

  [ Christian Perrier ]
  * [fe381184] Updating debconf translation: fr.po (Closes: #540502)

  [ Jordà Polo ]
  * [2c23a9a6] Updating debconf translation: ca.po (Closes: #544101)

  [ Clytie Siddall ]
  * [49af80a6] Updating debconf translation: vi.po (Closes: #548020)

  [ Bernd Zeimetz ]
  * [35fe08a1] Correct dependencies in init....

Read more...

Changed in gpsd (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.