Last active
February 24, 2020 04:53
-
-
Save schnell18/512f81d56c201ad186b4c5bc0f65d3ea to your computer and use it in GitHub Desktop.
remove virtualbox disk file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| GUEST="slave-1" | |
| vboxmanage list hdds \ | |
| | sed -e '/./{H;$!d;}' -e 'x;/'"$GUEST"'/!d;' \ | |
| | grep UUID | egrep -v Parent | awk '{print $2}' \ | |
| | xargs -I{} vboxmanage closemedium disk {} --delete | |
| # vboxmanage list hdds \ | |
| # | sed -e '/./{H;$!d;}' -e 'x;/'"$GUEST"'/!d;' \ | |
| # | grep UUID | egrep -v Parent | awk '{print $2}' \ | |
| # | xargs -I{} echo vboxmanage closemedium disk {} --delete | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment