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

It's possible to create a VXLAN interface via udp2raw ? #526

Open
Wyk72 opened this issue May 18, 2024 · 1 comment
Open

It's possible to create a VXLAN interface via udp2raw ? #526

Wyk72 opened this issue May 18, 2024 · 1 comment

Comments

@Wyk72
Copy link

Wyk72 commented May 18, 2024

I have a VPS that has crippled UDP connectivity (i.e. speed limited), but gets full-band on TCP (nobody seem to know why - not even the ISP).

I'd like to use udp2raw for TCP tunneling, but I don't really need L3, I need L2 connectivity.

I've seen examples of wireguard, but I'd like to know if it's possible to use VXLAN directly instead.

I've tried, but I get the "RTNETLINK answers: File exists" error on setting the VXLAN up.

My setup:

server side:

udp2raw -s -l :8443 -r 127.0.0.1:50001 -k "shared secret" -a --raw-mode faketcp

client side:

udp2raw -c -l 127.0.0.1:50002 -r :8443 -k "shared secret" -a --raw-mode faketcp

The tunnel goes up.

But when I create the vxlan with the usual commends, I do not get any link:

Server side:

ip link add nxc0 type vxlan remote 127.0.0.1 id 12 dstport 50001
ip link set dev nxc0 mtu 1300; ip link set nxc0 up
ip addr add 192.168.33.1/24 dev nxc0

Client side:
ip link add nxc0 type vxlan remote 127.0.0.1 id 12 dstport 50002
ip link set dev nxc0 mtu 1300; ip link set nxc0 up
ip addr add 192.168.33.2/24 dev nxc0

But nothing works ....

Any clues ?

@wangyu-
Copy link
Owner

wangyu- commented Jun 13, 2024

ip link add nxc0 type vxlan remote 127.0.0.1 id 12 dstport 50001

your command is sending to port 127.0.0.1 50001

udp2raw -s -l :8443 -r 127.0.0.1:50001 -k "shared secret" -a --raw-mode faketcp

but you server is not really listening at 127.0.0.1 50001

it's not suprising if it's not working.

You setup doesn't follow the client-server pattern, nor is it NAT friendly.

I am not familiar with vxlan setup, can not point out a working fix.

But... If you client has public ip as well maybe you can try to setup 2 udp2raw tunnels: one per direction. (not guarenteed to work)

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

No branches or pull requests

2 participants