Skip to content
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

Windwos TCP mode support #58

Open
KoSukeWork opened this issue Dec 6, 2024 · 15 comments
Open

Windwos TCP mode support #58

KoSukeWork opened this issue Dec 6, 2024 · 15 comments
Labels
enhancement New feature or request

Comments

@KoSukeWork
Copy link

request Add support for the S2 parameter on windwos

p2p is not possible in some network environments, and udp is affected by qos

I tried udp2raw, but edge crashed. I think this may be due to the existence of multiple 127.0.0.1 addresses

@hamishcoleman
Copy link
Contributor

Yes, I am planning on trying to support TCP mode on Windows. This will require a bit of testing, so there is no specific timeline for it.

I am also interested in your crashing edge - it really shouldnt crash in any situation, so you could log a bug ticket for that with the steps to reproduce.

@hamishcoleman
Copy link
Contributor

I have just quickly tested the Windows TCP function after some recent code changes and worked for me in my tests - #59 is the PR tracking that improvement

@chenxudong2020
Copy link

ntop/n2n#1189
there is a idea of them

@chenxudong2020
Copy link

I downloaded the latest program for Windows. Where is the default edge.conf location when starting?
When placed in the same directory as the program, the prompt cannot be found and the file location cannot be specified.

@hamishcoleman
Copy link
Contributor

On Windows, the default directory for the conf file is %USERPROFILE%\n3n\

The file location can be specified - but using the unix path characters, eg: "./edge.conf"

@hamishcoleman hamishcoleman added the enhancement New feature or request label Dec 11, 2024
@hamishcoleman
Copy link
Contributor

We believe that windows support for TCP mode is working in the latest builds. Are you able to test this and confirm?

@KoSukeWork
Copy link
Author

Yes, I'm getting ready to test it.
But currently my server is running n2n 3.1.1
Will the n2n 3.1.1 service connect properly after I upgrade n3n?

@hamishcoleman
Copy link
Contributor

The intent is to maintain compatibility with the released n2n versions - I have not specifically tested against n2n 3.1.1 for a while, but the protocol has not been changed.

@KoSukeWork
Copy link
Author

I have tested on windows and n2n 3.1.1 is running fine.
n3n is currently connecting unsuccessfully with connect_tcp=true configuration enabled.
n3n connects successfully with connect_tcp=false

log(recur):
[src/edge_utils.c:363] Error connecting TCP: 0
[n3n-edge.c:947] REGISTER_SUPER_ACK timeout
[src/edge_utils.c:1344] send REGISTER_SUPER to [my ubuntu server]
[n3n-edge.c:921] send REGISTER_SUPER to supernode [my ubuntu server] asking for IP address

@hamishcoleman
Copy link
Contributor

The line numbers in those error messages do not appear to match the version I was expecting. Can you verify exactly which n3n-edge version you tested?

@KoSukeWork
Copy link
Author

The version I'm using is the latest 3.4.4release

Terminal output:
n3n v3.4.4, configured Sat Dec 7 14:10:17 2024 +1100

@hamishcoleman
Copy link
Contributor

Ah! The TCP fixes have not been included in a release yet.

The latest builds are in the artifacts attached to https://github.com/n42n/n3n/actions/runs/12351950825 - if you are able to test that, that would be great

@KoSukeWork
Copy link
Author

I updated the beta version and creating the connection went very smoothly.
However, when I try to access the Minecraft local server, it causes the following log to appear on the remote machine.
even if I subsequently try to use the base RDP application.

02/Jan/2025 20:06:42 [src/edge_utils.c:1323] send REGISTER_SUPER to [MyServerIP]
02/Jan/2025 20:06:42 [src/edge_utils.c:697] registering with multicast group 224.0.0.68:1968
02/Jan/2025 20:06:42 [src/edge_utils.c:1471] send REGISTER to [224.0.0.68:1968]

@KoSukeWork
Copy link
Author

It seems to be a problem with n3n, I tried setting connect_tcp=false but the problem is the same.

n2n everything is fine.

Can I please run it through options so that I can rule out the possibility of a misconfiguration

I Known
-c community name
-l ip:port
-a tap_ip

@hamishcoleman
Copy link
Contributor

If you can run the edge with -vvvv you will generate more logging that might help with debugging.

To help confirm the options, there is a script that can convert the n2n config file format to a n3n config file - use ./scripts/n3n-convert_old_conf $OLDFILENAME from the source code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants