Commit 5b808bce authored by Stephen Roe's avatar Stephen Roe Committed by Commit Bot

Add chrome-bot ps output to system statistics log.

Currently the system statistics contain top output which truncates
executable names.  Adding ps output will give full executable names
and invocation arguments.

Bug: 1100402
Change-Id: I5357fea58e0dbf04dacdc6b6caabf5b2d79ea856
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2335649Reviewed-by: default avatarKevin Marshall <kmarshall@chromium.org>
Commit-Queue: Stephen Roe <steveroe@google.com>
Cr-Commit-Position: refs/heads/master@{#794628}
parent 1b116856
...@@ -129,8 +129,13 @@ class EmuTarget(target.Target): ...@@ -129,8 +129,13 @@ class EmuTarget(target.Target):
# TODO(crbug.com/1100402): Delete when no longer needed for debug info. # TODO(crbug.com/1100402): Delete when no longer needed for debug info.
def _LogSystemStatistics(log_file_name): def _LogSystemStatistics(log_file_name):
statistics_log = runner_logs.FileStreamFor(log_file_name)
# Log the cpu load and process information. # Log the cpu load and process information.
subprocess.call(['top', '-b', '-n', '1'], subprocess.call(['top', '-b', '-n', '1'],
stdin=open(os.devnull), stdin=open(os.devnull),
stdout=runner_logs.FileStreamFor(log_file_name), stdout=statistics_log,
stderr=subprocess.STDOUT)
subprocess.call(['ps', '-ax'],
stdin=open(os.devnull),
stdout=statistics_log,
stderr=subprocess.STDOUT) stderr=subprocess.STDOUT)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment