crashes with Permission denied: '/proc/5177/exe'

Bug #121121 reported by Juan Pablo Salazar Bertín
2
Affects Status Importance Assigned to Milestone
apport (Ubuntu)
Fix Released
Low
Martin Pitt

Bug Description

Binary package hint: apport

snifer@snifer-laptop:~$ pidof gdm
5177 5176
snifer@snifer-laptop:~$ ubuntu-bug -P 5177
Traceback (most recent call last):
  File "/usr/share/apport/apport-gtk", line 252, in <module>
    app.run_argv()
  File "/var/lib/python-support/python2.5/apport/ui.py", line 230, in run_argv
    self.run_report_bug()
  File "/var/lib/python-support/python2.5/apport/ui.py", line 212, in run_report_bug
    self.report.add_proc_info(self.options.pid)
  File "/var/lib/python-support/python2.5/apport/report.py", line 370, in add_proc_info
    self['ExecutablePath'] = os.readlink('/proc/' + pid + '/exe')
OSError: [Errno 13] Permission denied: '/proc/5177/exe'

ProblemType: Bug
ApportLog:
 apport (pid 5894) Mon Jun 18 22:41:48 2007: called for pid 5892, signal 11
 apport (pid 5894) Mon Jun 18 22:41:49 2007: executable: /usr/bin/gdm-signal (command line "gdm-signal -help")
 modinfo: could not open cdrom: No such device
 modinfo: could not open cdrom: No such device
 apport (pid 5894) Mon Jun 18 22:41:49 2007: wrote report /var/crash/_usr_bin_gdm-signal.1000.crash
Architecture: i386
Date: Tue Jun 19 00:33:31 2007
DistroRelease: Ubuntu 7.10
Package: apport 0.84
PackageArchitecture: all
SourcePackage: apport
Uname: Linux snifer-laptop 2.6.22-6-generic #1 SMP Fri Jun 1 19:24:12 GMT 2007 i686 GNU/Linux

Tags: apport-bug
Revision history for this message
Juan Pablo Salazar Bertín (snifer) wrote :
Revision history for this message
Juan Pablo Salazar Bertín (snifer) wrote :
Revision history for this message
Juan Pablo Salazar Bertín (snifer) wrote :

Also confirmed in Feisty, apport version: 0.76.1.

snifer@snifer-laptop:~$ pidof gdm
5072 5069
snifer@snifer-laptop:~$ ubuntu-bug -P 5072
Traceback (most recent call last):
  File "/usr/share/apport/apport-gtk", line 247, in <module>
    app.run_argv()
  File "/var/lib/python-support/python2.5/apport/ui.py", line 250, in run_argv
    self.run_report_bug()
  File "/var/lib/python-support/python2.5/apport/ui.py", line 232, in run_report_bug
    self.report.add_proc_info(self.options.pid)
  File "/var/lib/python-support/python2.5/apport/report.py", line 329, in add_proc_info
    self['ExecutablePath'] = os.readlink('/proc/' + pid + '/exe')
OSError: [Errno 13] Permission denied: '/proc/5072/exe'

Revision history for this message
Juan Pablo Salazar Bertín (snifer) wrote :

Still present in version 0.85 (gutsy):

snifer@snifer-laptop:~$ pidof gdm
5094 5093
snifer@snifer-laptop:~$ ubuntu-bug -P 5094
Traceback (most recent call last):
  File "/usr/share/apport/apport-gtk", line 252, in <module>
    app.run_argv()
  File "/var/lib/python-support/python2.5/apport/ui.py", line 230, in run_argv
    self.run_report_bug()
  File "/var/lib/python-support/python2.5/apport/ui.py", line 212, in run_report_bug
    self.report.add_proc_info(self.options.pid)
  File "/var/lib/python-support/python2.5/apport/report.py", line 370, in add_proc_info
    self['ExecutablePath'] = os.readlink('/proc/' + pid + '/exe')
OSError: [Errno 13] Permission denied: '/proc/5094/exe'

Revision history for this message
Martin Pitt (pitti) wrote :

Thank you for your bug report. I have all information I need now. I will fix it soon.

Note to self: This happens when using the GUI in bug filing mode on a process that does not run as yourself. It should print a proper error message and suggest sudo/su.

Changed in apport:
assignee: nobody → pitti
status: New → In Progress
importance: Undecided → Low
Revision history for this message
Martin Pitt (pitti) wrote :

apport (0.91) gutsy; urgency=low

  * bin/apport: Remove code that supported the Edgy kernel way of core dump
    passing. Also factorize the CORE_REAL_RLIM evaluation, since it is likely
    to change in the near future.
  * apport/crashdb_impl/launchpad.py, close_duplicate(): Delete some
    attachments, as specified in apport-crash-duplicates spec, and make the
    bug public afterwards.
  * apport/crashdb_impl/launchpad.py, close_duplicate(): If the master bug is
    already duped to yet another bug, mark the bug to that one instead of the
    master.
  * apport/crashdb.py: Split out duplicate_db_last_consolidation() for getting
    the date (or seconds since) the last consolidation, so that we can use it
    externally.
  * apport/crashdb.py: Add duplicate_db_change_master_id() to change the
    master ID of a crash. Add test case to apport/crashdb_impl/memory.py.
  * Add bin/dupdb-admin: Initial version of duplicate db CLI app; can dump the
    db, display consolidation state, and change master bug IDs for now. Ship
    it in apport-retrace.
  * apport/crashdb.py, duplicate_db_last_consolidation(): Fix timedelta
    seconds calculation to actually take the days into account, too.
  * bin/crash-digger: Fix dumping of dup db after consolidation.
  * apport/ui.py:
    - test_run_report_bug_package(): Add test case for calling the UI in bug
      filing mode with an invalid package name.
    - run_report_bug(): Do not crash on invalid package name, generate an
      error message instead. (LP: #123644)
  * apport/fileutils.py, mark_report_seen(): Do not crash if the file has
    already been deleted underneath us. (LP: #122347)
  * apport/ui.py, run_report_bug(): Do not crash if the target process runs as
    a different user. Print a proper error message instead. Add test case
    test_run_report_bug_noperm_pid(). (LP: #121121)
  * apport/fileutils.py, likely_packaged(): Ignore /var/lib/schroot. Add test
    case. (LP: #122859)
  * apport/ui.py, open_url(): Intercept weird race condition for os.close()
    trying to close an already invalidated fd. (LP: #123180)

  Merge the fedora branch, thanks to Will Woods <email address hidden>:

  * Add apport.init.fedora: Fedora specific init script.
  * Add apport.spec: RPM build recipe.
  * Add backends/packaging_rpm.py: Partial implementation of the packaging
    backend for RPM which applies to all RPM-based distros.
  * Add backends/packaging_fedora.py: Concrete packaging backend
    implementation for Fedora.
  * apport/elfcore.py: Classes for parsing general ELF files, and information
    from core dumps.
  * bin/apport: Fall back to reading signal number and PID directly from the
    core file (via elfcore.py) if CORE_SIGNAL and CORE_PID are not defined (i.
    e. when running on a non-Ubuntu kernel).
  * crashdb.conf: Add stanzas for Fedora and a 'debug' database which uses the
    'memory' crashdb implementation.

 -- Martin Pitt <email address hidden> Sat, 14 Jul 2007 15:08:35 +0200

Changed in apport:
status: In Progress → 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.