Ik heb het automatisch starten van OpenVPN werkend gekregen onder mijn eigen account (geen Admin, maar wel met administrator rechten). De truc zit (c.q. zat bij mij) in het installeren met administrator rechten en tevens de eerste keer handmatig opstarten met ook administrator rechten. Anders krijg je een foutmelding. Vervolgens gaat het daarna goed met je eigen account. Ik heb geen aanpassingen gedaan in de settings van enig bestand of zo. Wat wel heel nauw luistert zijn de items in je config file. Soms zorgde één enkele instelling er voor dat het verbinden al niet meer lukte. Kortom: veel "trial and error".
De reden dat ik recent toch weer teruggegaan ben naar de cliënt van PrivateInternetAccess is het lastige reconnecten van OpenVPN na verlies van de verbinding. Dan moest ik eerst de TAP adapter uitschakelen en de OpenVPN GUI afsluiten en dan alles weer activeren en opstarten. Ook heb ik nooit een goeie methode gevonden om te controleren of het verkeer dan ook daadwerkelijk over de VPN ging. Dan kreeg ik wel een 'connected' melding, maar als ik dan m'n IP adres controleerde via whatismyip.com dan had ik toch een IP van m'n eigen provider. Met de PIA client gaat het eigenlijk altijd goed.
Dit is mijn config file:
##############################################
# Client-side OpenVPN 2.0 config file #
# for connecting to Private Internet Access. #
# #
# This configuration can be used by multiple #
# clients, however each client should have #
# its own cert and key files. #
# #
# On Windows, you might want to rename this #
# file so it has a .ovpn extension #
##############################################
# Specify that we are a client and that we
# will be pulling certain config file directives
# from the server.
client
# Use the same setting as you are using on
# the server.
# On most systems, the VPN will not function
# unless you partially or fully disable
# the firewall for the TUN/TAP interface.
dev tun
# Are we connecting to a TCP or
# UDP server? Use the same setting as
# on the server.
proto udp
# Other commands not further explained yet.
route-method exe
route-delay 2
# The hostname/IP and port of the server.
# You can have multiple remote entries
# to load balance between the servers.
remote nl.privateinternetaccess.com 1194
remote germany.privateinternetaccess.com 1194
remote uk-london.privateinternetaccess.com 1194
# Choose a random host from the remote
# list for load-balancing. Otherwise
# try hosts in the order specified.
;remote-random
# Keep trying indefinitely to resolve the
# host name of the OpenVPN server. Very useful
# on machines which are not permanently connected
# to the internet such as laptops.
;resolv-retry infinite
# If you would also like DNS resolution failures to
# cause the OpenVPN client to move to the next
# server in the list, add the following:
resolv-retry infinite
# Most clients don't need to bind to
# a specific local port number.
nobind
# Try to preserve some state across restarts.
persist-key
persist-tun
# Wireless networks often produce a lot
# of duplicate packets. Set this flag
# to silence duplicate packet warnings.
;mute-replay-warnings
# SSL/TLS root certificate (ca), certificate
# (cert), and private key (key). Each client
# and the server must have their own cert and
# key file. The server and all clients will
# use the same ca file.
ca ca.crt
# Other commands not further explained yet.
tls-client
remote-cert-tls server
reneg-sec 0
keepalive 10 60
inactive 3600
#This it the IP address scheme and subnet of your normal network your server is on.
#Your router would usually be 192.168.188.1
# Command to check if#: C:\>route print -4
route 192.168.188.0 255.255.255.0 10.174.1.5
# For extra security beyond that provided
# by SSL/TLS, create an "HMAC firewall"
# to help block DoS attacks and UDP port flooding.
# NOT supported by PIA
# Select a cryptographic cipher.
# This config item must be copied to
# the client config file as well.
;cipher BF-CBC # Blowfish (default)
;cipher AES-128-CBC # AES
;cipher DES-EDE3-CBC # Triple-DES
# Other commands not further explained yet.
auth-nocache
auth-user-pass password.txt
crl-verify crl.pem
# Enable compression on the VPN link.
# Don't enable this unless it is also
# enabled in the server config file.
comp-lzo
# By default, log messages will go to the syslog (or
# on Windows, if running as a service, they will go to
# the "\Program Files\OpenVPN\log" directory).
# Use log or log-append to override this default.
# "log" will truncate the log file on OpenVPN startup,
# while "log-append" will append to it. Use one
# or the other (but not both).
;log openvpn.log
;log-append openvpn.log
# Set log file verbosity.
verb 3