AdGuard Topic is solved

Having issues with your DietPi installation or found a bug? Post it here.
NoLifer
Posts: 20
Joined: Sun May 02, 2021 7:10 pm

AdGuard

Post by NoLifer »

Hi, I installed AdGuard but I can't access it. I've checked

dietpi-services status and I got this error

Code: Select all

[FAILED] DietPi-Services | ● adguardhome.service - AdGuard Home (DietPi)
     Loaded: loaded (/etc/systemd/system/adguardhome.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Sun 2021-10-17 09:54:29 BST; 263ms ago
    Process: 3150 ExecStart=/mnt/dietpi_userdata/adguardhome/AdGuardHome (code=exited, status=1/FAI    LURE)
   Main PID: 3150 (code=exited, status=1/FAILURE)
        CPU: 270ms

Oct 17 09:54:29 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is a    t 5.
Oct 17 09:54:29 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:54:29 DietPi systemd[1]: adguardhome.service: Start request repeated too quickly.
Oct 17 09:54:29 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:54:29 DietPi systemd[1]: Failed to start AdGuard Home (DietPi).
Any ideas how to fix it?
User avatar
Joulinar
Posts: 6525
Joined: Sat Nov 16, 2019 12:49 am

Re: AdGuard

Post by Joulinar »

Hi,

Pls can you share following

Code: Select all

journalctl -u adguardhome
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
NoLifer
Posts: 20
Joined: Sun May 02, 2021 7:10 pm

Re: AdGuard

Post by NoLifer »

Code: Select all

root@DietPi:~# journalctl -u adguardhome
-- Journal begins at Sun 2021-10-17 09:49:53 BST, ends at Sun 2021-10-17 10:17:01 BST. --
Oct 17 09:49:55 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:49:57 DietPi AdGuardHome[531]: 2021/10/17 09:49:57.131021 [info] AdGuard Home, version v0.106.3
Oct 17 09:49:57 DietPi AdGuardHome[531]: 2021/10/17 09:49:57.135933 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:49:57 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:49:57 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:50:02 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 1.
Oct 17 09:50:02 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:50:02 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:50:02 DietPi AdGuardHome[691]: 2021/10/17 09:50:02.631158 [info] AdGuard Home, version v0.106.3
Oct 17 09:50:02 DietPi AdGuardHome[691]: 2021/10/17 09:50:02.635309 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:50:02 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:50:02 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:50:07 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 2.
Oct 17 09:50:07 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:50:07 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:50:08 DietPi AdGuardHome[807]: 2021/10/17 09:50:08.161366 [info] AdGuard Home, version v0.106.3
Oct 17 09:50:08 DietPi AdGuardHome[807]: 2021/10/17 09:50:08.178694 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:50:08 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:50:08 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:50:13 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 3.
Oct 17 09:50:13 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:50:13 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:50:13 DietPi AdGuardHome[869]: 2021/10/17 09:50:13.422329 [info] AdGuard Home, version v0.106.3
Oct 17 09:50:13 DietPi AdGuardHome[869]: 2021/10/17 09:50:13.424429 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:50:13 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:50:13 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:50:18 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 4.
Oct 17 09:50:18 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:50:18 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:50:18 DietPi AdGuardHome[938]: 2021/10/17 09:50:18.924888 [info] AdGuard Home, version v0.106.3
Oct 17 09:50:18 DietPi AdGuardHome[938]: 2021/10/17 09:50:18.925784 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:50:18 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:50:18 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:50:24 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 5.
Oct 17 09:50:24 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:50:24 DietPi systemd[1]: adguardhome.service: Start request repeated too quickly.
Oct 17 09:50:24 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:50:24 DietPi systemd[1]: Failed to start AdGuard Home (DietPi).
Oct 17 09:54:03 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:54:03 DietPi AdGuardHome[2937]: 2021/10/17 09:54:03.506925 [info] AdGuard Home, version v0.106.3
Oct 17 09:54:03 DietPi AdGuardHome[2937]: 2021/10/17 09:54:03.508953 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:54:03 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:54:03 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:54:08 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 1.
Oct 17 09:54:08 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:54:08 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:54:08 DietPi AdGuardHome[3015]: 2021/10/17 09:54:08.832123 [info] AdGuard Home, version v0.106.3
Oct 17 09:54:08 DietPi AdGuardHome[3015]: 2021/10/17 09:54:08.834245 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:54:08 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:54:08 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:54:14 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 2.
Oct 17 09:54:14 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:54:14 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:54:14 DietPi AdGuardHome[3088]: 2021/10/17 09:54:14.276328 [info] AdGuard Home, version v0.106.3
Oct 17 09:54:14 DietPi AdGuardHome[3088]: 2021/10/17 09:54:14.278292 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:54:14 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:54:14 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:54:19 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 3.
Oct 17 09:54:19 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:54:19 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:54:19 DietPi AdGuardHome[3143]: 2021/10/17 09:54:19.536830 [info] AdGuard Home, version v0.106.3
Oct 17 09:54:19 DietPi AdGuardHome[3143]: 2021/10/17 09:54:19.537599 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:54:19 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:54:19 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:54:24 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 4.
Oct 17 09:54:24 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:54:24 DietPi systemd[1]: Started AdGuard Home (DietPi).
Oct 17 09:54:24 DietPi AdGuardHome[3150]: 2021/10/17 09:54:24.798827 [info] AdGuard Home, version v0.106.3
Oct 17 09:54:24 DietPi AdGuardHome[3150]: 2021/10/17 09:54:24.800668 [fatal] couldn't read config file /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: open /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml: permission denied
Oct 17 09:54:24 DietPi systemd[1]: adguardhome.service: Main process exited, code=exited, status=1/FAILURE
Oct 17 09:54:24 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:54:29 DietPi systemd[1]: adguardhome.service: Scheduled restart job, restart counter is at 5.
Oct 17 09:54:29 DietPi systemd[1]: Stopped AdGuard Home (DietPi).
Oct 17 09:54:29 DietPi systemd[1]: adguardhome.service: Start request repeated too quickly.
Oct 17 09:54:29 DietPi systemd[1]: adguardhome.service: Failed with result 'exit-code'.
Oct 17 09:54:29 DietPi systemd[1]: Failed to start AdGuard Home (DietPi).
User avatar
Joulinar
Posts: 6525
Joined: Sat Nov 16, 2019 12:49 am

Re: AdGuard

Post by Joulinar »

Well you have stored user data on an external disk, right? And it seems AGH has issues to read configuration file due to permission issues. What file system format your external disk has?

Can you share as well following

Code: Select all

ls -la /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
NoLifer
Posts: 20
Joined: Sun May 02, 2021 7:10 pm

Re: AdGuard

Post by NoLifer »

My external drive has ntfs file system

Code: Select all

root@DietPi:~# ls -la /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome
total 18973
drwxr-xr-x 1 adguardhome adguardhome     4096 May 19 14:25 .
drwxrwxr-x 1 dietpi      dietpi          4096 Oct 17 09:46 ..
-rwxr-xr-x 1 adguardhome adguardhome 19333120 May 19 14:25 AdGuardHome
-rw------- 1 adguardhome adguardhome      331 May 19 14:25 AdGuardHome.sig
---------- 1 adguardhome adguardhome     2589 Oct 17 09:34 AdGuardHome.yaml
-rw------- 1 adguardhome adguardhome    16827 May 19 14:25 CHANGELOG.md
-rw------- 1 adguardhome adguardhome    35149 May 19 14:25 LICENSE.txt
-rw------- 1 adguardhome adguardhome    22689 May 19 14:25 README.md
User avatar
Joulinar
Posts: 6525
Joined: Sat Nov 16, 2019 12:49 am

Re: AdGuard

Post by Joulinar »

for whatever reason your configuration file has no permission at all. Means nobody could access it and therefore AGH service is failing.

Code: Select all

---------- 1 adguardhome adguardhome     2589 Oct 17 09:34 AdGuardHome.yaml
pls try following

Code: Select all

chmod 600 /mnt/94BA918FBA916F0C/dietpi_userdata/adguardhome/AdGuardHome.yaml
The file should have r/w permission now. Try to restart AGH.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
NoLifer
Posts: 20
Joined: Sun May 02, 2021 7:10 pm

Re: AdGuard

Post by NoLifer »

Thank you! It's helped, everything is working now. Friend had same problem, looks like it don't like ntfs system :?
User avatar
Joulinar
Posts: 6525
Joined: Sat Nov 16, 2019 12:49 am

Re: AdGuard

Post by Joulinar »

what kind of system your are running. Maybe I could try to replicate

Required Information
  • DietPi version | cat /boot/dietpi/.version
  • Distro version | echo $G_DISTRO_NAME $G_RASPBIAN
  • Kernel version | uname -a
  • SBC model | echo $G_HW_MODEL_NAME or (EG: RPi3)
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
NoLifer
Posts: 20
Joined: Sun May 02, 2021 7:10 pm

Re: AdGuard

Post by NoLifer »

Code: Select all

root@DietPi:~# cat /boot/dietpi/.version
G_DIETPI_VERSION_CORE=7
G_DIETPI_VERSION_SUB=7
G_DIETPI_VERSION_RC=3
G_GITBRANCH='master'
G_GITOWNER='MichaIng'
root@DietPi:~# echo $G_DISTRO_NAME $G_RASPBIAN
bullseye 0
root@DietPi:~# uname -a
Linux DietPi 5.10.63-v7l+ #1459 SMP Wed Oct 6 16:41:57 BST 2021 armv7l GNU/Linux
root@DietPi:~# echo $G_HW_MODEL_NAME
RPi 4 Model B (armv7l)
User avatar
Joulinar
Posts: 6525
Joined: Sat Nov 16, 2019 12:49 am

Re: AdGuard

Post by Joulinar »

Independent on the issue, just a question. Is there a reason to use NTFS? Because I would recommend to use Linux file system format ext4 if possible. :)
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
Post Reply