]> git.proxmox.com Git - ceph.git/blobdiff - ceph/qa/run-standalone.sh
update sources to 12.2.8
[ceph.git] / ceph / qa / run-standalone.sh
index 3be6121f6ff3d075f920dbbb36c9f1491df05b9c..9321cba6515016696afaf22a4d60583ff09ab459 100755 (executable)
@@ -61,6 +61,15 @@ if [ "$precore" = "$COREPATTERN" ]; then
 else
     sudo sysctl -w ${KERNCORE}=${COREPATTERN}
 fi
+# Clean out any cores in core target directory (currently .)
+if ls $(dirname $(sysctl -n $KERNCORE)) | grep -q '^core\|core$' ; then
+    mkdir found.cores.$$ 2> /dev/null || true
+    for i in $(ls $(dirname $(sysctl -n $KERNCORE)) | grep '^core\|core$'); do
+       mv $i found.cores.$$
+    done
+    echo "Stray cores put in $(pwd)/found.cores.$$"
+fi
+
 ulimit -c unlimited
 for f in $(cd $location ; find . -perm $exec_mode -type f)
 do