We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fe4e916 commit 25f3ef9Copy full SHA for 25f3ef9
1 file changed
end-to-end-test.sh
@@ -316,7 +316,9 @@ EOF
316
if [ ${keep} -eq 0 ]
317
then
318
pid=$(cat "${tmpdir}/node_exporter.pid")
319
- kill "$pid"
+ # Disown to prevent shell from printing "Terminated" message
320
+ disown "$pid" 2>/dev/null || true
321
+ kill "$pid" 2>/dev/null || true
322
# Wait for the process to exit gracefully to allow socket cleanup
323
for i in {1..100}; do
324
if ! kill -0 "$pid" 2>/dev/null; then
@@ -327,9 +329,6 @@ EOF
327
329
# Force kill if it's still running
328
330
kill -9 "$pid" 2>/dev/null || true
331
- # This silences the "Killed" message
- set +e
332
- wait "$pid" > /dev/null 2>&1
333
rc=0
334
if [ ${socket} -ne 0 ]; then
335
if ls -l "${unix_socket}" &> /dev/null; then
0 commit comments