hashmap-kz / hashmap-kz/kubectl-syncpod
"copy file: sftp: \"Failure\" (SSH_FX_FAILURE)" - Error when downloading
- Dominant language
- Go
- Stars
- 16
- Forks
- 0
- Avg merge
- 1m
- Merged PRs (30d)
- 6
Description
**Describe the bug**
Running synpod download of pgdata , the first thing it attempts to download outputs an error
appears to try to download a directory as a file?
level=ERROR msg="file download error" pid=1367 err="copy file: sftp: \"Failure\" (SSH_FX_FAILURE)"
**To Reproduce**
Steps to reproduce the behavior:
kubectl-syncpod download --namespace test1 --pvc db-s6hg-pgdata --mount-path /pgdata --src / --dst ./syncpod-pgdata/pg14 --log-level debug -w 1
(I set to 1 worker so i could try to figure out which file was triggering it)
...
time=2026-06-11T14:33:56.468-04:00 level=DEBUG msg="download file" pid=1367 remote=/pgdata/pg14/pg_wal local=syncpod-pgdata/pg14/pg14/pg_wal
time=2026-06-11T14:33:56.474-04:00 level=ERROR msg="file download error" pid=1367 err="copy file: sftp: \"Failure\" (SSH_FX_FAILURE)"
time=2026-06-11T14:33:56.475-04:00 level=DEBUG msg="download file" pid=1367 remote=/pgdata/pg14/global/pg_control local=syncpod-pgdata/pg14/pg14/global/pg_control
...
in the logs it does later recurse through pg14_wal and download files that are in that directory, but for some reason its first operation is to try to download the directory as a file, and writes errors.
**Expected behavior**
A clear and concise description of what you expected to happen.
No error
**Screenshots**
If applicable, add screenshots to help explain your problem.
**Environment (please complete the following information):**
- OS: Rocky 9, k3s , postgres 14
- k8s version : 1.34.6+k3s1
**Additional context**
Add any other context about the problem here.
Contributor guide
Assessment
This issue has not been assessed yet.