Routing question oVPN -> Local Netzwork

This forum is for admins who are looking to build or expand their OpenVPN setup.
Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
vpnistlustig
OpenVpn Newbie
Posts: 4
Joined: Sun May 16, 2021 8:37 am

Routing question oVPN -> Local Netzwork

Post by vpnistlustig » Wed Dec 01, 2021 9:16 am

Hello Community,

i have a question about Routing Local Network to VPN, i hope that this is possible.

My scenario:
- OpenVPN Server on rented vServer
- Win10 PC with special Software behind AVM Router 100/100 MBIT (Client1, Lan 192.168.178.50, VPN 10.80.1.6)
- 3 Clients (Win10 Laptops on different locations) - (Client 2-4, 10.80.1.x)

All devices are connected to the vpn server.
The Laptops use a RDP Connection to the PC (Client 1) - The Clients connect the RDP about the 10.80.1.6 Address, works great.

Now my next Step, on the PC Client 1 is a Harddrive that i share as a network drive share connection, but this work only (on the other clients) when connecting to IP 10.80.1.6 (and only when im turn off the Client1 Firewall), but i want to route the Local Network (192.168.178.x) from Client1 to the other clients, so they can use the Local IP 192.168.178.50 from Client 1 and Connect to the network drive share about 192.168.178.50 and not 10.80.1.6.

For better understanding , i have a picture:
Image


My Server.conf:
server

port 1194
proto udp
dev tun0
ca ./zertifikat/ca.crt
cert ./zertifikat/server-cert.crt
key ./zertifikat/server-cert.key
dh ./zertifikat/dh2048.pem
server 10.80.1.0 255.255.255.0
ifconfig-pool-persist ./status/ipp.txt
status ./status/vpn-status.log
log ./status/vpn-log.log
client-to-client
keepalive 10 120
comp-lzo
verb 6
client-config-dir ccd
persist-key
persist-tun


My Client Conf:
client

client
dev tun0
proto udp
remote 1xx.2xx.1xx.1xx 1194
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca.crt
cert client1.crt
key client1.key
ns-cert-type server
comp-lzo
verb 3


So, is it possible that all Clients (2-4) cann connect to the network drive share on client1 ?

User avatar
TinCanTech
Forum Team
Posts: 10276
Joined: Fri Jun 03, 2016 1:17 pm

Re: Routing question oVPN -> Local Netzwork

Post by TinCanTech » Wed Dec 01, 2021 1:18 pm

vpnistlustig wrote:
Wed Dec 01, 2021 9:16 am
is it possible that all Clients (2-4) cann connect to the network drive share on client1 ?
sure ..

vpnistlustig
OpenVpn Newbie
Posts: 4
Joined: Sun May 16, 2021 8:37 am

Re: Routing question oVPN -> Local Netzwork

Post by vpnistlustig » Thu Dec 02, 2021 6:58 am

Sorry, but this is not really helpful.
I now that this is possible, i think i asked my question wrong:

What i have to do or to change that it works to connect the clients to the network drive share on client1 with local ip adress?

User avatar
TinCanTech
Forum Team
Posts: 10276
Joined: Fri Jun 03, 2016 1:17 pm

Re: Routing question oVPN -> Local Netzwork

Post by TinCanTech » Thu Dec 02, 2021 1:16 pm

vpnistlustig wrote:
Thu Dec 02, 2021 6:58 am
What i have to do or to change that it works to connect the clients to the network drive share on client1 with local ip adress?
By looking at your configs, I would suggest that you start by reading the Howto.

vpnistlustig
OpenVpn Newbie
Posts: 4
Joined: Sun May 16, 2021 8:37 am

Re: Routing question oVPN -> Local Netzwork

Post by vpnistlustig » Thu Dec 02, 2021 3:31 pm

Why? Whats wrong with my config?
I have no problems with the vpn, only with the routing.

User avatar
TinCanTech
Forum Team
Posts: 10276
Joined: Fri Jun 03, 2016 1:17 pm

Re: Routing question oVPN -> Local Netzwork

Post by TinCanTech » Thu Dec 02, 2021 3:36 pm

I can clearly see, from your configs, that you have not read the howto.

vpnistlustig
OpenVpn Newbie
Posts: 4
Joined: Sun May 16, 2021 8:37 am

Re: Routing question oVPN -> Local Netzwork

Post by vpnistlustig » Thu Dec 02, 2021 9:01 pm

forget it. i hope to get help here, but all i see is senseless answers.

User avatar
TinCanTech
Forum Team
Posts: 10276
Joined: Fri Jun 03, 2016 1:17 pm

Re: Routing question oVPN -> Local Netzwork

Post by TinCanTech » Thu Dec 02, 2021 9:41 pm

The help you get is to read the howto

It has been written, so that people like you can learn from it.

Post Reply