-
-
Notifications
You must be signed in to change notification settings - Fork 177
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
Improve WSL connection #3666
Comments
Ah! |
It is the Windows-defined virtual socket for There are some document for hyper-v socket development. |
AFAICT, Found some helpful code here: Using the Hyper-V sockets between Windows host and Linux guest. |
@firejox where do you get the It might be possible to compile Python 3.12 under MSYS2. |
@totaam It comes from the explanation in Linux kernel code
And HyperV Socket document in Microsoft doc also tell that
|
Kernel 6.4 adds:
|
As of this week, MSYS2 has moved to python 3.12 and everthing should be in place:
|
automatically convert port numbers into Linux VM vsock serviceid uuid strings, and vmid names into their corresponding uuid constants
The commit above adds hyper-v socket parsing to xpra urls, so now we can do:
Which will convert the serviceid to
I would quite like to make it easier to locate the It seems odd that we have to register a new application "in order to use Hyper-V sockets", since the protocol + vmid + serviceid should fully describe the endpoint. It feels like an unnecessary hoop to go through. Information for setting up vsock connections is in #983 |
trying to set it on a socket causes an error
Tested and working as of Will follow up in #4418. |
I have used winsocat and socat to bridge the connection between Windows host and WSL. And this has lower latency than using TCP. And now I want to improve it further.
So the current connection between host and WSL is:
Both
winsocat
andsocat
will allocate buffer to transfer data during the connection.I come up with some ideas about the improvement.
hyper-v socket
andunix socket
connection on windows clientAs what wslg do, the client side will connect via
hyper-v socket
and server will listen onvsock
.This implementation will improve the WSL2 connection. For WSL1, Windows/WSL Interop with AF_UNIX show that xpra client is possible to connect server via
unix socket
. The connection will be:Basically,
winsocat
will listen named pipe connection and then create process for each client. This can be simplified by lettingxpra client
able to create wsl process. Then xpra client can communicate with wsl process via pipe. In order to improve the connection, this wsl process may just pass the stdio fds of the process to server with some protocol. The connection will be:It will be great to have these implementation.
The text was updated successfully, but these errors were encountered: