Skip to content

Instantly share code, notes, and snippets.

@ljjjustin
Created February 27, 2018 03:35
Show Gist options
  • Save ljjjustin/3ee7b6af8fd8ed4a3465f65edf9e34df to your computer and use it in GitHub Desktop.
Save ljjjustin/3ee7b6af8fd8ed4a3465f65edf9e34df to your computer and use it in GitHub Desktop.
#!/bin/bash
if [ $# -ne 1 ]; then
echo "usage: $0 <image name>"
exit
fi
image=$1
rbd -p pool-beishu snap unprotect ${image}@snap
rbd -p pool-beishu snap rm ${image}@snap
rbd -p pool-beishu rm ${image}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment