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

Metered connections #739

Closed
Baughn opened this issue Mar 30, 2016 · 5 comments
Closed

Metered connections #739

Baughn opened this issue Mar 30, 2016 · 5 comments

Comments

@Baughn
Copy link

Baughn commented Mar 30, 2016

Here's a scenario:

I'm using mosh on a laptop, through tethering to a cellphone. I close the laptop, but the cellphone retains its own connection. In this case, what happens to mosh?

If the answer is, "It keeps sending UDP packets to the phone, in hopes of sometime getting a reply", then I'd like to add a feature request for it not to do that. Surprisingly, it seems that mosh can add up to megabytes of traffic in a fairly small number of days.

The client should be able to resume the connection from its side, once it awakens from sleep nigh-eternal.

@eminence
Copy link
Member

What does "close the laptop" mean? If it means that the laptop enters a suspend state, then mosh is not doing anything, as the machine is suspended.

@Baughn
Copy link
Author

Baughn commented Mar 30, 2016

That's true for the mosh instance on the laptop. Not so much the one on the server.

@eminence
Copy link
Member

Ah, good point. Yes, the server will continue to send packages to the last known address of the client, at least for a little while. The exact timeout is specified by SERVER_ASSOCIATION_TIMEOUT here in network.h#L137

(or 40 seconds)

@Baughn
Copy link
Author

Baughn commented Mar 30, 2016

If there's already such a timeout, then I have nothing to worry about. It's been a little difficult to tell.

40 seconds? The only thing I might as for then is documentation. :)

@Baughn Baughn closed this as completed Mar 30, 2016
@keithw
Copy link
Member

keithw commented Mar 30, 2016

You might also be interested in the lowbandwidth branch of mosh (https://github.com/mobile-shell/mosh/tree/lowbandwidth), for extreme low consumption. It is compatible with normal mosh, but if you want the benefits, you'll need to compile the mosh-client and mosh-server from this branch.

glensc added a commit to pld-linux/mosh that referenced this issue Mar 30, 2016
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

3 participants