Fix server kill in coverage task

This commit is contained in:
alesapin 2019-12-11 16:42:08 +03:00
parent 6edc7bd089
commit 7457d911f1
2 changed files with 20 additions and 8 deletions

View File

@ -1,11 +1,17 @@
#!/bin/bash
kill_clickhouse () {
while kill -0 `pgrep -u clickhouse`;
do
kill `pgrep -u clickhouse` 2>/dev/null
for i in {1..10}
do
if ! kill -0 `pgrep -u clickhouse`; then
echo "No clickhouse process"
break
else
echo "Process" `pgrep -u clickhouse` "still alive"
sleep 10
fi
done
}

View File

@ -1,11 +1,17 @@
#!/bin/bash
kill_clickhouse () {
while kill -0 `pgrep -u clickhouse`;
do
kill `pgrep -u clickhouse` 2>/dev/null
for i in {1..10}
do
if ! kill -0 `pgrep -u clickhouse`; then
echo "No clickhouse process"
break
else
echo "Process" `pgrep -u clickhouse` "still alive"
sleep 10
fi
done
}