1 |
On 05/22/13 15:35, Samuraiii wrote: |
2 |
> The only result I got was a script which every 5 minutes checked all |
3 |
> possible addresses of given machine (my "network" is not big at all - |
4 |
> only eight machines and one network printer). So checking around 20 |
5 |
> addreses is not big deal - but this approach feels clumsy and not |
6 |
> scalable to bigger networks (as have other users from list to deal with). |
7 |
> |
8 |
> Script was just checking (by sftp with public ssh keys for unprivileged |
9 |
> account) if LAN (eth or wifi) address is up and if not it just assigned |
10 |
> address to hostname from vpn range (it did not accounted if machine is |
11 |
> up or down). And the just write new /etc/hosts. |
12 |
> Central dns is possible only in one part of network - only one machine |
13 |
> runs 24/7. |
14 |
|
15 |
Can't this be changed? If you're running a script to update 20 hosts |
16 |
files regularly, you're reinventing what DNS already does. |
17 |
|
18 |
|
19 |
> |
20 |
> Routers on both sides are just simple boxes which support only built-in |
21 |
> dhcp. |
22 |
> Central DNS and/or routed VPN does not solve problem of compute not in |
23 |
> any of "known" networks. |
24 |
|
25 |
Both would solve the problem. |
26 |
|
27 |
If the routers are the VPN gateways as well, you could decide e.g. that |
28 |
a certain chunk of the VPN space belongs to location 1, and then have |
29 |
the router at location 1 do the appropriate thing (all packets travel |
30 |
through it, after all). This can be done directly with some VPN |
31 |
software, or you can translate the addresses on the fly with iptables. |
32 |
|
33 |
With a DNS server at each physical location, you just have the DNS |
34 |
server at location 1 return the local (location 1) address instead of |
35 |
the VPN address for any hostnames physically located at location 1. |