[mosh-users] Mosh Client Exits Unexpectedly

john hood cgull at glup.org
Fri Dec 25 22:39:23 EST 2015


On 12/24/15 8:06 AM, Dan Schwartz wrote:
> Hi mosh community -
>
> I'm trying to get set up with mosh, and I'm having an issue that the 
> mosh-client is exiting unexpectedly (at least I think it is the 
> mosh-client that causes this). I am able to establish a connection 
> between the client and server - the server is receiving packets, and I 
> can even run 'ls' and get back directory contents if I am fast 
> enough...and then the client exits (regardless of what I type, the 
> client seems to exit after between 30s and 1 minute). The server side 
> debug info is pasted below. I see a 'received state -1' which seems 
> suspicious, but I'm not sure what this means or how to debug what's 
> happening.
>
> Any help would be appreciated.
>
> Thanks,
> Dan
>
> Here is the server side debug info:
>
> [24498] Sent [26=>29] id 29, frag 0 ack=24, throwaway=26, len=54, 
> frame rate=31.25, timeout=102, srtt=62.7
> [24532] Sent [26=>30] id 30, frag 0 ack=24, throwaway=26, len=48, 
> frame rate=31.25, timeout=102, srtt=62.7
> [24565] Received state -1 [coming from 24, ack 29]
> [24565] Sent [29=>30] id 31, frag 0 ack=-1, throwaway=29, len=43, 
> frame rate=31.25, timeout=97, srtt=63.3
>
> [mosh-server is exiting.]
Yes, state -1 is a request for shutdown.  So your client is terminating 
in a somewhat-orderly way.  The question is, why is it doing this 
without any action from you or the server?

Things to try:

* Start mosh with the --no-init option.  Sometimes errors are written 
just before the screen is cleared on exit.  This option disables that 
screen clearing.
* If that fails, use the script command to get a typescript of your session.
* If neither of these produce anything useful, please try using your OS 
system-call tracer (truss, ktrace, dtrace) to capture a record of what 
mosh-client is actually doing.

Please open an issue on Github with anything you find, it's the best way 
to handle problems like this.

regards,

   --jh


More information about the mosh-users mailing list