I have a public url like app1.wifi.com
,so that I can access my url from anywhere. Now I want to set that same url to my local machine. If I type app1.wifi.com
from my LAN, it should routed to local app1.wifi.com
. To achieve this, I tried the below configuration.
I have a Windows 7 machine, where I installed BIND9, I set that machine IP to 192.168.1.2 and named it app1.wifi.com
. It is connected with a router (192.168.1.1
). In BIND conf
, I have 2 forward look up zones and 2 reverse lookup zones. In addition, I have .
zone
1)localhost
2)0.0.127.in-addr.arpa (reverse lookup)
3)wifi.com
4)1.168.192.in-addr.arpa(reverse lookup of wifi.com).
I'm able to communicate with external urls (Google, Yahoo...) from 192.168.1.2
.
On the other end of the router I have another machine connected to the same network with an IP of 192.168.1.3
. On 192.168.1.3
, I set the DNS server IP as 192.168.1.2
. If I ping app1.wifi.com
from 192.168.1.3
,the result is:
ping app1.wifi.com.
Ping request could not find host app1.wifi.com. Please check the name and try again.
C:\windows\system32>nslookup app1.wifi.com
DNS request timed out.
timeout was 2 seconds.
Server: UnKnown
Address: 192.168.1.2
DNS request timed out.
timeout was 2 seconds.
DNS request timed out.
timeout was 2 seconds.
DNS request timed out.
timeout was 2 seconds.
DNS request timed out.
timeout was 2 seconds.
*** Request to UnKnown timed-out
C:\windows\system32>
How do I get this working with app1.wifi.com
locally? I'm able to communicate with external urls (Google, Yahoo...) from 192.168.1.2
, but not from 192.168.1.3
. The result of an nslookup
from 192.168.1.3
is below:
nslookup google.com
Server: UnKnown
Address: 192.168.1.2
------------
SendRequest(), len 28
HEADER:
opcode = QUERY, id = 11, rcode = NOERROR
header flags: query, want recursion
questions = 1, answers = 0, authority records = 0, additional = 0
QUESTIONS:
google.com, type = A, class = IN
------------
DNS request timed out.
timeout was 10 seconds.
timeout (10 secs)
SendRequest failed.
And on 192.168.1.2
, I'm not getting any queries from 192.168.1.3
(I set the ACL to 192.168.1/24
).
Note: Important thing is that 192.168.1.2
should communicate with external urls. This machine should communicate with app2.wifi.com
, so in this case how do I set up domain name locally and configure app1.wifi.com
locally?