mobile-shell / mobile-shell/mosh
mosh sometimes hangs on connect
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 14.5k
- Forks
- 865
- PR merge metrics
- No merged PRs in 30d
Description
Sometimes, when I try to use mosh to connect to a VM running on my computer, mosh just prints a couple of blank lines and does nothing else:
moth ~ $ mosh h4
(h4 is the VM.) Ctrl-c and ctrl-\ do nothing. No mosh TUI with a blue banner or anything; it's as if I typed echo;echo;cat>/dev/null and somehow disabled ctrl-c and ctrl-\. pgrep shows there are three mosh-server processes on the VM and no mosh-client processes on the host.
The host machine (i.e. mosh client) runs OpenBSD-current amd64. The VM runs OpenBSD 7.3. Both have mosh 1.4.0.
Here is an excerpt from pstree output on the host where I ran mosh h4:
| |-+= 40796 falsifia /usr/X11R6/bin/xterm
| | \-+= 25909 falsifia ksh
| | \-+= 36986 falsifia perl /usr/local/bin/mosh h4
| | \-+- 11626 falsifia ssh -n -tt -S none -o ProxyCommand='/usr/local/bin/mosh' '--family=prefer-inet' --fake-proxy -- %h %p h4 -- mosh-server 'new' '-c' '8' '-s' '-l' 'LANG=en_CA.UTF-8' '-l' 'LC_TIME=C' '-l' 'LC_COLLATE=C'
| | \-+- 36023 falsifia perl /usr/local/bin/mosh --family=prefer-inet --fake-proxy -- h4 22
| | \--- 54912 falsifia perl /usr/local/bin/mosh --family=prefer-inet --fake-proxy -- h4 22
| |--= 15846 falsifia emacs (emacs-28.2)
This bug isn't consistent: usually mosh h4 successfully sets up a remote session on h4.
I don't think I've observed this when connecting to a machine that isn't a VM on the same computer. (I wonder if it's got something to do with network to the VM being super low-latency.)
I saw https://github.com/mobile-shell/mosh/issues/114 which looks quite similar, but it's old and closed, and I'm running mosh 1.4.0 on OpenBSD.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing mosh h4 on the OpenBSD-current host with the OpenBSD 7.3 VM, then inspect the pstree and the mosh-server/mosh-client process state described in the report. Compare successful and hung connections, including the SSH command and low-latency VM network; done means the intermittent connection completes reliably or the failure is diagnosed with a focused regression test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, perl
- Domain
- networking, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100