Heads up, I found on my OpenWrt router (Netgear R7800), running openvpn servers for my mobile devices to connect back home while out and about, the previous compression setting in /etc/config/openvpn did not work and caused a service startup loop.
This works in 19.07, but not in 21.02.0-rc3:
The compression no-no is also mentioned in the OpenVPN manual for 2.5. And the function will be removed in 2.6.
19.07 have OpenVPN 2.4 and 21.02 have OpenVPN 2.5.
But 21.02 was released very late so we didn’t get 2.5 when it got out.
Generally speaking, is there a place that an OpenWrt end-user can monitor for incompatible package changes like this? A blog or announcement list?
And then what exactly is option comp_lzo 1 doing for me now? Is it ignored, or is somehow the package I got installed for my OpenVPN server on my OpenWrt router actually implementing this option?
(I likely got this package built from source, I was attempting to use the imagebuilder and it had incompatibilities with the packages since 21.02.0-rc3 packages are still a moving target. But I didn't set any specific options, other than CONFIG_PACKAGE_openvpn-openssl=m)
This is what you should do for most other opensource software used in OpenWrt, since in most cases OpenWrt is just repackaging their stuff with little changes, and does not have enough manpower to set up a full system to send you updates on all things that changed or didn't change.
that is not a valid config, where did you read that "comp_lzo 1" does anything? I assume it is ignored by the uci config system and does not generate any change in the actual openwrt config file.
If you actually give it a valid config like option compress 'lzo' OpenVPN tries to do it and then blows up because that function was disabled.
The compression support for LZO has been removed from the binary in 21.02 and master snapshot in the commit linked above. Even if you build from source it is still removed (the build system will compile a new package following the same configuration, where that functionality is removed).
Found it via web search...but now that I think about it, that seems to be an old name for the option before option compress 'lzo'? I took out option comp_lzo 1 and the config fails to work with my iOS devices, blurting this in the openvpn log file:
2021-07-09 20:47:04 JTKphone-openvpn/22.214.171.124:10961 IP packet with unknown IP version=15 seen
So the option seems to be doing something?
If I set it to option comp_lzo '0', the VPN connection also works, so perhaps that is the best solution for now: that seems likely to disable that compression and saves me from having to regenerate the openvpn client's configuration immediately.
Is it possible the openvpn package for OpenWrt retained the server code for LZO compression, and only disabled the client code?
It seems that with that option (regardless of 0 or 1 at the end) the server is explicitly telling the client to not use compression (overriding its config?), while without it it just assumes things and the client freaks out when it expects compressed packets and does not get them.
It's hard to tell what is going on without seeing the actual openvpn config file of the server and of the client. That thing is the uci config of OpenWrt but it's used to generate a temporary OpenVPN config file used by the actual service to run.
Even for the client -> server direction? The referenced openvpn man page suggested the push option to the client, from which I infer that the client and server could choose their own options for each direction?
It gets generated as /var/etc/openvpn-<servername>.conf. Notice that comp_lzo gets converted to comp-lzo by something along the way. (If I use option comp-lzo 'no' in /etc/config/openvpn, then the generated config file does not have any comp-lzo or comp_lzo option in it.)
root@LEDE:~# cat /var/etc/openvpn-vpnserver.conf
keepalive 10 120
push "dhcp-option DNS 172.30.11.1"
push "redirect-gateway def1"
push "route 172.30.11.0 255.255.255.0"
push "route-gateway dhcp"
push "topology subnet"
push "comp-lzo no"
server 172.30.11.0 255.255.255.0
tls-auth /etc/openvpn/tls-auth.key 0
An as-yet-unanswered question: why does omitting option comp_lzo <anything> from the server's /etc/config/openvpn cause the client (iOS) and server (OpenWrt) fail to communicate, with the server blurting complaints about IP packet with unknown IP version=15 seen, if there is no LZO support in the OpenWrt openvpn server package?
Anyway, IP packet with unknown IP version=15 seen happens when you have different compression settings in server and client, regardless of LZO being available or not, or you enabling it or disabling it.
Or if you have Ata-over-Ethernet kernel modules enabled (not your case since it's not installed by default in OpenWrt and it's quite frankly a VERY niche thing).
So yeah, in your case it's not a LZO thing but a "config files are not the same on client and on server" thing. And everything blew up when "option compress 'lzo'" could not be used anymore so the config file did not contain "comp-lzo something" and therefore was not "similar enough to the client compression settings".
Adding the option comp_lzo anything lets you add custom config options for openvpn and therefore you could add "comp-lzo something" again and the configs were similar enough to not trigger that error.