ntop / n2n

Peer-to-peer VPN
GNU General Public License v3.0
6.28k stars 943 forks source link

All edge traffic passes through the supernode #58

Closed liziwl closed 5 years ago

liziwl commented 5 years ago

I built a supernode on Ubuntu and 2 edges on 2 Windows PC. I connect the other Windows through Microsoft RDP and play video on it.

I view large traffic on the supernode. So I want to know where I might be mistaken.

How to config real p2p connection that without passing through the supernode?

lucktu commented 5 years ago

I recommend n2n here, It's easier to establish direct connection (p2p)。 https://github.com/meyerd/n2n

liziwl commented 5 years ago

I thought they were the same. Because they are in the same name.

lucktu commented 5 years ago

Not the same. and it's incompatible.

emanuele-f commented 5 years ago

Hi, n2n development has moved here, if you have any improvement or suggestion please create a pull request or discuss it here. n2n works p2p wherever the environment allows it. It depends on the type of firewalls between the two peers. It tries to open ports via UDP hole punching techniques by this does not work with some types of NAT. Please note that n2n could split a single flow asimmetrically making A->B packets p2p while B->A packets pass through the supernode. I've opened this issue https://github.com/ntop/n2n/issues/27 as I think it is a good compromise to allow p2p communication where we are in control of the NAT settings

lucktu commented 5 years ago

Or, it is recommended to add a parameter that allows the p2p application to work independently of the supernode in supernode.

lucktu commented 5 years ago

In fact, meyerd's n2n has a much higher direct link success rate than the official n2n.

emanuele-f commented 5 years ago

How do you measure this? I thought meyerd code was integrated into this n2n version

emanuele-f commented 5 years ago

Closing as the relevant information has been provided. Let's continue on #27 for a better direct communication support.