0.4.2: fix D-state sample merge (grep -vF '' was filtering everything; use awk dedupe)
This commit is contained in:
parent
ee0f0da59f
commit
6e39a1db66
2 changed files with 4 additions and 5 deletions
|
|
@ -1,6 +1,6 @@
|
|||
# Maintainer: luna <anassaeneroi@pm.me>
|
||||
pkgname=freeze-watcher
|
||||
pkgver=0.4.1
|
||||
pkgver=0.4.2
|
||||
pkgrel=1
|
||||
pkgdesc="Continuously samples system state and snapshots detailed diagnostics when freeze conditions are detected"
|
||||
arch=('any')
|
||||
|
|
|
|||
|
|
@ -254,10 +254,9 @@ capture_snapshot() {
|
|||
fi
|
||||
echo "## D-state processes (with kernel wchan)"
|
||||
# Use the snapshot taken before /proc reads to catch transient blockers.
|
||||
# Combine 3 rapid samples (~100ms apart) and dedupe by pid.
|
||||
echo "$dstate_immediate"
|
||||
echo "$dstate_t1" | grep -vF "$dstate_immediate" 2>/dev/null
|
||||
echo "$dstate_t2" | grep -vF "$dstate_immediate" | grep -vF "$dstate_t1" 2>/dev/null
|
||||
# Combine 3 rapid samples (~100ms apart) and dedupe by pid (column 2).
|
||||
printf '%s\n%s\n%s\n' "$dstate_immediate" "$dstate_t1" "$dstate_t2" \
|
||||
| awk 'NF >= 4 && $1=="D" && !seen[$2]++' | head -30
|
||||
echo
|
||||
if [ "${CAPTURE_KERNEL_STACKS:-1}" = "1" ]; then
|
||||
capture_kernel_stacks
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue