New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 743125 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Closed: Jul 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 1
Type: Bug



Sign in to add a comment

Logs frequently missing from feedback reports

Project Member Reported by bleung@chromium.org, Jul 14 2017

Issue description

Chrome Version: 60.0.3112.41 beta
Chrome OS Version: 9592.29.0 (Official Build) beta-channel samus
Chrome OS Platform: Samus
<b>Network info: <network, encryption type, router model (if known)></b>

Please specify Cr-* of the system to which this bug/feature applies (add
the label below).

Steps To Reproduce:
(1) Boot system
(2) open file:///var/log/power_manager/powerd.LATEST
(3)

Expected Result:
File exists, displays.

Actual Result:
File does not exist. Missing from feedback report too.

How frequently does this problem reproduce? (Always, sometimes, hard to
reproduce?)
Sometimes

What is the impact to the user, and is there a workaround? If so, what is
it?
Feedback reports for power management issues are missing log file.

Please provide any additional information below. Attach a screen shot or
log if possible.

https://listnr.corp.google.com/report/68336862908

Is this possibly related to log rotation? When this happens, there's only one powerd. log in var/log/power_manager. Maybe the symlink got swept by whatever's sweeping old logs?

This goes away with a reboot, since a new powerd log is created and the symlink is presumably recreated.


 
68336862908-system_logs.zip
1.4 MB Download

Comment 1 by bleung@chromium.org, Jul 14 2017

Owner: derat@chromium.org
Status: Assigned (was: Unconfirmed)

Comment 2 by derat@chromium.org, Jul 14 2017

Components: OS>Systems
Labels: -Pri-2 M-60 Pri-1
Status: Started (was: Assigned)
Summary: Logs frequently missing from feedback reports (was: powerd.LATEST symlink missing in action.)
This affects a bunch of stuff; I have a fix.

I'm going to ask for a merge to M60 since it's trivial and has an impact on debugging.
Project Member

Comment 3 by bugdroid1@chromium.org, Jul 15 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/2735652276307195f6320903b60c75a50cf8d2f4

commit 2735652276307195f6320903b60c75a50cf8d2f4
Author: Daniel Erat <derat@chromium.org>
Date: Sat Jul 15 06:22:04 2017

init: Make chromeos-cleanup-logs skip symlinks.

Make the chromeos-cleanup-logs script only delete regular
files when cleaning up directories.

I think that this solves the longstanding puzzle of why
powerd logs are sometimes missing from feedback reports: the
powerd.LATEST and powerd.PREVIOUS symlinks are only created
at boot, so if the directory gets big and the system has
been running for a while, the symlinks can get deleted.

BUG= chromium:743125 
TEST=manual: verified that the current chromeos-cleanup-logs
     deletes powerd.LATEST after i run e.g.
     "touch -m -d 'last sunday' -h powerd.LATEST" to give it
     an old mtime, but leaves it alone after making this
     change

Change-Id: I44b5b17b8ed331e63f4498b28d76c5778c25f0c3
Reviewed-on: https://chromium-review.googlesource.com/572047
Commit-Ready: Dan Erat <derat@chromium.org>
Tested-by: Dan Erat <derat@chromium.org>
Reviewed-by: Benson Leung <bleung@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/2735652276307195f6320903b60c75a50cf8d2f4/init/chromeos-cleanup-logs

Comment 4 by derat@chromium.org, Jul 15 2017

Labels: Merge-Request-60
Project Member

Comment 5 by sheriffbot@chromium.org, Jul 15 2017

Labels: -Merge-Request-60 Hotlist-Merge-Review Merge-Review-60
This bug requires manual review: We are only 9 days from stable.
Please contact the milestone owner if you have questions.
Owners: amineer@(Android), cmasso@(iOS), josafat@(ChromeOS), bustamante@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 6 by derat@chromium.org, Jul 15 2017

Cc: josa...@chromium.org
Josafat, mind taking a look? The change is trivial and fixes a longstanding issue that's caused a lot of trouble when investigating feedback reports.
Labels: -Merge-Review-60 Merge-Approved-60
Project Member

Comment 8 by bugdroid1@chromium.org, Jul 17 2017

Labels: merge-merged-release-R60-9592.B
The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/1f62fd128c3fde9c38aeb602161a4ddc898cfbe4

commit 1f62fd128c3fde9c38aeb602161a4ddc898cfbe4
Author: Daniel Erat <derat@chromium.org>
Date: Mon Jul 17 19:57:45 2017

init: Make chromeos-cleanup-logs skip symlinks.

Make the chromeos-cleanup-logs script only delete regular
files when cleaning up directories.

I think that this solves the longstanding puzzle of why
powerd logs are sometimes missing from feedback reports: the
powerd.LATEST and powerd.PREVIOUS symlinks are only created
at boot, so if the directory gets big and the system has
been running for a while, the symlinks can get deleted.

BUG= chromium:743125 
TEST=manual: verified that the current chromeos-cleanup-logs
     deletes powerd.LATEST after i run e.g.
     "touch -m -d 'last sunday' -h powerd.LATEST" to give it
     an old mtime, but leaves it alone after making this
     change

Change-Id: I44b5b17b8ed331e63f4498b28d76c5778c25f0c3
Reviewed-on: https://chromium-review.googlesource.com/572047
Commit-Ready: Dan Erat <derat@chromium.org>
Tested-by: Dan Erat <derat@chromium.org>
Reviewed-by: Benson Leung <bleung@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>
(cherry picked from commit 2735652276307195f6320903b60c75a50cf8d2f4)
Reviewed-on: https://chromium-review.googlesource.com/574931
Reviewed-by: Dan Erat <derat@chromium.org>

[modify] https://crrev.com/1f62fd128c3fde9c38aeb602161a4ddc898cfbe4/init/chromeos-cleanup-logs

Comment 9 by derat@chromium.org, Jul 17 2017

Labels: -Hotlist-Merge-Review -Merge-Approved-60 Merge-Merged
Status: Fixed (was: Started)
Thanks!

Comment 10 by dchan@chromium.org, Jan 22 2018

Status: Archived (was: Fixed)

Sign in to add a comment