Commit Graph

14 Commits

Author SHA1 Message Date
John Spurlock
5ecd4beef8 Dump system settings for all users
Change-Id: Ic832b19fe698da1984876b2949c3f26990ae5076
2014-01-29 14:34:24 -05:00
Geremy Condra
e167d889e4 am a3d3e137: Merge "dumpstate: Add SELinux restorecon call."
* commit 'a3d3e137f473a965fefced9670e3b0c6b5f7f791':
  dumpstate: Add SELinux restorecon call.
2013-04-04 23:42:15 -07:00
Robert Craig
957983787d dumpstate: Add SELinux restorecon call.
Set the security context on the directory used
to dump Dalvik and native stack traces.

Change-Id: Iba13783f10e850485ce1a8d4aa5792d55085eb22
Signed-off-by: Robert Craig <rpcraig@tycho.ncsc.mil>
2013-04-04 06:33:10 -04:00
Jeff Sharkey
27f9e6d849 Support broadcast when dumpstate finishes.
Add flag that sends BUGREPORT_FINISHED broadcast when dumpstate
is finished, including the resulting filesystem paths.  Also reduces
directory creation to 0770.

Bug: 7005318
Change-Id: Id4c6b699a56f8acd859b7ab73368500e1a8f3c67
2013-03-13 16:59:27 -07:00
jp abgrall
574d6902b7 am ba8abb51: Merge "Ensure dumpstate children die"
* commit 'ba8abb517d1eddebeda62bf907fa446e3c3b81f6':
  Ensure dumpstate children die
2013-03-11 12:28:06 -07:00
John Michelau
e7b6cf13f9 Ensure dumpstate children die
Use prctl(PR_SET_PDEATHSIG, SIGKILL) in each forked child to ensure
it dies when dumpstate dies.

This is important for two cases:
- dumpstate runs a timer for each child process.  On expiration, it
  sends SIGTERM to kill the process.  Sometimes SIGTERM isn't enough
  to kill a hung process, so the child lives on.
- When dumpstate is killed by the user before completing, outstanding
  children continue to run and generate output.

Change-Id: I96e0dc918c26d56c9fee53611980ba2edd238712
2013-03-11 11:44:15 -05:00
Colin Cross
1493a3974a dumpstate: fix incorrectly zeroed array
Change-Id: I55a916568baf66629b02a6d80fce34b84ffb3a34
2012-11-07 11:25:31 -08:00
Colin Cross
0c22e8b316 dumpstate: dump all threads in show_wchan
for_each_pid only finds processes and not their threads.  Add
for_each_tid and call it for show_wchan so we can see where all
threads are blocked in the kernel.

Change-Id: Iffb59f7c2933cecf51cdd358a36e19932c2f24c7
2012-11-02 23:57:43 -07:00
Elliott Hughes
5f87b31d80 Use a named constant rather than a magic number.
Change-Id: I86e8c91c6f5628df3eec38faf28598cc8cef2ea3
2012-09-17 11:43:40 -07:00
James Dong
1fc4f80fc3 Add stack dump from drmserver process to bugreports
This would be helpful tracking down ANR issues in drmserver

o related-to-bug: 7132419

Change-Id: I7eceaa0c29af26bd0092110be6bddf8f4c063545
2012-09-10 16:10:29 -07:00
Jeff Brown
bf7f49238d Include stack traces for certain native processes in bugreport.
Bug: 6615693
Change-Id: I64c3b3ce0bba62d9c332a795f7d979fb753dc27b
2012-06-08 11:45:00 -07:00
Nick Kralevich
d51820e8de dumpstate: don't follow symlinks when creating /data/anr/traces.txt
Make Android more robust against symlink attacks when /data/anr
is world-writable.

Bug: 5614000
Change-Id: I9a7e4c4ec9aa4300ac30a968db0dcd276f364ab6
2012-04-06 09:53:45 -07:00
Nick Kralevich
c7f1fe2680 Ensure that /data/anr/traces.txt is world-writable
The umask changed for init. We have to force /data/anr to be world
readble and /data/anr/traces.txt to be world writable so dalvik
processes can write to it.

Hopefully this is a short term change while we investigate tightening
up these permissions.

Bug: 6300296
Change-Id: Iacb4c9f1bc69d2ac679697f9cf9a52694f888489
2012-04-06 09:46:10 -07:00
Colin Cross
f45fa6b285 move dumpstate and dumpsys from frameworks/base to frameworks/native
Change-Id: I8a5318022ce5cd3e7c8055f21fe5da74639aa6c0
2012-03-26 12:39:26 -07:00