OpenVPN server not starting



  • my openvpn service gives this error in the log. these log entries are about the openvpn server.

    Mar 2 00:23:54 openvpn[70892]: OpenVPN 2.3.8 amd64-portbld-freebsd10.1 [SSL (OpenSSL)] [LZO] [MH] [IPv6] built on Aug 21 2015
    Mar 2 00:23:54 openvpn[70892]: library versions: OpenSSL 1.0.1l-freebsd 15 Jan 2015, LZO 2.09
    Mar 2 00:23:54 openvpn[70961]: NOTE: the current –script-security setting may allow this configuration to call user-defined scripts
    Mar 2 00:23:54 openvpn[70961]: Control Channel Authentication: using '/var/etc/openvpn/server3.tls-auth' as a OpenVPN static key file
    Mar 2 00:23:54 openvpn[70961]: TCP/UDP: Socket bind failed on local address [AF_INET]...:1194: Address already in use
    Mar 2 00:23:54 openvpn[70961]: Exiting due to fatal error

    the error occurred when i assigned the openvpn server to an interface. when i changed everything back the error still remains. can somebody help me with this?

    Thanks!



  • The first thing that jumps out at me is:

    TCP/UDP: Socket bind failed on local address [AF_INET]...:1194: Address already in use

    Any chance you have another OpenVPN server instance running?

    If you haven't explicitly created a new server instance, it's entirely possible you have some pieces left running during your changes.
    At the "Diagnostics->Execute Command" try a "ps auxwww | grep vpn" to see what's left running.

    You can track them down and kill them from the console or just force a reboot to make sure nothing else is there.



  • Okay big thanks! that solved my problem. hope it doesnt happen again! :D



  • I've run into the situation a few times with OpenVPN, mainly when I'm "fiddling" with my configurations.

    I think the scenario occurs when a client is in the middle of establishing a link and I try to pull the server side down.
    The server instance tries to stay alive and complete the link so the restart ends up failing (sometimes "silently").
    Normally a manual command line kill of the session solves the issue.  Worst case you're stuck with a reboot (very rare).

    Once you stop playing with the config files on both ends (especially mid-connect), I've found OpenVPN to be very stable.