dave14305
Part of the Furniture
I noticed today after enabling IPv6 and testing nextdns.io, that I was seeing AAAA requests for router.asus.com in the nextdns.io console logs. Sure enough, the hosts file has no IPv6 address for router.asus.com, so it was apparently forwarding the AAAA requests upstream with no luck.
After researching a little bit, I read this post and decided to write a script to get the address from nvram. I'm opting against the advice of @ColinTaylor (I call this spitting in the wind) and not using the link-local address, since it looks nicer in Windows nslookup.
I guess this was solved in John's fork a while back, but Merlin hasn't adopted it as best I can tell. There is code for lan_hostname but those nvram variables aren't populated in my setup. If there's a better way to do this, I'm open to ideas (e.g. dnsmasq). I just want to prevent sending router.asus.com upstream in the end.
FYI for @IsaacFL from a couple years ago.
/jffs/scripts/hosts.postconf
After researching a little bit, I read this post and decided to write a script to get the address from nvram. I'm opting against the advice of @ColinTaylor (I call this spitting in the wind) and not using the link-local address, since it looks nicer in Windows nslookup.
I guess this was solved in John's fork a while back, but Merlin hasn't adopted it as best I can tell. There is code for lan_hostname but those nvram variables aren't populated in my setup. If there's a better way to do this, I'm open to ideas (e.g. dnsmasq). I just want to prevent sending router.asus.com upstream in the end.
FYI for @IsaacFL from a couple years ago.
/jffs/scripts/hosts.postconf
Code:
#!/bin/sh
CONFIG="$1"
. /usr/sbin/helper.sh
if [ "$(nvram get ipv6_service)" != "disabled" ]; then
pc_append "$(nvram get ipv6_rtr_addr) $(nvram get local_domain)" "$CONFIG"
pc_append "$(nvram get ipv6_rtr_addr) $(nvram get computer_name).$(nvram get lan_domain) $(nvram get computer_name)" "$CONFIG"
fi