Skip to content

Commit

Permalink
init-rbdmap: fix error on stop rbdmap
Browse files Browse the repository at this point in the history
Avoid an error on stop service if many /dev/rbd* exist.

Signed-off-by: Laurent Barbe <[email protected]>
  • Loading branch information
ksperis committed Aug 22, 2013
1 parent 17859e1 commit b419924
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/init-rbdmap
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ do_unmap() {
umount $MNT
done
# Unmap all rbd device
if [ -b /dev/rbd[0-9]* ]; then
if ls /dev/rbd[0-9]* >/dev/null 2>&1; then
for DEV in /dev/rbd[0-9]*; do
log_progress_msg $DEV
rbd unmap $DEV
Expand Down

0 comments on commit b419924

Please sign in to comment.