Script: Update AdGuard Home

How exactly it works?
The script will check frequently if there is an Update available and if so, the new version will be installed without notice?

No, you will have to install AdGuard updates by yourself within the AdGuard GUI.
The script will just make sure that the update functionality within AGH is enabled.

1 Like

Thanks admon, I used your “Quick run without downloading” to update my AXT1800 and my MT6000 on a fly without any issues :saluting_face:

1 Like

Default GLiNet router has disable update adguard home within reason for storage or other things. All frimwares.
@admon made script for enable update adguard home and download latest version. In the future if you upgrading new frimware with save setting then will be work adguard home with enable update.
If you upgrade new frimware without save setting then will be installed old version Adguard home and disable update.


How the backup works?
It will generate a backup on every update or just the last one will be stored?

To save space, maybe the script could save just the latest one.


  • Updated from 0.107.40 to 0.107.44: save the backup of 0.107.40
  • Updated from 0.107.44 to 0.107.45: save the bakcup of 0.107.44 and delete the 0.107.40

In this way I guess the storage space needed will be small as possible.

I would kindly ask you to read the script by yourself, since it will answer all your questions.

The script will not create additional backups, only one (1) initial one.

1 Like

Installed correctly on MT-6000 and MT-3000, it works excellently! Many thanks!

I hope for an official implementation in the firmware of GL-iNet routers as soon as possible.


The router was updated with the latest release (4.5.7 release 7) and AdGuard Home continued to function correctly with the ability to check for updates! Good job! Thank you!


Updated to the latest 0.107.46

This is an interesting feature added on the latest version to save your eMMC from die due to too many writes on it:

1 Like

After the last update of the script, I can no longer install it in OpenWRT:

From the error itself, I would suggest to install curl: opkg install curl

@admon I wouldn’t use wget in the help and curl in the script. By reading the script, in line 116 both could be used.
If get is already on the base image this would prevent to check for dependencies within the script.

If the filename is the same remote and local, you even could remove -O in wget.

What router model you tried to update adguard home?

curl and wget are quite different and the curl version on the GL routers don’t support something, that I needed. Both should be installed by default anyway.

People running scripts should be able to read error messages and fix dependencies. If they are not, that should not run scripts. :sweat_smile:

The script was never designed for running it on plain OpenWrt.

@admon I understand you don’t support alternative forks. However, if you changed your mindset, it would help a lot of people, as it is also not possible to update AdguardHome directly from OpenWRT.

@LupusE Thanks for the advice, it worked perfectly! :slight_smile:

@slesar MT6000 with openwrt snapshot

Problay not using gl inet interface? That’s different. @admon made script only official gl inet interface because he made correct address files for default gl inet

So you could follow my alternative instruction :+1:t2:

In that case, the people maintaining the AdGuard Home package within OpenWrt should fix this.
They only need to remove --no-check-update from the init script. o_O

So mostly executing this should help you

sed -i '/procd_set_param command \/usr\/bin\/AdGuardHome/ s/--no-check-update //' "/etc/init.d/adguardhome"
1 Like

totally new to open-wrt and gL.iNet as a whole, how long until this gets fixed do you guys think?

read through the thread and there’s no way I could pull off a workaround…

Personally, I don’t think this will be fixed at all. It’s not a bug. AGH will certainly receive an update in the GL firmware at some point - but the workaround is, in my opinion, the best solution.

(The workaround is to use the script. See 1st post here)

1 Like

It’s not enough to just remove the line. It looks like there is something in OpenWRT that prevents Adguardhome from updating automatically and your script fixed this somehow:


You should report this to the AGH team or the OpenWrt team then - they need to figure out what’s going on.