Xterm from Linux VM disappears repeatably

Benn Schreiber 6 Reputation points
2021-03-29T23:31:00.117+00:00

Setting: Windows 20H2 with Hyper-V enabled, and Debian 10.6 VM installed. Xming Xserver running on the Windows host. In the Debian guest, fire up an xterm displaying on the Windows-based Xming Xserver. All good!

Some random amount of time later (typically a couple of hours), the xterm disappears. 'pgrep -a xterm' in the Debian guest shows that the xterm is still running.

Some time after that, the xterm exits with "xterm fatal error 110 (connection timed out) or KillClient on X server 192.168.92.8:0" Repeatably.

This first showed up with WSL (see 5339). Someone suggested the following Linux sysctl changes in the guest VM: sysctl -w net.ipv4.tcp_keepalive_intvl=60 net.ipv4.tcp_keepalive_probes=5 net.ipv4.tcp_keepalive_time=300

This fixed the issue for WSL.

Over the weekend i set up two virtually identical Debian 10.6 VMs, one with the default settings, and one with the above modified settings.

The xterm from the VM with the modified settings has kept running. The xterm from the "stock" VM died within 6 hours. I restarted it several times and it repeatably died.

To be clear, the Debian VM continues running, but xterms started from a "stock" Linux VM reliably disappear.

Not sure where the problem lies, but posting here in case anyone else runs into it, and hoping that someone on the Hyper-V team might have some insider perspective on it.

Windows for business | Windows Client for IT Pros | Storage high availability | Virtualization and Hyper-V
{count} vote

1 answer

Sort by: Most helpful
  1. Benn Schreiber 6 Reputation points
    2021-03-31T14:08:06.237+00:00

    Thank you Annie, for looking at this. While this workaround works, it seems clear to me that there is something in Hyper-V that causes this. I've never seen this issue on bare metal or a similar VM running in Virtualbox.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.