Hello,
I've be struggling with an issue since few days now and can't get to the bottom of it. Here is a link of the question I asked on Serverfault (that has developed a bit since then) :
http://serverfault.com/questions/615094/openvpn-not-assigning-fixed-ip
I am using a VPS (at OVH, all root access and etc), running Debian.
I can connect to the VPN the "normal" way. My problem is that whenever I try giving fixed IPs to my clients, it fails. If I add the rule ccd-exclusive, I get this error message :
TLS Auth Error: --client-config-dir authentication failed for common name 'userRaph' file='/etc/openvpn/jail/ccd/userRaph'
Here is my server configuration :
#Serveur TCP/443
mode server
proto udp
port 443
dev tun
#Cles et certificats
ca ca.crt
cert server.crt
key server.key
dh dh1024.pem
tls-auth ta.key 1
key-direction 0
cipher AES-256-CBC
#Reseau
server 10.8.0.0 255.255.255.0
route 10.8.0.0 255.255.255.252
push "redirect-gateway def1 bypass-dhcp"
push "dhcp-option DNS 208.67.222.222"
push "dhcp-option DNS 208.67.220.220"
client-config-dir ccd
ccd-exclusive
keepalive 10 120
#Securite
user nobody
group nogroup
chroot /etc/openvpn/jail
persist-key
persist-tun
comp-lzo
#Log
verb 4
mute 20
status openvpn-status.log
log-append /var/log/openvpn.log
My client configuration file (openvpn/clientconf/userRaph/client.conf) :
# Client
client
dev tun
proto udp
remote 92.222.34.20 443
resolv-retry infinite
cipher AES-256-CBC
# Cles
ca ca.crt
cert userRaph.crt
key userRaph.key
tls-auth ta.key 1
key-direction 1
# Securite
nobind
persist-key
persist-tun
comp-lzo
verb 3
Also, in /openvpn/ccd I created the file userRaph with the following line :
ifconfig-push 10.8.0.50 10.8.0.49
And I also created a link between /openvpn/jail/ccd pointing to /openvpn/ccd
Besides this problem, I also have a limited bandwidth when connecting to my VPN server (when I let it give me the IP it wants). It seems I can't have higher than 10Mpbs (using speedtest.net), while my server has a 100Mpbs bandwidth and my home connection 20Mbps (and when I do a speedtest without the VPN, I get way higher than the 10Mpbs I have with the VPN). What can cause this and how to solve it?
Thanks for you help,
Raphael