-
Notifications
You must be signed in to change notification settings - Fork 752
mosh: Nothing received from server on UDP port 60001 #1039
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
Comments
Because UDP is connectionless, |
server:
client:
client:
server:
|
Are you familiar with how to use Note that if the mosh-server process doesn't receive any packets from the client within 60 seconds of startup, it will shutdown. This is something important to keep in mind |
I have a similar problem on FreeBSD (13-current = in-development version). Mosh is at 1.3.2. At the end of this report is an assert failure message. Debugging: "Mosh by hand" from client to Server:
NC on client:
NC on destination:
Mosh manually (server side):
Mosh manually (client side):
tcpump on the server ("mosh bastille.leidinger.net"): Anything else I could provide? |
removed firewall and started working again for a while. It is not working with ufw firewall. |
@netchild The tcpdumps show incoming UDP packets, but no attempts at all to send a reply. The most obvious cause of this is that the packets weren't reaching mosh-server. Was it still running? (Remember that mosh-server will exit if it doesn't receive any packets within 60 seconds). Also, that assertion failure looks concerning. If you can reproduce it, can you please open a new github issue? @gitgitgat Can you take the same debugging steps I describe above? It will be helpful to know if the client-to-server messages aren't reaching the server, or if the server-to-client messages aren't reaching the client |
The client side was executed within the 60 seconds window. I remember that the server was telling after the client already died with the assert, that it will exit due to timeout. Is there a way to get some more debug output of the server and keep it in the foreground (I didn't see anything in the man-page)? Would it help to run a FreeBSD ktrace (or dtrace) to trace the syscalls mosh-server is doing? I will open a new issue for the client assert. |
In my case, it seems that ISP filtered my packages. I can mosh to the target server from another server that is within the same data center but not from my laptop. The problem is resolved after re-dial PPPoE. |
Same here, I've opened 22/tcp and 60001/udp on ufw, but I couldn't make it work. It just timeouts. Disabling ufw make it work. |
Fixed my problem by rebooting machines. |
Any ideas how to debug this further? |
On iOS & macOS connecting to Ubuntu server, I get the same thing. Built from GitHub source or from package managers (apt for my Ubuntu server & brew on my Mac). Using wireshark on my Mac shows packets being sent to 60001, but no reply... I added an iptables rule to allow the ports.
IDK what to do from here. Restarting server didn't help. Afaik it was working until I made an image & changed to a new AWS availability zone (I hadn't used |
I believe the problem was on the host side, they blocked all traffic by default. I found a place to turn off the firewall. |
Hi, just a note. The closing of this triggered me testing this again. I have absolutely no change in the firewal rules on the target machine which exhibited this issue (timestamp of pf.conf is not changed, system rebooted prior to testing). The only difference is that I'm running a more recent FreeBSD-current and I may have recompiled mosh with a more recent version of llvm. This works for me now. Bye, |
Firewall was the reason in my case. You don't need to disable it and can allow the port mosh needs by: sudo ufw allow 60001/udp (In your server machine) |
Hi, just wanted to say that in my case, adding a firewall rule solved the problem. Here's how to do that with firewalld. |
For most Ubuntu user this is the best way to go
|
Mosh can use more than just port 60001.
|
My server is running Ubuntu 22.04.1 LTS, and I have enabled ufw allowing 60000:61000/udp including a few others. mosh-server runs with no problem, but on the client machine (macOS Monterey) mosh user@IP return the "nothing received ..." error and exits in a few seconds. |
You can improve your security by limiting the range of open ports. For example: on the Ubuntu server, only expose a small range of ports: sudo ufw allow 60050:60060/udp # opens 10 ports in the given range Then you simply provide the same range to your mosh -p 60050:60060 your_target_host |
Fresh Arch-based linux distro install on VPS, without firewall.
On the client side there is also no firewall.
Mosh installed on server and client, same version:
SSH works.
UDP port opens and works.
On server:
On client:
On server:
Also I tried to use it over yggdrasil overlayed network (with ipv6 ip) to exclude possible firewall on provider side. But I getting same behaviour. IDK what to do.
The text was updated successfully, but these errors were encountered: