Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cli slow, browser good same machine #70

Open
lukasa1993 opened this issue Sep 2, 2020 · 5 comments
Open

cli slow, browser good same machine #70

lukasa1993 opened this issue Sep 2, 2020 · 5 comments

Comments

@lukasa1993
Copy link

so from same machine i am trying to send file from cli and browser and cli maxes out on 300kbs and browsers goes to 4mbs recipient and sender is same in both cases any idea?

cli says relay by the way don't know what browser uses…

@saljam
Copy link
Owner

saljam commented Sep 16, 2020

Did I get this correctly:

cli -> cli: slow
browser -> browser: fast

What happens when you send from cli to browser or browser to cli?

Is the sender and recipient on the same network? are they the same machine?

From the sound of it, in your network environment the browser is able to establish a direct connection, but the cli isn't so it ends up using a the relay. Also, is 300kbps consistent with your normal internet connection bandwidth or is it unusually slow? I usually get much faster relay rates.

@lukasa1993
Copy link
Author

i am sending from 1 machine in my local network to second one, and cli always hits relay and browser always goes direct.

my usual internet speed is 100 mbps

@saljam
Copy link
Owner

saljam commented Nov 24, 2020

sorry for the long pause.

so the problem is that browsers can connect directly, but cli hits relay so it gets relay speeds.

it can be quite difficult to troubleshoot why ICE failed to get a direct connection when it could have.

how were you running the cli? does it have direct network access or is it namespaced (e.g. docker or vm?)

@lukasa1993
Copy link
Author

directly in terminal, no vm no docker

@saljam
Copy link
Owner

saljam commented Nov 25, 2020

i just pushed a change to log local and remote candidates when running with the verbose flag. this might help troubleshoot why the two peers can't connect to each other directly.

run ww -verbose pipe on both machines, look for the line that says sent new local candidate: host. e.g. on machine 1:

% ww -verbose pipe
...
2020/11/25 17:25:45 sent new local candidate: host 10.5.128.63:49239
2020/11/25 17:25:45 received new remote candidate: candidate:foundation 1 udp 2130706431 10.5.128.20 49239 typ host
...

and on machine 2:

% ww -verbose pipe foo-bar-baz
...
2020/11/25 17:25:45 received new remote candidate: candidate:foundation 1 udp 2130706431 10.5.128.63 55043 typ host
2020/11/25 17:25:45 sent new local candidate: host 10.5.128.20:49239
...

now verify that the two machines can indeed reach each other on these addresses, e.g. no firewall rules or nats are getting in the way. if they are indeed on the same local network, the host candidate should work.

also, what operating system and version are you using? and what browser?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants