Created
May 3, 2019 14:20
-
-
Save alanbchristie/ef98c79d50512d742d2ac14b9c2342a1 to your computer and use it in GitHub Desktop.
List OKD PV volumes (paths)
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
#!/bin/bash | |
# | |
# Use the oc-command-set to get persistent volume paths. | |
# Useful in correlating PV to underlying gluster volume. | |
# | |
# Alan Christie | |
# May 2019 | |
for pvc in $(oc get pv | grep pvc- | cut -f1 -d" ") | |
do | |
oc describe pv/$pvc | grep "Path:" | tr -s ' ' | cut -f3 -d" " | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment