Hey,
I've an OpenVPN server on a raspberry (IP 192.168.11.150) which is behind 2 routers
Gateway router : 192.168.1.1
Main router : 192.168.11.1
I've created an OVPN file for my android cellphone and I'm able to connect and get an IP from the VPN server (10.8.100.6)
However I can't access local resources on the main network (192.168.11.1) where I've a Samba server and other stuff.
Can you help me config my server ?
Thanks in advance
This is server.config
local 192.168.11.150 # SWAP THIS NUMBER WITH YOUR RASPBERRY PI IP ADDRESS
dev tun USED FOR IP TUNNEL
proto udp #Some people prefer to use tcp. Don't change it if you don't know.
port 1194
ca /etc/openvpn/easy-rsa/keys/ca.crt
cert /etc/openvpn/easy-rsa/keys/server.crt # SWAP WITH YOUR CRT NAME
key /etc/openvpn/easy-rsa/keys/server.key # SWAP WITH YOUR KEY NAME
dh /etc/openvpn/easy-rsa/keys/dh1024.pem # If you changed to 2048, change that here!
server 10.8.100.0 255.255.255.0
# server and remote endpoints
ifconfig 10.8.100.1 10.8.100.2
# Add route to Client routing table for the OpenVPN Server
push "route 10.8.100.1 255.255.255.255"
# Add route to Client routing table for the OpenVPN Subnet
push "route 10.8.100.0 255.255.255.0"
# your local subnet
push "route 192.168.11.150 255.255.255.0" # SWAP THE IP NUMBER WITH YOUR RASPBERRY PI IP ADDRESS
# Set primary domain name server address to the SOHO Router
# If your router does not do DNS, you can use Google DNS 8.8.8.8
push "dhcp-option DNS 192.168.11.1" # This should already match your router address and not need to be changed.
# Override the Client default gateway by using 0.0.0.0/1 and
# 128.0.0.0/1 rather than 0.0.0.0/0. This has the benefit of
# overriding but not wiping out the original default gateway.
push "redirect-gateway def1"
client-to-client
duplicate-cn
keepalive 10 120
tls-auth /etc/openvpn/easy-rsa/keys/ta.key
cipher AES-128-CBC
comp-lzo
user nobody
group nogroup
persist-key
persist-tun
status /var/log/openvpn-status.log 20
log /var/log/openvpn.log
verb 1