getdnsapi / stubby

Stubby is the name given to a mode of using getdns which enables it to act as a local DNS Privacy stub resolver (using DNS-over-TLS).
https://dnsprivacy.org/dns_privacy_daemon_-_stubby/
BSD 3-Clause "New" or "Revised" License
1.17k stars 97 forks source link

Stubby and Openwrt installation procedure #360

Open hanvinke opened 1 month ago

hanvinke commented 1 month ago

Lately I cannot install stubby as usual:

` opkg install stubby Unknown package 'stubby'. Collected errors:

I am using latest release Openwrt 23.05.03. The firmwareselector page from openwrt also does not recognize Stubby as a program anymore.

Is this intentional?

hanvinke commented 1 month ago

Update: Although I updated twice with opkg update Stubby was not found. But Stubby was found after updating through the luci gui. Probably the reason it was not found on the firmware selector page is because the device i use is only supported through a Snapshot (not yet officially supported).

Stubby

So I will close this issue.

wtoorop commented 1 month ago

Thanks for reporting @hanvinke . If anyone else has the issue, we at least know what to do.

hanvinke commented 1 month ago

@wtoorop Thanks for the reaction!

Did not have much time recently to test Stubby. But got some mixed feelings when following the guide for installing with OpenWrt though. For instance when a user reboots the device Stubby will lose its DNSSEC functionality. This is because the directory "/var/lib/stubby/" does not exist anymore. The reason is OpenWrt´s /var is just a symlink to /tmp, thus only resides on a tmpfs-partition. It is however not recreated on boot. So Stubby´s Zero configuration will fail and will try to look for the default trust anchor location.

"Stubby -i" shows "default_trust_anchor_location": <bindata of "/etc/unbound/getdns-root.key" But Unbound is not installed, only dnsMasq. Maybe it is an idea to give some more information about this in the README? I think a normal user might get frustrated about Stubby not working after a reboot.

//Edit: I still need to examine if there is a difference in behaviour when using an ext4 or squashfs openWRT-image when installing Stubby.

hanvinke commented 1 month ago

Reopening and changed description

rmandrad commented 6 days ago

@wtoorop Thanks for the reaction!

Did not have much time recently to test Stubby. But got some mixed feelings when following the guide for installing with OpenWrt though. For instance when a user reboots the device Stubby will lose its DNSSEC functionality. This is because the directory "/var/lib/stubby/" does not exist anymore. The reason is OpenWrt´s /var is just a symlink to /tmp, thus only resides on a tmpfs-partition. It is however not recreated on boot. So Stubby´s Zero configuration will fail and will try to look for the default trust anchor location.

"Stubby -i" shows "default_trust_anchor_location": <bindata of "/etc/unbound/getdns-root.key" But Unbound is not installed, only dnsMasq. Maybe it is an idea to give some more information about this in the README? I think a normal user might get frustrated about Stubby not working after a reboot.

//Edit: I still need to examine if there is a difference in behaviour when using an ext4 or squashfs openWRT-image when installing Stubby.

read the openwrt forum ... you have an option to have /var permanent ... and really has this anything to do with stubby !!! open a question instead on forum.openwrt.org

hanvinke commented 6 days ago

@rmandrad Hi, thank you for your input.

I think my main concern is more about a simple user following the instructions found on https://github.com/openwrt/packages/blob/master/net/stubby/files/README.md . These are fine but are missing in my opinion some important points. [ I just hate to see a highly sophisticated program like Stubby fail in the real world because of some silliness. The creators deserve better in my opinion. ]

Firstly Stubby will not work "out of the box" after installation. This is because the directory /var/lib/stubby is not created automatically. So mkdir /var/lib stubby and chown -R stubby:stubby /var/lib/stubby is needed. Then it would be nice to have a description about adding /var/lib/stubby to the backup list via System > Backup/Flash firmware via LuCI. Then with an attended sysupgrade (see https://openwrt.org/docs/guide-user/installation/attended.sysupgrade) the directory and files will be preserved after a reinstallation for example. I don´t know if making /var permanent is in general a good idea in this case.