It may be the case that stop.sh can't stop a process for reasons
unrelated to vstart.sh. Because apache runs independantly, for
instance. Instead of trying forever, try twice in a raw ( should be
enough 99% of the case ) and try three more times, sleeping one second
between each try should be more than enough.
Signed-off-by: Loic Dachary <loic@dachary.org>
if [ $stop_all -eq 1 ]; then
for p in ceph-mon ceph-mds ceph-osd radosgw lt-radosgw apache2 ; do
- while pkill $p ; do : ; done
+ for try in 0 1 1 1 1 ; do
+ if ! pkill $p ; then
+ break
+ fi
+ sleep $try
+ done
done
pkill -f valgrind.bin.\*ceph-mon
$SUDO pkill -f valgrind.bin.\*ceph-osd