Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
HELP! I am attempting to setup a OpenVPN connection that will allow traffic to go from any workstation on Network A to any workstation on Network B (and vice-versa)
Network A is as follows.
OpenVPN server IP subnet = 192.168.143.0
OpenVPN server IP address = 192.168.143.12
VPN Network subnet = 10.14.30.0
VPN Network address = 10.14.30.1
Network B is as follows.
OpenVPN client IP subnet = 192.168.163.0
OpenVPN cclient IP address = 192.168.163.8
VPN Network subnet = 10.14.30.0
VPN Network address = 10.14.30.6
Using the following configuration files, I can establish a connection from the client to the server. Also, the client is able to ping any workstation on the server network. For example 192.168.16.8 can ping any 192.168.143.0 address. That direction works well. However, the server cannot ping the client (192.168.143.12 (VPN server) cannot ping 192.168.163.8). But 192.168.143.12 CAN ping 10.14.30.6 so I know that the traffic from the VPN server is getting to the client machine, just not to the right device. Also, other than the VPN client on network B (192.168.163.8) no other workstation on Network B can ping anything on network A, despite having the router on Network B routing 192.168.143.0 traffic to 192.168.163.8.
Any ideas? Can OpenVPN be a conduit that will allow traffic from any workstation on Network A to communicate with and workstation on Network B?
Here are the config files.
* server.conf
port 1194
proto udp
dev tun
ca /etc/openvpn/ca.crt
cert /etc/openvpn/server.crt
key /etc/openvpn/server.key
dh /etc/openvpn/dh1024.pem
server 10.14.30.0 255.255.255.0
push "route 192.168.143.0 255.255.255.0"
keepalive 10 120
comp-lzo
persist-key
persist-tun
max-clients 3
status openvpn-status.log
verb 5
mute 20
client-config-dir ccd
route 192.168.163.0 255.255.255.0
client-to-client
push "route 192.168.163.0 255.255.255.0"
* client3 (located in /etc/openvpn/ccd/)
iroute 192.168.163.0 255.255.255.0
* client.conf
client
dev tun
proto udp
remote xxx.xxx.xxx.xxx 1194
nobind
persist-key
persist-tun
ca /etc/openvpn/ca.crt
cert /etc/openvpn/client3.crt
key /etc/openvpn/client3.key
comp-lzo
verb 3
mute 20
Hopefully I've read everything correctly, but as I see things, you need to add a route on the server to see the client network (192.168.163.0/255.255.255.0 to use tun0). Not quite sure why
Code:
route 192.168.163.0 255.255.255.0
isn't working, but I don't use this setup.
Try your openvpn logs to see if there's an error on trying to set this route on startup.
I'm trying to do the same thing, create a site-to-site VPN with two linux machines using OpenVPN. Why wouldn't you use a tap0 device on the client (or Network B) machine too?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.