Local hostnames are not accessible on a client when connected externally to my network via OpenVPN

This thread has been locked for further replies. You can start a new thread to share your ideas or ask questions.

Local hostnames are not accessible on a client when connected externally to my network via OpenVPN

This thread has been locked for further replies. You can start a new thread to share your ideas or ask questions.
Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-05-31 11:13:28
Model: ER7206 (TL-ER7206)   EAP245   OC200  
Hardware Version: V1
Firmware Version: 1.3.0 Build 20230322 Rel.70951

At my home network i have the following setup:

 

OC200 Controller

ER7206 (router)

4x EAP245 accespoint

PiHole on a raspberry

 

Issue description

I have an OpenVPN server configured. Using an external client (iOS) i can make a connection and access local ip's. But i am not able to access local hostname such as nas1.local. While this hostname is accessible when locally connected to my network. I'm not a network expert. I was also not able to find any solutions searching online and within the community. Maybe someone can help me solve this. Thank you.

 

Configuration

I have 1 LAN configured and the DNS is fixed set to my pihole 192.168.1.90. All other settings are default.

PiHole on my Raspberry as DNS server: 192.168.1.90

 

My OpenVPN server config:

 

 

My LAN config

 

  0      
  0      
#1
Options
9 Reply
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-05-31 13:29:03

  @m85 I'm not entirely sure if my suggestion will help but you can try setting up mDNS in Omada, here's a page from the knowledge base:

 

https://community.tp-link.com/en/business/kb/detail/412610

The reason I suggest this is because:

 

1. Your OpenVPN IP Pool and LAN pool are two different subnets, mDNS will forward broadcast packets across different subnets for you.

2. You are using an iOS device, they typically rely on the Bonjour service (mDNS) for discovery.

  0  
  0  
#2
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-05-31 15:34:16

  @itsAlex thanks I will try that. I tried to put the vpn server on the same subnet before. That did not help. I will try with mDNS enabled. 

  0  
  0  
#3
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-06-01 06:15:12

  @m85 

 

Hi, I don't think it supports using the mDNS based on the VPN, but it's ok, you can test it.

If it doesn't work, then definitely it doesn't support it.

Just striving to develop myself while helping others.
  0  
  0  
#4
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-06-01 15:19:25 - last edited 2023-06-01 15:23:53

  @m85 If mDNS doesn't work, you can also try setting the primary DNS server as the gateway IP address in your VPN policy. 

 

I am not sure if this is done by default in Omada, but you can try this. Your router/gateway should be caching DNS lookups for faster resolves in future requests. The router may also have information about your local clients and their hostnames/IP addresses.

 

Hypothetically, if OpenVPN used your gateway as a DNS server, then it should be able to resolve local hostnames. If the router/gateway does not have info about a DNS query, the gateway will forward the query to the next DNS server (most likely external, provided by your ISP or a custom one such as 1.1.1.1 (cloudflare) ).

 

Let me know if this helps.

  0  
  0  
#5
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-06-02 07:57:32

  @itsAlex mDNS did not help.

 

As my pihole is my DNS server. I set the IP in the OpenVPN configuration as the primary DNS server. Do you mean this? I also set the IP pool to the same subnet as my network.

 

I exported the config again and imported it on my iOS device. It still does not work to access domain.local hostnames. Local IP addresses do work.

 

 

  0  
  0  
#6
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-06-02 13:07:06

  @m85 Yes, that is what I meant. However, if you have your Pi-hole as your primary DNS server, try setting the secondary DNS server as your gateway IP address.

 

Does Pi-hole have the ability to set external DNS servers when it is unable to resolve a query? If so, Try setting one of the external DNS servers as your gateway IP in Pi-hole instead of doing it in Omada, or maybe try doing it in both as an experiment.

 

Let me know if this helps.

  0  
  0  
#7
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-06-02 18:27:22 - last edited 2023-06-02 18:29:10

  @itsAlex i set both the primary and secondy DNS in the OpenVPN server to 192.168.1.1 as this is my gateway ip. In both cases it did not solve my problem.

 

Also i was checking my pihole and was seeing these warning messages. Not sure what they mean. I am not a network export.

 

 

 

  0  
  0  
#8
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-06-02 18:42:45

  @m85 It might be some setting in my pihole that should make this work. I found these settings. I tried the Permit all origins settings. But it did not help also.

 

  0  
  0  
#9
Options
Re:Local hostnames are not accessible on a client when connected externally to my network via OpenVPN
2023-06-04 07:51:27

  @m85 i also put DNS in the Omada controller back to auto. So it wont use PiHole anymore. That did not help aswell.

  0  
  0  
#10
Options

Information

Helpful: 0

Views: 611

Replies: 9