PT-2322 - pt-mysql-summary does not detect jemalloc.

- Added fix and test case. Fix checks for end of word (space or newline) instead of space.
This commit is contained in:
Sveta Smirnova
2025-08-29 15:09:12 +03:00
parent 05b7efcd27
commit 0d0e7210f7
6 changed files with 938 additions and 3 deletions

View File

@@ -2392,7 +2392,7 @@ report_jemalloc_enabled() {
local variables_file="$2"
local GENERAL_JEMALLOC_STATUS=0
for pid in $(grep '/mysqld ' "$instances_file" | awk '{print $1;}'); do
for pid in $(grep '/mysqld\b' "$instances_file" | awk '{print $1;}'); do
local jemalloc_status="$(get_var "pt-summary-internal-jemalloc_enabled_for_pid_${pid}" "${variables_file}")"
if [ -z $jemalloc_status ]; then
continue