Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] dns problem with vpnc and internal domain
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
Lawless
l33t
l33t


Joined: 03 Nov 2003
Posts: 638
Location: Germany

PostPosted: Thu Apr 12, 2007 8:33 pm    Post subject: [solved] dns problem with vpnc and internal domain Reply with quote

Hi,

I have turned my gentoo server into a router providing dns and dhcp services through dnsmasq.
I have set up a private domain home.lan and managed to get it working on all machines so that I can simply ping the other dhcp clients by name.

Now I also need a vpn connection (with vpnc) which brings in another private domain name in a .prv network and I cannot get the name resolution working for both.

Without vpnc resolv.conf is looking like this
Code:

# Generated by dhcpcd for interface eth0
search home.lan
nameserver 192.168.0.1

whereas vpnc makes this out if it
Code:

#@VPNC_GENERATED@ -- this file is generated by vpnc
# and will be overwritten by vpnc
# as long as the above mark is intact
# Generated by dhcpcd for interface eth0
search home.lan otherdomain.prv
nameserver 10.x.x.x
nameserver 10.x.x.y

With this resolv.conf I cannot ping machine.home.lan.
If I add 192.168.0.1 to the file I have to put it as the first nameserver - then I can ping home.lan but not the prv network names... how can I work with both?!
_________________
Kernel panic: I have no root and I want to scream


Last edited by Lawless on Sat Apr 14, 2007 7:07 am; edited 1 time in total
Back to top
View user's profile Send private message
jsfan
Apprentice
Apprentice


Joined: 28 Dec 2004
Posts: 204
Location: Melbourne, Australia

PostPosted: Sat Apr 14, 2007 2:41 am    Post subject: Reply with quote

Just a thought... Can you put your local DNS server into the VPN too and get it to resolve .prv through the VPN's DNS server? That might work...
Back to top
View user's profile Send private message
d_m
Guru
Guru


Joined: 12 Jun 2003
Posts: 570
Location: Philadelphia, PA, USA

PostPosted: Sat Apr 14, 2007 3:13 am    Post subject: Reply with quote

The problem here is that your operating system assumes that all of the nameservers in resolv.conf agree. You might imagine that it will try contacting all of them and then see which of them were able to resolve the name, but it doesn't. Thus, if you want to be able to resolve your private DNS queries, and also resolve your internal company DNS queries, you have (at least) the following options:

1. use /etc/hosts to put in entries for one set of queries, and use DNS for the other.
2. set up your private DNS server so it can resolve your VPN DNS queries (possibly by having it also use vpnc; this is what jsfan suggests).

Good luck.
_________________
The name that can be named is not the eternal name.
Back to top
View user's profile Send private message
Lawless
l33t
l33t


Joined: 03 Nov 2003
Posts: 638
Location: Germany

PostPosted: Sat Apr 14, 2007 7:07 am    Post subject: Reply with quote

I've installed dnsmasq on the client now to provide a local dns which itself knows about home.lan and prv.
_________________
Kernel panic: I have no root and I want to scream
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum