Details
-
Bug
-
Status: Closed
-
Minor - P4
-
Resolution: Done
-
3.2.8, 3.3.9
-
Fully Compatible
-
ALL
-
TIG 2017-03-06
Description
We run dmesg -T > /dev/null 2>&1 instead of $sudo dmesg -T > /dev/null 2>&1 to see if human readable timestamps are supported.
# Print out any Out of Memory killed process messages.
|
- command: shell.exec
|
params:
|
system_log: true
|
working_dir: src # Temporary files created in src will be cleaned up in "pre".
|
script: |
|
${set_sudo}
|
# Use dmesg -T option, if supported, to display timestamps.
|
dmesg=dmesg
|
dmesg -T > /dev/null 2>&1
|
if [ $? -eq 0 ]; then
|
dmesg="dmesg -T"
|
fi
|
$sudo $dmesg 2> /dev/null > dmesg.txt
|
if [ $? -ne 0 ]; then
|
echo "Cannot check for OOM (Out of memory) killed processes on this platform"
|
exit 0
|
fi
|
egrep -i '(Out of memory|OOM[- ]killer|Killed process)' dmesg.txt > oom.txt
|
if [ -s oom.txt ]; then
|
echo "OOM (Out of memory) killed processes detected"
|
cat oom.txt
|
else
|
echo "No OOM (Out of memory) killed processes detected"
|
fi
|
Attachments
Issue Links
- related to
-
SERVER-24211 Addition of oom killed processes to the system logs tab
-
- Closed
-