pgo show pvc does not work from non-root location
Describe the bug A clear and concise description of what the bug is. pgo show pvc does not work from non-root location
To Reproduce Steps to reproduce the behavior: pgo show pvc test340-2-xlog --pvc-root / //pgdata// //pgdata//lost+found //pgdata//test340-2-wal //pgdata//test340-2-wal/000000010000000000000002 //pgdata//test340-2-wal/000000010000000000000001 //pgdata//test340-2-wal/000000010000000000000003 Mac2018:quickstart ford$ Mac2018:quickstart ford$ pgo show pvc test340-2-xlog --pvc-root /pgdata/test340-2-wal /find: '/pgdata//pgdata/test340-2-wal': No such file or directory Mac2018:quickstart ford$ pgo show pvc test340-2-xlog --pvc-root /pgdata/test340-2-wal/ /find: '/pgdata//pgdata/test340-2-wal/': No such file or directory Mac2018:quickstart ford$ pgo show pvc test340-2-xlog --pvc-root '/pgdata/test340-2-wal/' /find: '/pgdata//pgdata/test340-2-wal/': No such file or directory
However, this works
pgo show pvc test340-2-xlog --pvc-root 'test340-2-wal/' //pgdata/test340-2-wal/ //pgdata/test340-2-wal/000000010000000000000002 //pgdata/test340-2-wal/000000010000000000000001 //pgdata/test340-2-wal/000000010000000000000003
pgo show pvc --help shows --pvc-root string The PVC directory to list.
Expected behavior A clear and concise description of what you expected to happen.
Screenshots If applicable, add screenshots to help explain your problem.
Please tell us about your environment:
- Operating System:
- Where is this running ( Local, Cloud Provider)
- Storage being used (NFS, Hostpath, Gluster, etc):
- Container Image Tag: 10.6-2.2.0
- PostgreSQL Version:
- Platform (Docker, Kubernetes, OpenShift):
- Platform Version: OCP-3.11
Additional context Add any other context about the problem here.
Remove pgdata and it should work. You don't need quotes.
Correct. Absolute path other than / was not working because of the automatic prefixing of pgdata. It was not clear in the help of pgo show pvc command
I added a new example to the 'pgo show pvc' CLI help, but this will probably be replaced soon with a 'pgo show volume' command that will be probably more useful to people for poking into mounted volumes.