package trousers 0.3.7-2ubuntu1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 137
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
| trousers (Ubuntu) |
High
|
Unassigned | ||
| Precise |
High
|
Unassigned | ||
| Quantal |
High
|
Unassigned |
Bug Description
[Impact]
Trousers users need to reboot (or restart udev) in order to fully complete configuration of the package. Worse, the install fails and prompts to open this bug with apport.
[Fix]
First, the problem. Though udev watches their rules files and re-reads them whenever something new is added, it does _not_ monitor when new users are groups are added to the system. We're left with:
Jul 31 21:21:46 neptune udevd[409]: specified user 'tss' unknown
Jul 31 21:21:46 neptune udevd[409]: specified group 'tss' unknown
The fix is to explicitly restart udev. This causes udev to reread users and groups and allows the initscript to start.
[Test Case]
1) make sure there is no tss user/group
2) apt-get install tpm-tools
[Regression Potential]
Very small. udevadm control --reload-rules is a benign command and we have it in other packages already.
[Original Report]
Setting up trousers (0.3.7-2ubuntu1) ...
Adding system user `tss' (UID 118) ...
Adding new group `tss' (GID 129) ...
Adding new user `tss' (UID 118) with group `tss' ...
Not creating home directory `/var/lib/tpm'.
* Starting Trusted Computing daemon tcsd [fail]
invoke-rc.d: initscript trousers, action "start" failed.
dpkg: error processing trousers (--configure):
subprocess installed post-installation script returned error exit status 137
No apport report written because MaxReports is reached already
tpm-tools depends on trousers; however:
Package trousers is not configured yet.
dpkg: error processing tpm-tools (--configure):
dependency problems - leaving unconfigured
ProblemType: Package
DistroRelease: Ubuntu 12.04
Package: trousers 0.3.7-2ubuntu1
ProcVersionSign
Uname: Linux 3.2.0-19-generic x86_64
NonfreeKernelMo
ApportVersion: 1.94.1-0ubuntu2
Architecture: amd64
Date: Mon Mar 19 16:16:56 2012
ErrorMessage: subprocess installed post-installation script returned error exit status 137
SourcePackage: trousers
Title: package trousers 0.3.7-2ubuntu1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 137
UpgradeStatus: No upgrade log present (probably fresh install)
Related branches
- Brian Murray: Approve on 2012-08-17
- Ubuntu branches: Pending requested 2012-08-01
-
Diff: 24 lines (+7/-0)2 files modifieddebian/changelog (+6/-0)
debian/trousers.postinst (+1/-0)
James P. Carter (jpcarter) wrote : | #1 |
James P. Carter (jpcarter) wrote : | #2 |
tags: | removed: need-duplicate-check |
James P. Carter (jpcarter) wrote : | #4 |
wow... strange... on a whim I decided to run through the installations to see if I could gather more information.
I changed directory to /var/cache/
dpkg -i trousers* (installed with no error)
dpkg -i tpm-tools* (installed with no error)
Perhaps something is missing... or perhaps 'I' am missing something here? Let me know if I need to do any additional tasks to help out here.
Thank you,
-james
Danny Fullerton (northox) wrote : | #5 |
I have the same problem but dpkg -i trousers* still fails.
# dpkg -i trouser*
(Reading database ... 177528 files and directories currently installed.)
Preparing to replace trousers 0.3.7-2ubuntu1 (using trousers_
* Stopping Trusted Computing daemon tcsd [ OK ]
Unpacking replacement trousers ...
Setting up trousers (0.3.7-2ubuntu1) ...
The system user `tss' already exists. Exiting.
* Starting Trusted Computing daemon tcsd [fail]
invoke-rc.d: initscript trousers, action "start" failed.
dpkg: error processing trousers (--install):
subprocess installed post-installation script returned error exit status 137
Processing triggers for ureadahead ...
Processing triggers for man-db ...
Errors were encountered while processing:
trousers
Launchpad Janitor (janitor) wrote : | #6 |
Status changed to 'Confirmed' because the bug affects multiple users.
Changed in trousers (Ubuntu): | |
status: | New → Confirmed |
James M. Leddy (jm-leddy) wrote : | #7 |
As near as I can tell, this is because user tss does not have access to tpm0. This causes start-stop-daemon in the init script to fail, which in turn causes the init script to fail, which means that the install will fail. The best way to fix this is to have tpm0 accessible to tss user.
open("/dev/tpm0", O_RDWR) = -1 EACCES (Permission denied)
open("/udev/tpm0", O_RDWR) = -1 ENOENT (No such file or directory)
open("/dev/tpm", O_RDWR) = -1 ENOENT (No such file or directory)
James M. Leddy (jm-leddy) wrote : | #8 |
Looks like commit 19 was designed to address this. The commands provided don't actually alter the permissions though:
https:/
James M. Leddy (jm-leddy) wrote : | #9 |
according to https:/
> There are some more recent changes in the git repository that provide caching of the udev rules and further volume UUID support (that would be nice for ProbeForRootFil
I think these caching rules went into effect, since udev is not re-reading rules files.
James M. Leddy (jm-leddy) wrote : | #10 |
udevadm control --reload-rules works, working on a patch
James M. Leddy (jm-leddy) wrote : | #11 |
The problem is that without --reload-rules, we don't get the new users and groups that were just added. Here is the output in my syslog:
Jul 31 21:21:46 neptune udevd[409]: specified user 'tss' unknown
Jul 31 21:21:46 neptune udevd[409]: specified group 'tss' unknown
Jul 31 21:21:46 neptune TCSD TDDL[12097]: TrouSerS ERROR: Could not find a device to open!
tags: | added: rls-q-incoming |
Changed in trousers (Ubuntu): | |
status: | Confirmed → Triaged |
importance: | Undecided → High |
Changed in trousers (Ubuntu Precise): | |
status: | New → Triaged |
importance: | Undecided → High |
tags: | removed: rls-q-incoming |
description: | updated |
Brian Murray (brian-murray) wrote : | #12 |
For the precise branch to merged and uploaded the bug will need the necessary SRU information filled out in the bug description.
Launchpad Janitor (janitor) wrote : | #13 |
This bug was fixed in the package trousers - 0.3.9-2ubuntu1
---------------
trousers (0.3.9-2ubuntu1) quantal; urgency=low
* debian/
groups. (LP: #959795) Thanks to James M Leddy for the patch.
* debian/
-- Brian Murray <email address hidden> Fri, 17 Aug 2012 14:34:07 -0700
Changed in trousers (Ubuntu Quantal): | |
status: | Triaged → Fix Released |
Jamie Strandboge (jdstrand) wrote : | #14 |
I read the man page for udevadm:
Signal udevd to reload the rules files. The udev daemon detects
changes automatically, this option is usually not needed. Reloading
rules does not apply any changes to already existing devices.
However, James' error is quite telling:
Jul 31 21:21:46 neptune udevd[409]: specified user 'tss' unknown
Jul 31 21:21:46 neptune udevd[409]: specified group 'tss' unknown
The package is both adding the user group and a udev rule. It may a bug in udev that it isn't doing another lookup if it can't find the group in its cache, but adding a "udevadm control --reload-rules" seems easy enough and ok for an SRU.
Jamie Strandboge (jdstrand) wrote : | #15 |
I have uploaded the change to 12.04. Please follow https:/
Changed in trousers (Ubuntu Precise): | |
status: | Triaged → In Progress |
Brian Murray (brian-murray) wrote : | #16 |
Bug 1038302 should really be fixed in Precise too.
James M. Leddy (jm-leddy) wrote : | #17 |
Thanks for the work Jamie, I'm subbing ubuntu-sru as requested.
description: | updated |
Hello James, or anyone else affected,
Accepted trousers into precise-proposed. The package will build now and be available at http://
Please help us by testing this new package. See https:/
If this package fixes the bug for you, please change the bug tag from verification-needed to verification-done. If it does not, change the tag to verification-
Further information regarding the verification process can be found at https:/
Changed in trousers (Ubuntu Precise): | |
status: | In Progress → Fix Committed |
tags: | added: verification-needed |
tags: |
added: verification-done removed: verification-needed |
The verification of this Stable Release Update has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regresssions.
Launchpad Janitor (janitor) wrote : | #20 |
This bug was fixed in the package trousers - 0.3.7-2ubuntu1.1
---------------
trousers (0.3.7-2ubuntu1.1) precise-proposed; urgency=low
* Reload udev rules to reload new users and groups. (LP: #959795)
-- James M Leddy <email address hidden> Tue, 31 Jul 2012 21:34:49 -0400
Changed in trousers (Ubuntu Precise): | |
status: | Fix Committed → Fix Released |
** 2nd Installation Attempt with debug packages selected **
Selecting previously unselected package libopencryptoki -dev. toki-dev_ 2.3.1+dfsg- 3ubuntu2_ amd64.deb) ... dev_1%3a1. 2.3.4.dfsg- 3ubuntu4_ amd64.deb) ... dev_1.0. 0g-1ubuntu1_ amd64.deb) ... doc_1.0. 0g-1ubuntu1_ all.deb) ... dev_0.3. 7-2ubuntu1_ amd64.deb) ... i-dbg_2. 3.1+dfsg- 3ubuntu2_ amd64.deb) ... dbg_0.3. 7-2ubuntu1_ amd64.deb) ... dfsg-3ubuntu2) ... 3.4.dfsg- 3ubuntu4) ...
No apport report written because the error message indicates its a followup error from a previous failure.
Setting up libssl-dev (1.0.0g-1ubuntu1) ... dfsg-3ubuntu2) ...
Errors were encountered while processing:
(Reading database ... 345311 files and directories currently installed.)
Unpacking libopencryptoki-dev (from .../libopencryp
Selecting previously unselected package zlib1g-dev.
Unpacking zlib1g-dev (from .../zlib1g-
Selecting previously unselected package libssl-dev.
Unpacking libssl-dev (from .../libssl-
Selecting previously unselected package libssl-doc.
Unpacking libssl-doc (from .../libssl-
Selecting previously unselected package libtspi-dev.
Unpacking libtspi-dev (from .../libtspi-
Selecting previously unselected package opencryptoki-dbg.
Unpacking opencryptoki-dbg (from .../opencryptok
Selecting previously unselected package trousers-dbg.
Unpacking trousers-dbg (from .../trousers-
Processing triggers for man-db ...
Setting up trousers (0.3.7-2ubuntu1) ...
The system user `tss' already exists. Exiting.
* Starting Trusted Computing daemon tcsd [fail]
invoke-rc.d: initscript trousers, action "start" failed.
dpkg: error processing trousers (--configure):
subprocess installed post-installation script returned error exit status 137
dpkg: dependency problems prevent configuration of tpm-tools:
tpm-tools depends on trousers; however:
Package trousers is not configured yet.
dpkg: error processing tpm-tools (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of tpm-tools-dbg:
tpm-tools-dbg depends on tpm-tools (= 1.3.7-1); however:
Package tpm-tools is not configured yet.
dpkg: error processing tpm-tools-dbg (--configure):
dependency problems - leaving unconfigured
Setting up libopencryptoki-dev (2.3.1+
Setting up zlib1g-dev (1:1.2.
No apport report written because the error message indicates its a followup error from a previous failure.
Setting up libssl-doc (1.0.0g-1ubuntu1) ...
Setting up libtspi-dev (0.3.7-2ubuntu1) ...
Setting up opencryptoki-dbg (2.3.1+
dpkg: dependency problems prevent configuration of trousers-dbg:
trousers-dbg depends on trousers (= 0.3.7-2ubuntu1); however:
Package trousers is not configured yet.
dpkg: error processing trousers-dbg (--configure):
dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
trousers
tpm-tools
tpm-tools-dbg
trousers-dbg
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install. Trying to recover:
Setting up trousers (0.3.7-2ubuntu1) ...
The system use...