I have searched, read, and experimented but have failed to get the settings I need.
I can ping any machine on server lan. I can ping client from server, but I can't ping client from another machine on server lan.
server ip = 172.23.93.9
client ip = 192.168.4.254
server tun1 = 10.8.1.1
client tun1 = 10.8.1.5
The tun0 you see on client side is a server the client is running.
These are my configurations.
server:
port 1195
proto tcp
dev tun1
ca ca.crt
cert mgtsciences.crt
key mgtsciences.key # This file should be kept secret
dh dh.pem
topology subnet
server 10.8.1.0 255.255.255.0
ifconfig-pool-persist ipp.txt
push "route 172.23.93.0 255.255.255.0"
push "dhcp-option DNS 172.23.93.3"
push "dhcp-option DNS 208.67.222.222"
push "dhcp-option DNS 208.67.220.220"
client-to-client
client-config-dir ccd
route 192.168.4.0 255.255.255.0 10.8.1.1
keepalive 10 120
comp-lzo
persist-key
persist-tun
status openvpn-status.log
verb 3
plugin /usr/lib/openvpn/plugins/openvpn-plugin-auth-pam.so login
Client configuration on server side:
iroute 192.168.4.0 255.255.255.0
push "route 172.23.93.0 255.255.255.0 10.8.1.1"
Client configuration:
client
dev tun
proto tcp
remote SERVER_PUBLIC_IP 1195
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca-client.crt
cert durwin-alt.crt
key durwin-alt.key
remote-cert-tls server
comp-lzo
verb 3
auth-user-pass auth.txt
Routing table on server:
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
0.0.0.0 172.23.93.1 0.0.0.0 UG 0 0 0 em1
10.8.1.0 0.0.0.0 255.255.255.0 U 0 0 0 tun1
172.23.93.0 0.0.0.0 255.255.255.0 U 0 0 0 em1
192.168.4.0 10.8.1.1 255.255.255.0 UG 0 0 0 tun1
Routing table on client:
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
0.0.0.0 192.168.4.1 0.0.0.0 UG 0 0 0 enp1s0
10.8.0.0 0.0.0.0 255.255.255.0 U 0 0 0 tun0
10.8.1.0 0.0.0.0 255.255.255.0 U 0 0 0 tun1
172.23.93.0 10.8.1.1 255.255.255.0 UG 0 0 0 tun1
192.168.4.0 0.0.0.0 255.255.255.0 U 0 0 0 enp1s0
Routing table on 'other machine':
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
0.0.0.0 172.23.93.1 0.0.0.0 UG 0 0 0 enp0s3
10.8.1.0 172.23.93.9 255.255.255.0 UG 0 0 0 enp0s3
172.23.93.0 0.0.0.0 255.255.255.0 U 0 0 0 enp0s3
192.168.4.0 172.23.93.9 255.255.255.0 UG 0 0 0 enp0s3
I can ping the tun1 interface from other machine, but not the client.
I appreciate the help.
Thank you.