Bug 254865 - Add support for async file downloading in kio_sftp
Summary: Add support for async file downloading in kio_sftp
Status: RESOLVED FIXED
Alias: None
Product: kio
Classification: Unmaintained
Component: sftp (show other bugs)
Version: SVN
Platform: Unlisted Binaries Linux
: NOR wishlist
Target Milestone: ---
Assignee: Andreas Schneider
URL:
Keywords:
: 218798 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-10-21 12:01 UTC by Andreas Schneider
Modified: 2011-08-18 09:01 UTC (History)
7 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
sftp_async_read patch by Philip Lorenz (8.57 KB, patch)
2010-10-21 12:01 UTC, Andreas Schneider
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Schneider 2010-10-21 12:01:04 UTC
Created attachment 52713 [details]
sftp_async_read patch by Philip Lorenz

Version:           SVN (using Devel) 
OS:                Linux

Use sftp_async_read to speed up get requests

The attached patch uses sftp_async_read to speed up the sftp kioslave.
Preliminary testing showed that the transfer speed locally increased from
~3MByte/s to 18-20 MByte/s.

It should apply cleanly to trunk (r1152597) but was developed against the KDE
4.5 branch. 

Let me know if there are any issues with the patch and I will try to fix them.

Reproducible: Always
Comment 1 Andreas Schneider 2011-01-31 19:29:30 UTC
I'm working on this. I will push it as soon as I did more testing and the kde-runtime git repository is working correctly.
Comment 2 Andreas Schneider 2011-02-01 22:51:57 UTC
Git commit 8eaeb42c787c182b046ce78e5bcdc4069e68c2bb by Andreas Schneider.
Committed on 30/01/11 at 21:15.
Pushed by anschneider into branch 'master'.

kio_sftp: Added async sftp download support.

Thanks to Philip Lorenz.

BUG: 254865

M  +140  -15   kioslave/sftp/kio_sftp.cpp     
M  +56   -1    kioslave/sftp/kio_sftp.h     

http://commits.kde.org/kde-runtime/8eaeb42c787c182b046ce78e5bcdc4069e68c2bb
Comment 3 Ivo Anjo 2011-02-23 16:31:27 UTC
Wow, the performance gains are very nice, and kind-of explain why kio_sftp was slower than other sftp/scp clients.

Can this "fix" be backported for 4.6? Thanks.
Comment 4 ashelley 2011-02-23 18:20:45 UTC
thanks for fixing this.  i'm not too sure how to test for this but is this related at all to this bug? https://bugs.kde.org/show_bug.cgi?id=264557
Comment 5 Philip Lorenz 2011-02-23 18:23:45 UTC
(In reply to comment #4)
> thanks for fixing this.  i'm not too sure how to test for this but is this
> related at all to this bug? https://bugs.kde.org/show_bug.cgi?id=264557

No this is not related to that bug. The patch merely improved transfer speeds for the SFTP kioslave.
Comment 6 BRULE Herman 2011-02-23 18:29:32 UTC
+1 to:
Can this "fix" be backported for 4.6? Thanks.
Comment 7 Andreas Schneider 2011-02-23 22:05:46 UTC
I've asked when I pushed the patch and the answer was no backport as this is a new feature. So this will probably be not in any 4.6 release.

We've reached libssh 0.5 and the plan is to support async sftp_read and sftp_write soon. So I hope we will have libssh 0.6 soon.
Comment 8 Ivo Anjo 2011-02-24 00:17:47 UTC
(In reply to comment #7)
> I've asked when I pushed the patch and the answer was no backport as this is a
> new feature. So this will probably be not in any 4.6 release.
> 
> We've reached libssh 0.5 and the plan is to support async sftp_read and
> sftp_write soon. So I hope we will have libssh 0.6 soon.

Oh, it's a pity. I think this can be seen as a bug fix, as in "kio_sftp has bad performance, this fixes it", and it sucks having to wait 6 months for it, but thanks for trying and for all your hard work.
Comment 9 BRULE Herman 2011-02-24 07:53:10 UTC
And what about folder async listing (because it's vey slow), it's fixed too with this patch?
Comment 10 Andreas Schneider 2011-03-25 09:43:00 UTC
*** Bug 218798 has been marked as a duplicate of this bug. ***
Comment 11 Antonio Orefice 2011-07-21 07:10:19 UTC
Has this patch been applied?
I ask because something weird happened after my last upgrade to kde 4.6.5.
Now my sftp upload ove 1gps link goes at about 1MB/sec.
YES, about 100 times slower the theoretical limit.

Thunar copies the same file to the same server at about 50MB/Sec.

And as 218845 (KIO sftp:/ Slow in KDE 4) is marked as duplicate for 218845 (kio_sftp is much slower than command line scp) which is duplicate of this bug, i reported it here.
Comment 12 Philip Lorenz 2011-07-21 07:20:00 UTC
The patch has been applied and will be part of KDE 4.7.
Comment 13 Antonio Orefice 2011-07-21 07:28:29 UTC
Ok, going to open another bug report, thanks.
Comment 14 FiNeX 2011-08-18 09:01:05 UTC
(In reply to comment #6)
> +1 to:
> Can this "fix" be backported for 4.6? Thanks.

+1 :-)