zhanghai / zhanghai/MaterialFiles
Slow SFTP transfer speeds on local 1Gbps network
Nobody has claimed this yet.
- Dominant language
- Kotlin
- Stars
- 9k
- Forks
- 736
- PR merge metrics
- No merged PRs in 30d
Description
I am experiencing very slow file transfer speeds over SFTP, capped at approximately 1 MB/s, despite being on a 1 Gbps local network. For comparison, other protocols like SCP and rsync utilize the full network bandwidth in the same environment.
I have attempted to resolve this by increasing the buffer and window sizes in the SFTP client implementation, but the speed remains bottlenecked.
I am attaching a patch showing my attempts to fix this. Could you please review it or suggest a way to optimize the throughput?
I suspect we should make the transfer implementation asynchronous.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the attached my_changes.patch and trace the SFTP client transfer implementation it changes. Reproduce the approximately 1 MB/s local-network transfer and compare it with SCP or rsync; done means SFTP throughput is no longer capped under the reported conditions, supported by a relevant test or benchmark.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, kotlin
- Domain
- mobile, networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100