Mosh: the mobile shell
55 points by op
55 points by op
I could not work without it from flimsy german train internet.
Thanks, as somebody who is forced to take the train through Brandenburg regularly, I’ll give this a go.
I am also a regular mosh user! Even on a reliable internet connection, I like mosh because it survives suspend-to-RAM (without reconnecting / killing your session) :)
I used to use this thing like a thousand years ago. Are they still developing? Or suddenly? I’m so old that old things are new again?
They haven’t had a release since 2022 and things are getting a little stale. Still useful for any place where you’d use a raw SSH connection, or even just for whimsical things like pubnixes.
What’s stale about it? Seems like it still works great.
Of course, it still works. Not stale in that sense. Bugs however will remain unfixed, and the build process will be harder as time goes on due to dependency bitrot. Just today I had to patch it so it built correctly with protobuf.
(Obv this is only relevant if you’re a package maintainer)
Ah, well, if an otherwise-stable program has dependencies on libraries with bad backwards compatibility, that’s a huge liability. Good to know.
Is there a simpler alternative that doesn’t require much maintenance?
I don’t mind software that doesn’t need updates to continue working, but if it takes a month of part time work to get it working again that sucks.
What?
Mosh requires zero configuration, it just works. And it works today just as well as a decade ago.
Mosh requires zero configuration, it just works.
In my experience it requires punching some holes in firewalls, and this isn’t always an option on some networks. So while the client/server require no direct configuration, some network config is required for this to work 🤷♂️
From an implementation point of view.
It’s a small C program with a single dependency on protocol buffers. I expect it to compile just fine in 30 years.
Take a look at other parts of the thread where a packager talks about having to patch it due to problems building with a recent protobuf version.
Packagers don’t “have” to do anything. They could’ve continued to use a working version of protobufs.
I also don’t think this is what LenFalken is referring to…
Excellent, then I suspect the concerns about “not updated in 2 years” are unwarranted. Thank you for clarifying!
Isn’t it C++, and doesn’t it also depend on libncurses5 (which seems to be not likely to be in the next version of debian), libutempter which had a release 6 months ago, zlib, openssl?
I’m not aware of a simpler version. ET (Eternal Terminal) is the more complicated version. Which is why I use mosh instead. I’ve been using mosh for years, a decade maybe? It’s been amazingly stable. I used to work exclusively from cell service and without mosh, it would have been a nightmare.
I thought the same thing!
I used it back in the day when mobile internet was slow and spotty, it made my “run everything on a VPS” workflow at the time feasible.
Still has some unusual behavior when paired with tmux (misaligned characters, random UTF-8 characters, etc.).
It was good when it was new, but the resistance to adding things like SSH key forwarding minimize its overall usefulness for me.
Still has some unusual behavior when paired with tmux (misaligned characters, random UTF-8 characters, etc.).
Interesting; in my experience it tends to mangle some terminal programs when not paired with tmux. Thankfully, I use tmux everywhere I can, so I don’t get affected too much.
the resistance to adding things like SSH key forwarding
This is real, though. I ended up carrying patches for the agent and clipboard forwarding everywhere with the same diligence I set up login-to-tmux in every $HOME. Would be much easier if those features were built-in.
wezterm connect functionality is a nice update over stock mosh. Basically, features of screen, mosh and a fast terminal emulator in one convenient package.
For those who’re not familiar but want to get impressed: shell into a developer container somewhere in the cloud and switch your laptop internet connection to the cell phone. The shell is still there!
You still should be able to solve it with a clever enough VPN, but nothing is more magical than a user land tool that does it all and more. I really like mosh :)
see also https://eternalterminal.dev/
ET was great, but it has just stopped working for me, and I have no idea why. I’ve done some debugging but the developer isn’t active any more, and at a total loss as to how to proceed.
This is neat, didn’t know it.
“ Unfortunately, iTerm2 for OS/X and an unsupported fork of the Terminator terminal are the only terminals that support Tmux control center.”
Little known fact, ChromeOS terminal also supports tmux -CC
Terminator Developer here.
Where is this fork? I’ve been trying to get tmux integration into Terminator for years now, but I don’t use tmux, and I don’t understand the integration. I’ve had other people write patches, get about halfway done, and then bail. More than once. I’d like to see a usable integration if someone’s gone to the bother of writing one.
hey, great to see terminator is still actively developed! i’ve been happily using it on all my machines for the last 20 or so years (at least!).
Been using mosh for years. If you work from multiple locations or SSH over a VPN, it makes life much better by keeping your sessions alive when you re-establish your VPN connection or change locations. Every session starts with mosh and gets a tmux session.
I use it occasionally from Termux on Android. ssh is still my primary because I need port forwarding (which Mosh doesn’t support) but it’s great to have Mosh handy for those marginal reception situations.
Anyway to use this on iOS anymore w/o building/sideloading yourself (assuming that is even possible?)
Not free but Blink works amazingly well for it: https://blink.sh
Blink is worth the money, but you can also build it yourself from the source code – it was quite easy the last time I tried.