Kodi Community Forum

Full Version: Slow SSH connection
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3

I finally got SSH to work with Kodi, but the speed is alot slower than I expected it to be.
I can't even stream a SD video, it starts chopping after a couple of minutes.
It's all done local for now, because this setup is to prepare for when i get a decent upload connection so i can use it even when i'm not home.

When i try a simple file transfer in filezilla, i get speeds 16-16,5 MiB/s

I'm pretty sure that's not the case when i'm using kodi.
This is a screenshot of how things are when things are playing fine in the beginning, after 1 minute of caching.

This is when things start going really bad, chopping alot, and no sound.

The SSH server is not maxing out it's CPU, so as far as I can tell, it's Kodi that has a problem.
Any particular reason to use ssh?
SSH is an encrypted connection which has to be decrypted by the CPU. That's the reason why the CPU gets the high load. Filetransfers via SSH are done by SCP IIRC. SCP (Secure Copy) is encrypted, too. So transferring files and playing them back will get you the high CPU load. Not an issue at all...just normal.

And yes, the question nickr asked, is right. Any reason why to use SSH for that?
Bug is here: http://trac.kodi.tv/ticket/14038 sftp was never implemented correctly in kodi. The code basically limits the transfer to around 400KBps, which is unsuitable for HD content.
@David1977, i said i do not see any high CPU usage Wink

And my i chose SSH because i want to be able to access my library wherever i am Smile

I know i could use, FTP, just forwarding some ports, or make an VPN server, but FTP and opening ports is not encrypted, and VPN requires a VPN klient, or a firewall that is connected.

As far as i could tell, SSH would give me encrypted traffic, and the only configuration needed was in kodi.

If there isn't a way to get SSH to work faster, i think ill go with VPN.
I am in the same boat for the same reasons. The option for sFTP was there, and it was driving me crazy as to why it wasnt working. At least we know now. They should disable the sFTP option altogether in my opinion until / if it works.

I have setup an nginx container with https and basic authentication to use for the streaming server. Hopefully that will work and so I dont have to setup a VPN for this.
Is it possible to share files using a server using https instead?
The last report in the bug declared that the implementation of libcurl in kodi is 'correct' and that protocols supported by that library would work properly. http(s) and webdav(s) were suggested alternatives to SFTP. I setup an https server with authentication last night, but haven't put it through the paces with streaming / seeking with kodi yet.
@tekno442 would you report back if that is working better than SSH?
Just tried the https server with authentication. Works great. Fully saturates my network downlink while being encrypted (using 2% CPU on AMD A8) for filling the buffer. Seeking is super fast.
Sounds like my next step.

Think ill just use IIS, since i'm using Windows server anyway.

Is HTTPS as fast as using SMB?
I would say it's slightly faster than a SMB server on local LAN

In the bug report you can see SMB and NFS are also affected by the same faulty implementation that SFTP is. If you had setup a VPN to tunnel SMB it would have done the same thing as SFTP -- or even without the VPN
Wow really, i think SMB is fast on LAN, i never notice any sluggish behavior.

Doesn't https require a SSL certificate?
It just seems faster to resume or seek to a spot than SMB. SMB has more overhead than https. I dunno its really pretty close.

Yes, https requires an SSL cert. I'm unsure how IIS does this, I generated a self signed cert for nginx.
If i have to buy a certificate, ill do it, a simple SSL certificate isn't that expensive as i recall.

I'll try to get HTTPS to work, and see if that gives me the result i'm hoping for Smile
Pages: 1 2 3