recoverable_problem crashed with ValueError in add_proc_info(): invalid process

Bug #1345569 reported by Lukasz Grzesik
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
apport (Ubuntu)
Fix Released
High
Brian Murray

Bug Description

Well, I'm not a system engineer and I haven't knowlegde why that trouble happen here.

ProblemType: Crash
DistroRelease: Ubuntu 14.10
Package: apport 2.14.4-0ubuntu2
Uname: Linux 3.16.0-031600rc4-generic x86_64
ApportVersion: 2.14.4-0ubuntu2
Architecture: amd64
CurrentDesktop: Unity
Date: Sun Jul 20 13:54:54 2014
ExecutablePath: /usr/share/apport/recoverable_problem
InstallationDate: Installed on 2014-07-05 (15 days ago)
InstallationMedia: Ubuntu 14.10 "Utopic Unicorn" - Alpha amd64 (20140520)
InterpreterPath: /usr/bin/python3.4
PackageArchitecture: all
ProcCmdline: /usr/bin/python3 /usr/share/apport/recoverable_problem -p 14110
ProcEnviron:
 PATH=(custom, no user)
 LANGUAGE=pl
 XDG_RUNTIME_DIR=<set>
 LANG=pl_PL.UTF-8
 SHELL=/bin/bash
PythonArgs: ['/usr/share/apport/recoverable_problem', '-p', '14110']
SourcePackage: apport
Title: recoverable_problem crashed with ValueError in add_proc_info(): invalid process
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo

Revision history for this message
Lukasz Grzesik (qnebra) wrote :
tags: removed: need-duplicate-check
Changed in apport (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Sebastien Bacher (seb128) wrote :

that's ranked 4 on the e.u.c weekly reports for 14.10, setting as high

information type: Private → Public
Changed in apport (Ubuntu):
importance: Medium → High
Revision history for this message
Sebastien Bacher (seb128) wrote :

Martin, could you have a look?

Changed in apport (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in apport (Ubuntu):
status: New → Confirmed
Revision history for this message
Brian Murray (brian-murray) wrote :

This is fixed in trunk but hasn't landed in Utopic yet.

 $ bzr log -r2858.1.1 -p
------------------------------------------------------------
revno: 2858.1.1
committer: Evan Dandrea <email address hidden>
branch nick: handle-disappearing-processes
timestamp: Mon 2014-09-22 15:45:54 +0100
message:
  Handle the parent process going away while we're attempting to read from proc.
diff:
=== modified file 'data/recoverable_problem'
--- data/recoverable_problem 2014-05-14 20:58:42 +0000
+++ data/recoverable_problem 2014-09-22 14:45:54 +0000
@@ -37,7 +37,13 @@
         report.pid = os.getppid()

     # Grab PID info right away, as we don't know how long it'll stick around
- report.add_proc_info(report.pid)
+ try:
+ report.add_proc_info(report.pid)
+ except ValueError as e:
+ # The process may have gone away before we could get to it.
+ if e.message == 'invalid process':
+ return
+

     # Get the info on the bug
     items = sys.stdin.read().split('\0')

Changed in apport (Ubuntu):
assignee: Martin Pitt (pitti) → Brian Murray (brian-murray)
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apport - 2.14.7-0ubuntu5

---------------
apport (2.14.7-0ubuntu5) utopic; urgency=medium

  [ Evan Dandrea]
  * data/recoverable_problem: Handle the parent process going away while
    we're attempting to read from proc. (LP: #1345569)
 -- Brian Murray <email address hidden> Tue, 07 Oct 2014 15:26:30 -0700

Changed in apport (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Steve Langasek (vorlon) wrote :
Changed in apport (Ubuntu):
status: Fix Released → Triaged
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apport - 2.14.7-0ubuntu6

---------------
apport (2.14.7-0ubuntu6) utopic; urgency=medium

  * data/recoverable_problem: Fix a Traceback with how the ValueError was
    matched. (LP: #1345569)
 -- Brian Murray <email address hidden> Mon, 13 Oct 2014 10:02:21 -0700

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

Other bug subscribers

Remote bug watches

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