Merge "crash_reporter: Fix paths for kernel panic collection"

This commit is contained in:
Steve Fung 2016-02-03 20:30:58 +00:00 committed by Gerrit Code Review
commit da1a9a277d
4 changed files with 10 additions and 4 deletions

View file

@ -43,7 +43,8 @@
#endif
static const char kCrashCounterHistogram[] = "Logging.CrashCounter";
static const char kKernelCrashDetected[] = "/var/run/kernel-crash-detected";
static const char kKernelCrashDetected[] =
"/data/misc/crash_reporter/run/kernel-crash-detected";
static const char kUncleanShutdownDetected[] =
"/var/run/unclean-shutdown-detected";
static const char kGUIDFileName[] = "/data/misc/crash_reporter/guid";

View file

@ -13,6 +13,10 @@ on post-fs-data
# Remove any previous orphaned locks.
rmdir /data/misc/crash_reporter/lock/crash_sender
# Remove any previous run files.
rm /data/misc/crash_reporter/run/kernel-crash-detected
rmdir /data/misc/crash_reporter/run
# Create crash directories.
# These directories are group-writable by root so that crash_reporter can
# still access them when it switches users.

View file

@ -30,8 +30,8 @@ using base::StringPrintf;
namespace {
const char kDefaultKernelStackSignature[] = "kernel-UnspecifiedStackSignature";
const char kDumpParentPath[] = "/dev";
const char kDumpPath[] = "/dev/pstore";
const char kDumpParentPath[] = "/sys/fs";
const char kDumpPath[] = "/sys/fs/pstore";
const char kDumpFormat[] = "dmesg-ramoops-%zu";
const char kKernelExecName[] = "kernel";
// Maximum number of records to examine in the kDumpPath.

View file

@ -59,7 +59,8 @@ const int kSecondsPerWeek = kSecondsPerDay * kDaysPerWeek;
// Interval between calls to UpdateStats().
const uint32_t kUpdateStatsIntervalMs = 300000;
const char kKernelCrashDetectedFile[] = "/var/run/kernel-crash-detected";
const char kKernelCrashDetectedFile[] =
"/data/misc/crash_reporter/run/kernel-crash-detected";
const char kUncleanShutdownDetectedFile[] =
"/var/run/unclean-shutdown-detected";