OpenVPN / openvpn3

OpenVPN 3 is a C++ class library that implements the functionality of an OpenVPN client, and is protocol-compatible with the OpenVPN 2.x branch.
https://openvpn.net
Other
977 stars 386 forks source link

Shared library libprotobuf not available with old refferral #167

Closed emollusion closed 3 years ago

emollusion commented 3 years ago

Hi!

I believe the error occured after a kernel upgrade. It seems like openvpn3 is looking for specific version of files in the shared library of libprotobuf. Specifically looking for /usr/lib/libprotobuf.so.27

Error I received was:

net.openvpn.v3.sessions[7348]: /usr/libexec/openvpn3-linux/openvpn3-service-sessionmgr: error while loading shared libraries:  error while loading shared libraries: libprotobuf.so.27: cannot open shared object file: No such file or directory
dbus-daemon[481]: [system] Activated service 'net.openvpn.v3.sessions' failed: Launch helper exited with unknown return code 127

After the upgrade, the available version of libprotobuf is 28, which is reffered to by a relative links:

/usr/lib/libprotobuf.so -> libprotobuf.so.28.0.3
/usr/lib/libprotobuf.so.28 -> libprotobuf.so.28.0.3

I believe that openvpn3 should be looking for /usr/lib/libprotobuf.so instead of the specific version /usr/lib/libprotobuf.so.27 I solved my problem by pointing a new relative link:

/usr/lib/libprotobuf.so.27 -> libprotobuf.so

So this wont happen again if the kernels are upgraded before openvpn3 is.

(not often I report things, So I hope this is the right place for this issue, otherwise please refer me to the correct place) Thank you!

schwabe commented 3 years ago

What operating system is this on? Also normally a change in the number at the end of a library means a ABI change. While the change might be small enough here that you are lucky that it still works, in general that this is not true. So linking against the ibprotobuf.so.27 instead ibprotobuf.so is from what I understand correct.

I believe the error occured after a kernel upgrade.

Probably another upgrade than just the kernel.

emollusion commented 3 years ago

I am running Manjaro.

So I suppose this is not a problem by design, but an update needed to comply with libprotobuf.so.28 ?

Yeah, might very well have been updates along side the kernel :)

schwabe commented 3 years ago

well basically openvpn3-linux needs to be recompiled. Did you compile openvpn3-linux from sources?

emollusion commented 3 years ago

No, I have not compiled openvpn3.

schwabe commented 3 years ago

We don't distribute openvpn3-linux ourselves for Manjaro. It shoulds however packaged openvpn3-linux for your operating system is to blame for this. Google says Manjaro is based on arch and on the arch package page there is even a comment pointing out that this dependency is missing.

emollusion commented 3 years ago

Ah, ok, so this was maybe not the correct place to point out this "error". Thank you for your time and answer!

(comment for reference: https://aur.archlinux.org/packages/openvpn3/#comment-818127 )