Skip to content
Browse files

call sync before lvcreate (calling sync once is sufficient according …

…to man 2 sync)
  • Loading branch information...
1 parent b8147bc commit 2ac9ab9f5fcaf80817c5ab4932eda9a5c68e5231 Kazuho Oku committed Dec 27, 2009
Showing with 1 addition and 1 deletion.
  1. +1 −1 ssh_lvm_dump
View
2 ssh_lvm_dump
@@ -35,7 +35,7 @@ EXIT_CODE=0
# create snapshot
if [ "$EXIT_CODE" -eq 0 ] ; then
echo "creating snapshot..." >&2
- $LVCREATE_PREFIX ssh $SSH_ARGS "lvcreate --snapshot -L \"$SNAPSHOT_SIZE\" -n \"$SS_NAME\" \"$LV_PATH\"" >&2
+ $LVCREATE_PREFIX ssh $SSH_ARGS "sync && lvcreate --snapshot -L \"$SNAPSHOT_SIZE\" -n \"$SS_NAME\" \"$LV_PATH\"" >&2
EXIT_CODE=$?
fi

0 comments on commit 2ac9ab9

Please sign in to comment.
Something went wrong with that request. Please try again.