Thank you. Not the "lightweight" solution I was hoping for, using just the 
hosts file and maybe dnsmasq. But this is certainly do-able, especially 
with the helpful examples you've provided. If bind and dhcpd are what's 
called for, that's what I'll do.

...after I spend a bit more time studying your examples and digesting the 
info, that is!


On Wednesday, February 28, 2018 at 3:22:00 PM UTC-5, mwall wrote:
>
> robb,
>
> put two NICs on the computer that weewx runs on.  lets call them thing1 
> and thing2.
>
> thing1 should be the regular network configuration - it provides 
> connectivity for the computer.  it should be your LAN subnet, lets say 
> 192.168.25.0/24.  your router would be 192.168.25.1 and your computer 
> would be something like 192.168.25.30, with subnet mask of 255.255.255.0 
> and broadcast mask of 192.168.25.255.
>
> thing2 will be a private network that serves only the acurite device. 
>  give it its own subnet, lets say 192.168.100.0/24.  so the computer will 
> show up on that LAN as 192.168.100.1.
>
> configure dhcpd to run on the computer, but only serve the thing2 
> interface.  if you want, get the mac addr of the acurite device and make 
> dhcp give it the same address every time.
>
> configure bind to run on the computer, but to only serve the thing2 
> interface.  in your bind configuration, make hubapi.myacurite.com map to 
> 192.168.100.1.
>
> so what does look like? (i am using the traditional linux configurations, 
> because i find them easier to express/manage than the networkmanager junk - 
> nmcli and nmtui)
>
> this is NOT a recipe - do not just copy/paste!
>
> sudo apt-get install bind9 dhcpd
>
> /etc/network/interfaces should be something like this:
>
> auto lo
> iface lo inet loopback
> # thing1
> allow-hotplug eth0
> iface eth0 inet static
>   address 192.168.25.30
>   netmask 255.255.255.0
>   network 192.168.25.255
>   gateway 192.168.25.1
> # thing2
> allow-hotplug eth1
> iface eth1 inet static
>   address 192.168.100.1
>   netmask 255.255.255.0
>   network 192.168.100.255
>   gateway 192.168.100.1
>
> the bind configuration should be something like this in 
> /etc/bind/named.conf.local:
>
> zone "hubapi.myacurite.com" {
>     type master;
>     file "/etc/bind/myacurite.com";
> };
>
>
> in the file /etc/bind/myacurite.com:
>
> $TTL    604800
> @       IN      SOA     dns.hubapi.myacurite.com. root.hubapi.myacurite.com. (
> 2016032001 ; Serial
>     604800 ; Refresh
>      86400 ; Retry
>    2419200 ; Expire
>     604800 ) ; Negative Cache TTL
> ;
> @       IN      NS      dns.hubapi.myacurite.com.
> @       IN      A       Y.Y.Y.Y
> *       IN      A       Y.Y.Y.Y
> *       IN      AAAA    ::1
>
>
> /etc/dhcp/dhcpd.conf should be something like this:
>
> subnet 192.168.100.0 netmask 255.255.255.0 {
>   option routers 192.168.100.1;
>   option subnet-mask 255.255.255.0;
>   option domain-name-servers 192.168.100.1;
>   range 192.168.100.100 192.168.100.254;
>   default-lease-time 3600;
>   max-lease-time 7200;
>
> #  host hub {
> #    hardware ethernet xx:xx:xx:xx:xx:xx;
> #    fixed-address 192.168.100.10;
> #  }
> }
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to