MassMesh Tech

137 Members
Tuesday meetups: https://jitsi.massmesh.net/massmesh40 Servers

Load older messages

23 Sep 2020
@hurricos:tomesh.nethurricosapparently it doesn't even change the MAC (in ar71xx). It uses the U-boot MAC.20:16:50
@hurricos:tomesh.nethurricos * apparently it doesn't even change the MAC (in ar71xx). It uses the U-boot MAC.20:17:03
26 Sep 2020
@Stephen304:matrix.orgStephen304Been picking Neil's brain about ckr performance. It seems the core issue is that the tun code in kernel only allows userspace code to read a single packet at a time, and iiuc the regular packet routing happens in kernel, that results in context switching between userspace ygg and kernel for every packet gatewayed. Possible solutions are: rewriting ygg into the kernel, using a fully userspace networking stack, or updating a patch from 2014, using a patched kernel, and forking wireguard tun to take advantage of the patch and incorporating the patch into our ygg binaries.19:11:48
@Stephen304:matrix.orgStephen304From what I'm reading it seems the tun interface for userspace programs isn't meant to be performant?19:12:42
@Stephen304:matrix.orgStephen304It seems ygg in kernel is a long term goal, so maybe using squid to intercept and speed up web traffic is a decent middle ground. I need tips for getting it configured right though - half of sites won't load through mine19:15:43
@Stephen304:matrix.orgStephen304Seems the issue with squid that has me blocked is that I can't get squid to egress over mullvad instead of the system wan20:40:18
@Stephen304:matrix.orgStephen304 dns_v4_first on 21:15:54
@Stephen304:matrix.orgStephen304I did it21:15:56
@Stephen304:matrix.orgStephen304Turns out squid is pretty dumb, you can't tell it to use a specific interface. You can hardcode the outgoing ip to use, but it will try using that IP on the interface that your default gateway is on, so you also have to add an ip rule to put it on the correct interface it seems.22:54:14
@lurker42o:matrix.orglurkerWeird.. I wonder if that's on purpose.. like a "do just one thing" type of thing23:03:16
@Stephen304:matrix.orgStephen304I'm pretty frustrated by how complex it is to get decent performance out of this setup23:28:49
@cure:matrix.orgcureyeah, same23:28:55
@Stephen304:matrix.orgStephen304If I knew more about kernel dev I would probably chase the kernel patch to tun driver fix, that seems like a much more direct fix23:30:57
@Stephen304:matrix.orgStephen304Because even with squid it's still maxing out cpu between ygg, squid, and openvpn. Just somewhat mitigating the issue23:31:57
@cure:matrix.orgcureare you running squid in socks5 mode?23:32:14
@cure:matrix.orgcureor is this purely web proxying23:32:23
@Stephen304:matrix.orgStephen304Nope, just regular http proxy mode, I looked for that but nothing came up immediately23:32:42
@cure:matrix.orgcureso squid - at best - would speed up http(s) traffic to the wider internet, but, nothing else, correct?23:33:07
@cure:matrix.orgcurehrm. I wonder how bad it would be to patch the kernel. I guess it depends on how well that patch from 2014 still applies.23:34:59
@cure:matrix.orgcureand if it touches a lot.... maybe it just touches the 'tun' module?23:35:23
@Stephen304:matrix.orgStephen304It's not a big patch, so it might not be too bad for someone who is familiar to understand the intent and update it: https://patchwork.ozlabs.org/project/netdev/patch/1417752000-27171-1-git-send-email-agartrell@fb.com/23:35:54
@cure:matrix.orgcurehmm. That's not me.23:37:01
@Stephen304:matrix.orgStephen304The other piece of that is also patching the go wg-tun library to take advantage of it and compiling ygg with the change23:37:58
@cure:matrix.orgcurehmm, right23:38:13
@Stephen304:matrix.orgStephen304That patch discussion also mentions the possibility of developing a more performance oriented interface for tun, I'm not sure if something like that has come along23:39:01
@cure:matrix.orgcurethat was going to be my next question23:39:27
@cure:matrix.orgcureI wonder if it would make any sense for ygg to leverage the wireguard support in the kernel, rather than trying to get ygg into the kernel.23:42:24
@cure:matrix.orgcure(this may well be impossible, I know nothing much about either codebase)23:42:51
27 Sep 2020
@Stephen304:matrix.orgStephen304I'm still struggling to understand exactly how the issue manifests. Openvpn also reads and writes to a tun interface but doesn't seem to exacerbate the problem. Maybe related to where the mtu causes packets to be broken up01:02:18

There are no newer messages yet.

Back to Room List