From 04b1f1589acd358beca408ab16be6d17456e8200 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20W=C3=A4ckerlin?= Date: Wed, 23 Jan 2019 13:02:11 +0100 Subject: [PATCH] replace rremove with rm, because rremove is not reliable --- lizardfs/lizardfs-snapshots.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lizardfs/lizardfs-snapshots.sh b/lizardfs/lizardfs-snapshots.sh index 6f94ee1..32821be 100755 --- a/lizardfs/lizardfs-snapshots.sh +++ b/lizardfs/lizardfs-snapshots.sh @@ -111,7 +111,8 @@ for src in "${SOURCES[@]}"; do echo " " "lizardfs makesnapshot -lf '${src}' '${DESTINATION}/${target}${date}'" if test -n "$del"; then for f in $(ls -d1 "${DESTINATION}/${target}"-* | sort -r | tail -n +"$del"); do - echo " " "lizardfs rremove -l '$f'" + #echo " " "lizardfs rremove -l '$f'" + echo " " "rm -rf --one-filesystem '$f'" done fi else @@ -119,7 +120,8 @@ for src in "${SOURCES[@]}"; do lizardfs makesnapshot -lf "${src}" "${DESTINATION}/${target}${date}" if test -n "$del"; then for f in $(ls -d1 "${DESTINATION}/${target}"-* | sort -r | tail -n +"$del"); do - lizardfs rremove -l "$f" + #lizardfs rremove -l "$f" + test -d "$f" && rm -rf --one-filesystem "$f" done fi fi