Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

openvpn and iptables - no local hostnames accessible

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
kbian
Posts: 1
Joined: 2016-02-07 20:02

openvpn and iptables - no local hostnames accessible

#1 Post by kbian »

Hello,

i managed to set up an openvpn server, ip-forwarding and a nat iptable rule for that.

Almost everything works as expected, but my problem is:

Smartphone -> VPN -> Internet ==> works (by ip and hostname)
Smartphone -> VPN -> machine in my local network by IP ==> works
Smartphone -> VPN -> machine in my local network by its hostname => DOES NOT WORK
Machine w/ VPN server -> ping to machine in local network by ip or hostname => works

So, i wonder why i cant access a local machine through the vpn by its hostname.
I guess i'm missing a forwarding rule??
I read a lot of stuff about iptables, but i couldnt figure out where the problem is, yet.

Who knows what to do?

iptables dump:
# Generated by iptables-save v1.4.21 on Sun Feb 7 20:56:52 2016
*nat
:PREROUTING ACCEPT [786:59064]
:INPUT ACCEPT [728:53047]
:OUTPUT ACCEPT [19:1487]
:POSTROUTING ACCEPT [20:1576]
-A POSTROUTING -s 10.8.0.0/24 -j MASQUERADE
COMMIT
# Completed on Sun Feb 7 20:56:52 2016
Thanks!
btw: running raspbian jessie on a raspberry pi.

Post Reply