What's new

AdGuardHome Asuswrt-Merlin-AdGuardHome-Installer (AMAGHI) cont.

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Status
Not open for further replies.
Just for dev info, and unrelated to this issue, the changelog for the next unreleased version (0.107.44) state this:



I see that the issue 6545 was raised by dev, so just a reminder that this is reaching the release channel :)

I was trying to wait for it to be closer to being released to the main branch before I did anything to the installer; however, in the good spirit of change I updated the installer to be ready for the next update released by adguardhome.
 
Hey guys,

I had to reinstall my router from scratch since the wifi was buggy. Therefore I'm doing Adguard from scratch with unbound.

Unbound installed and I'm blocked at configuring the different DNS settings.

For the upstream, here is my config. I added the lan configuration (local-domain like lan), my domain for my websites (i.e. google.com) and the unbound stuff (127.0.0.1).

Code:
[/router.asus.com/][::]:553
[/www.asusnetwork.net/][::]:553
[/www.asusrouter.com/][::]:553
[/use-application-dns.net/][::]:553
[/dns.resolver.arpa/][::]:553
[/local-domain/]192.168.50.1:553
[//][::]:553
[/domain/]192.168.50.1:553
tcp://127.0.0.1:53535
127.0.0.1:53535

Only change concerns the local domain, not sure if it's the correct syntax (not sure if I need to add [::]


Concerning the following two DNS settings (fallback and the other), I don't know what to add since I'm using unbound. Currently it is

Code:
1.0.0.1
8.8.8.8
tcp://1.0.0.1
tcp://8.8.8.8

Lastly for the private DNS I can't seem to add the local domain inside, I keep getting an error (not a reversed IP network) :

Code:
[::]:553
[/10.in-addr.arpa/][::]:553
[/168.192.in-addr.arpa/][::]:553
[/local-domain/]192.168.50.1:553

Thanks for all your help.
 
Hey guys,

I had to reinstall my router from scratch since the wifi was buggy. Therefore I'm doing Adguard from scratch with unbound.

Unbound installed and I'm blocked at configuring the different DNS settings.

For the upstream, here is my config. I added the lan configuration (local-domain like lan), my domain for my websites (i.e. google.com) and the unbound stuff (127.0.0.1).

Code:
[/router.asus.com/][::]:553
[/www.asusnetwork.net/][::]:553
[/www.asusrouter.com/][::]:553
[/use-application-dns.net/][::]:553
[/dns.resolver.arpa/][::]:553
[/local-domain/]192.168.50.1:553
[//][::]:553
[/domain/]192.168.50.1:553
tcp://127.0.0.1:53535
127.0.0.1:53535

Only change concerns the local domain, not sure if it's the correct syntax (not sure if I need to add [::]


Concerning the following two DNS settings (fallback and the other), I don't know what to add since I'm using unbound. Currently it is

Code:
1.0.0.1
8.8.8.8
tcp://1.0.0.1
tcp://8.8.8.8

Lastly for the private DNS I can't seem to add the local domain inside, I keep getting an error (not a reversed IP network) :

Code:
[::]:553
[/10.in-addr.arpa/][::]:553
[/168.192.in-addr.arpa/][::]:553
[/local-domain/]192.168.50.1:553

Thanks for all your help.
You shouldn't need to add local-domain to your private dns section since it is already covered in your upstream section.

I would change your upstream to

Code:
[/router.asus.com/][::]:553
[/www.asusnetwork.net/][::]:553
[/www.asusrouter.com/][::]:553
[/use-application-dns.net/][::]:553
[/dns.resolver.arpa/][::]:553
[/local-domain/][::]:553
[//][::]:553
tcp://127.0.0.1:53535
127.0.0.1:53535
For syntax consistancies sake.
 
Last edited:
You shouldn't need to add local-domain to your private dns section since it is already covered in your upstream section.

I would change your upstream to

Code:
[/router.asus.com/][::]:553
[/www.asusnetwork.net/][::]:553
[/www.asusrouter.com/][::]:553
[/use-application-dns.net/][::]:553
[/dns.resolver.arpa/][::]:553
[/local-domain/][::]:553
[//][::]:553
tcp://127.0.0.1:53535
127.0.0.1:53535
For syntax consistancies sake.
Great thanks, and what should I add in the reverse DNS since I'm using unbound? Let it be since it won't be used?
 
Whether it's for 1st time installation (just tried) or just to update AGH, it's impossible for me to enter "ag" script UI without changing "Wan: Use local caching DNS server as system resolver (default: No)" to yes.
So when RMerlin release next update that removes said option, AGH will become unusable: https://www.snbforums.com/threads/a...-support-underway-for-3-wifi-7-routers.90126/
In the ASUS Webui, what do you have your WANDNS1 and WANDNS2 set to because these values cannot be empty if you are to run AGH? That could be the main reason your DNS is not working because when the local cache is selected, the Router himself relies on DNSMASQ's upstream for DNS (or who ever holds 127.0.0.1 on port 53). When AdGuardHome is running, then AdGuardHome becomes the local DNS cache. When you turn off local cache option, it should fall back to your WANDNS1 and WANDNS2 as the upstream DNS for the Router himself. So when you try to access the install script, it should be querying who ever is your DNS for the Router himself. IF WANDNS1 and WANDNS2 are not blank, then your internet has not been restored yet after making the NVRAM variable switch. You may have to manually restart the router or run service restart_dnsmasq from the command line. I recommend restarting the router though.

If neither work, then proceed to this method below:

The option for Adguardhome to become the local cache is hard coded as a yes/no question in the installer. If users answer the question using yes, then it is away around the issue. All I would have to do is take away the yes/no part and make it a default option (but I am not going to, we must keep @dave14305 at bay). Users running the installer don't get asked that question if they have the nvram variable set like you do though. But since @RMerlin plans to remove that feature, everyone will be getting asked a yes/no question from now on. If you want to switch to the "AGH scripts" method, I have made it to where your nvram variable will be set to "0".

If you run this into the command line:

Code:
nvram set dns_local_cache="0"
nvram commit
VALUE=$(printf "\"YES\"" | sed 's/[]\/()$*.^|[]/\\&/g')
if grep -q "ADGUARD_LOCAL" "/opt/etc/AdGuardHome/.config"; then
        sed -i "/^ADGUARD_LOCAL=/s/=.*/=${VALUE}/" "/opt/etc/AdGuardHome/.config"
    else
        printf "%s\n" "ADGUARD_LOCAL=${VALUE}" >>"/opt/etc/AdGuardHome/.config"
fi
service restart_AdGuardHome

after updating to the next release you should be good to go. The above steps will activate the AGH local caching feature.
 
Last edited:
Setting up AGH on a GT-AX6000 and it seems the installation gets "stuck" after re-entering the password to be setup

This was done with no other script/add-on
Any idea on what the issue could be?
Code:
=>  Select your timezone/location, [1-595]: 312
 Info:  Singapore selected
 Info:  Configuring AdGuardHome...
 =>  Do you want to redirect all DNS resolutions on your network through to AdGuardHome? [y/n]: y
 Info:  You can choose to keep any custom dnsfilter values by only redirect non-custom traffic or send all traffic through to AdGuardHome.
 =>  Do you want to redirect only NON-CUSTOM DNS resolutions on your network through to AdGuardHome? [y/n]: n
 Info:  DNS is set to redirect All DNS resolutions through to AdGuardHome.
 =>  Do you want to run AdGuardHome as a local caching DNS service which includes router traffic? [y/n]: y
 Info:  Requesting entries for AdGuardHome initial configuration...
 Info:  Please set the preferred Web Port for AdGuardHome WebUI.
 Info:  The chosen port must reside within the port range 3000-65535
 Info:  and not already in use by any other service.
 =>  Default is 3000: 3000
 Info:  Set the Username and Password which will be encrypted to the yaml file.
 =>  Please enter AdGuardHome username: kylim
 =>  Please enter AdGuardHome password:
 =>  Please reenter AdGuardHome password:
 
Setting up AGH on a GT-AX6000 and it seems the installation gets "stuck" after re-entering the password to be setup

This was done with no other script/add-on
Any idea on what the issue could be?
Code:
=>  Select your timezone/location, [1-595]: 312
 Info:  Singapore selected
 Info:  Configuring AdGuardHome...
 =>  Do you want to redirect all DNS resolutions on your network through to AdGuardHome? [y/n]: y
 Info:  You can choose to keep any custom dnsfilter values by only redirect non-custom traffic or send all traffic through to AdGuardHome.
 =>  Do you want to redirect only NON-CUSTOM DNS resolutions on your network through to AdGuardHome? [y/n]: n
 Info:  DNS is set to redirect All DNS resolutions through to AdGuardHome.
 =>  Do you want to run AdGuardHome as a local caching DNS service which includes router traffic? [y/n]: y
 Info:  Requesting entries for AdGuardHome initial configuration...
 Info:  Please set the preferred Web Port for AdGuardHome WebUI.
 Info:  The chosen port must reside within the port range 3000-65535
 Info:  and not already in use by any other service.
 =>  Default is 3000: 3000
 Info:  Set the Username and Password which will be encrypted to the yaml file.
 =>  Please enter AdGuardHome username: kylim
 =>  Please enter AdGuardHome password:
 =>  Please reenter AdGuardHome password:
The only thing that could be causing a hangup there is if the password encryption is being hindered. An example would be is if the password encryption software was not being installed with your entware setup.

Try this straight in the SSH commandline:

Code:
opkg install python3 python3-pip python3-bcrypt
pip3 install bcrypt

I am trying to see if they are installed, or if you get any errors trying to install them.

This was done with no other script/add-on
Any idea on what the issue could be?

Also, I hope I mentioned somewhere that this script requires a non-corrupt fully up-to-date Entware repository as a prerequisite before you will be able to run AdGuardHome successfully.

1718561849513.png
 
Last edited:
Issue looks like it's due to the bcrypt dependency. On a fresh setup, Entware was installed and up to date but do not contain any python or python-bcrypt related packages

fresh_install.png
 
Issue looks like it's due to the bcrypt dependency. On a fresh setup, Entware was installed and up to date but do not contain any python or python-bcrypt related packages

View attachment 59520
So, after installing entware, what is the output from running

Code:
opkg install python3 python3-pip python3-bcrypt
pip3 install bcrypt

in the SSH commandline? I ask because the installer performs these commands during the installation process.
 
Hi. I'm new to addons. Will receive my RT-AX86U Pro in a few days.

I have already read a lot. I see that people installing Unbound along with Adguarg Home. Bu I read somewhere, that Adguard already does a recursive lookup, so why installing both then? Thank you.
 
So, after installing entware, what is the output from running

Code:
opkg install python3 python3-pip python3-bcrypt
pip3 install bcrypt

in the SSH commandline? I ask because the installer performs these commands during the installation process.

I didn't capture the output but IIRC,
Code:
opkg install python3 python3-pip python3-bcrypt
- the usual output i.e. download and then install when installing packages

Code:
pip3 install bcrypt
- gives a warning about running as root and this is actually not needed since the previous command already did the bcrypt install

Do you mean the AGH installer performs the installation of those packages? I don't recall seeing any output related to those packages unless during the installation process the output is "silenced"
 
so why installing both then?

AdGuard Home works as Forwarder to upstream DNS server, Unbound can work as Forwarder or Resolver. You don't really need Unbound, what built-in Dnsmasq or AdGuard Home do is good enough for home router, if not better. No need to complicate things for no reason.
 
  • Like
Reactions: Igs
I didn't capture the output but IIRC,
Code:
opkg install python3 python3-pip python3-bcrypt
- the usual output i.e. download and then install when installing packages

Code:
pip3 install bcrypt
- gives a warning about running as root and this is actually not needed since the previous command already did the bcrypt install

Do you mean the AGH installer performs the installation of those packages? I don't recall seeing any output related to those packages unless during the installation process the output is "silenced"
No I was responding to your previous post above since you are aware that Entware doesn't natively come with these packages installed. Obviously there would have to be some method the installer uses whereby the packages get installed; the packages were not "divined" from unnatural means. What an astute observation, the process is "silenced". My question was merely to find out if Entware was providing an output error when you tried to install those packages manually because it would have had to "error" out at some point if the installer was stalling when you were setting the new password.
One of the means it would error out is if you somehow got past the check for entware, but had no entware...
Another means is if your entware wasn't up-to-date. I have seen issues where the packages would not install due to dependency issues if entware was not already up-to-date (e.g. opkg update && opkg upgrade).
Finally, if your entware wasn't properly mounted or was on a corrupt disk- I have seen errors in this instance as well; in such instances, typically entware will have problems with installing packages.
 
Last edited:
AdGuard Home works as Forwarder to upstream DNS server, Unbound can work as Forwarder or Resolver. You don't really need Unbound, what built-in Dnsmasq or AdGuard Home do is good enough for home router, if not better. No need to complicate things for no reason.
Thanks for the answer. So those both you mentioned can cache dns records, hence work as a DNS resolver? And yeah, I don't care where they are resolving DNS queries...
 
Status
Not open for further replies.

Similar threads

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top