[HowTo] Running Adguard Home on OpenWrt

Here is my config for reference. Following the tutorials in this thread.

1 Like

Okay, so this time round I had a little bit more success when running the initial setup.
I now got the black interface! :smiley:

This may seem obvious to everyone else here, but for me, I am confused as to what interface selection I am supposed to choose?

Last time I selected:
Admin Web Interface: br-lan-192.168.1.1 PORT: 8000
DNS Server: br-lan-192.168.1.1 PORT:5353

I am wondering if this is why when I selected "run as dns/masq upstream server" it then killed my connectivity and other clients on my network when configured in OpenWRT's administration portal (Luci) -> Services - AGH. Is this the part I messed up?

What interface selection are you supposed to choose? :thinking:

Thanks for your patience gnashk. :beer: I'm back tracking a bit to ask questions on things I thought were the right selection initially.

EDIT: I think I would like to filter just my computer initially, take the time to get used to it, then later look at how to configure it for complete home network filtering.

All interfaces
Admin Web Interface: 192.168.1.1 PORT: 8000
DNS Server: 192.168.1.1 PORT:5353

  1. get acquainted with the standard tools under linux. mv, cp, chown, chmod, tar etc. you will need them daily when working with unix systems.
  2. just connect to the router via ssh and leave out winscp.

I don't understand the complexity behind the long thread. You just have to download the binary and run it:

ssh root@192.168.1.1
opkg update && opkg install wget

mkdir /opt/ && cd /opt
wget -c https://github.com/AdguardTeam/AdGuardHome/releases/download/v0.101.0/AdGuardHome_linux_armv5.tar.gz
tar xfvz AdGuardHome_linux_armv5.tar.gz
rm AdGuardHome_linux_armv5.tar.gz

Either just run it /opt/AdGuardHome/AdGuardHome or install it directly with /opt/AdGuardHome/AdGuardHome -s install

The web interface should run on a port other than 80, since Luci already runs on it. The DNS port should be other than 53, because the standard OpenWrt DNS server is already listening on port 53. So use 5353 and send all requests from 53 to 5353. You can do this with the firewall.user rule in my first post. Also make sure to edit the dhcp config!

Edit: I altered my first post and made things more clear.

I just wanted to take the time to thank everyone here for their help in assisting me and others with providing a great tutorial to follow to install AdGuard on an OpenWrt router. This thread has been an incredible resource to me for getting things up and running.

Cheers!
Special thanks to gnashk, WildByDesign, brokenpipe, zzzzoooo and Brickme!!! :smiley: :beer:
~Dustyn~

3 Likes

Anyone else getting this error?
I installed AdGuardHome on a clean install of OpenWrt.
My filterlists also don't update.

error

1 Like

I believe it's because you need the ca-bundle and ca-certificates.

# Need ca-bundle & ca-certificates to make filter rule update work
opkg install ca-bundle, ca-certificates
3 Likes

That's the solution, thanks!!

1 Like

Hello! Will they add the app in LuCI?

1 Like

Just going forward for anybody taking this as reference: You only need one; either ca-bundle or ca-certificates. Not both.

1 Like

there is a 3rd party package. but its only half of the configuration, as the rest is in adguard itself.
but you can adjust those settings via the yaml file in luci

1 Like

hi all, actually testing ADG and work fine, but i use "redirect 53 to ADG" and not use "Run as dnsmasq upstream server" because don't work ( bad config by me probably, because i'm noob )

so

is possible change time for log file ?

and how to ?

thank you

sorry for my bad english :sweat_smile:

I think that's not possible. The config values are integers (days). You may try and edit the AdguardHome.yaml manually.

  statistics_interval: 7
  querylog_interval: 7

I get this whenever I try either one of those commands:

line 1: syntax error: unexpected word (expecting ")")

Does the binary exists under this path? Did you copy paste the command or did you type it in (maybe with tab and auto completion?). Maybe try another release (beta) or re-download the current release.

The binary does exist under this path. I did copy and paste the command, and I tried redownloading too, same result. How do I get beta release?

search for: Test unstable versions

Make sure the architecture is correct.

For example for my Netgear R7800: https://static.adguard.com/adguardhome/beta/AdGuardHome_linux_arm.tar.gz

Yes I am seeing the same error running latest OpenWrt 19.07.3.

Has anyone here got AdGuard to run on that version?

I have AGH running on latest 19.07.3 with no errors or issues. I have mine installed and running as a service, not sure if that makes a difference in error vs no error though. Also, mine was upgraded from 19.07.2 to 19.07.3 with AGH coming along for the ride via sysupgrade conf.

Ok looks like I installed the wrong architecture. I am using an EdgeRouter X so this release works for me:
https://github.com/AdguardTeam/AdGuardHome/releases/download/v0.102.0/AdGuardHome_linux_mipsle.tar.gz