Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running without root #723

Open
ameshkov opened this issue Apr 22, 2019 · 3 comments
Open

Running without root #723

ameshkov opened this issue Apr 22, 2019 · 3 comments

Comments

@ameshkov
Copy link
Member

ameshkov commented Apr 22, 2019

See the details and the conversation here:
#720

And here:
#1193 (comment)

@timkgh
Copy link

timkgh commented Oct 13, 2021

Any progress on this please? It is pretty important and the issue has been open for over 2 years.

@ameshkov
Copy link
Member Author

https://github.com/AdguardTeam/AdGuardHome/wiki/Getting-Started#running-without-superuser

@h4rp00n33r
Copy link

Hey Folks!

I can't get AdGuardHome working in rootless mode following @ameshkov 's link:

https://github.com/AdguardTeam/AdGuardHome/wiki/Getting-Started#running-without-superuser

I installed the current version (0.107.44) on a fresh Debian Bookworm server and followed the instructions from the wiki (setcap etc.). Ownership of all files is set to the user "me". First run was done with root privileges: sudo ./AdGuardHome -s install. After that I stopped AdGuard Home again.

When I run AdGuard Home now with ./AdguardHome -s run it works perfectly (but of course not as a service) as you can see here:

me@some-debian-server:/opt/AdGuardHome$ ./AdGuardHome -s run
2024/02/15 19:20:30 [info] AdGuard Home, version v0.107.44
2024/02/15 19:20:30 [info] service: control action: run
2024/02/15 19:20:30.206518 [info] AdGuard Home, version v0.107.44
2024/02/15 19:20:30.206626 [info] AdGuard Home is running as a service
2024/02/15 19:20:30.207252 [info] tls: using default ciphers
2024/02/15 19:20:30.207753 [info] safesearch default: disabled
2024/02/15 19:20:30.216009 [info] Initializing auth module: /opt/AdGuardHome/data/sessions.db
2024/02/15 19:20:30.216165 [info] auth: initialized.  users:1  sessions:0
2024/02/15 19:20:30.216215 [info] web: initializing
2024/02/15 19:20:30.220724 [info] dnsproxy: cache: enabled, size 4096 b
2024/02/15 19:20:30.220843 [info] dnsproxy: max goroutines is set to 300
2024/02/15 19:20:30.221042 [info] dnsproxy: cache: disabled
2024/02/15 19:20:30.221239 [info] AdGuard Home is available at the following addresses:
2024/02/15 19:20:30.221434 [info] go to http://127.0.0.1:8080
2024/02/15 19:20:30.221473 [info] go to http://[::1]:8080
2024/02/15 19:20:30.238463 [info] go to http://192.168.178.20:8080
2024/02/15 19:20:30.238547 [info] go to http://[f3d3:b86e:9884:3681:1f74:99bc:cb4e:7e17]:8080
2024/02/15 19:20:30.238697 [info] go to http://[f3d3:b86e:9884:3681:1f74%enp0s3]:8080
2024/02/15 19:20:30.238781 [info] go to http://172.17.0.1:8080
2024/02/15 19:20:30.221678 [info] clients: processing addresses
2024/02/15 19:20:30.330715 [info] dnsproxy: starting dns proxy server
2024/02/15 19:20:30.330944 [info] Ratelimit is enabled and set to 20 rps, IPv4 subnet mask len 24, IPv6 subnet mask len 56
2024/02/15 19:20:30.331032 [info] The server is configured to refuse ANY requests
2024/02/15 19:20:30.331134 [info] dnsproxy: cache: enabled, size 4194304 b
2024/02/15 19:20:30.331198 [info] dnsproxy: max goroutines is set to 300
2024/02/15 19:20:30.331281 [info] dnsproxy: creating udp server socket 0.0.0.0:53535
2024/02/15 19:20:30.331425 [info] dnsproxy: listening to udp://[::]:53535
2024/02/15 19:20:30.331466 [info] dnsproxy: creating tcp server socket 0.0.0.0:53535
2024/02/15 19:20:30.331667 [info] dnsproxy: listening to tcp://[::]:53535
2024/02/15 19:20:30.331890 [info] dnsproxy: entering udp listener loop on [::]:53535
2024/02/15 19:20:30.332009 [info] dnsproxy: entering tcp listener loop on [::]:53535
2024/02/15 19:21:00.229163 [info] auth: user "ahab" successfully logged in from ip 192.168.178.21

Trying to run AdGuard Home as a service with ./AdGuardHome -s start leads to this error:

2024/02/15 19:19:19 [info] AdGuard Home, version v0.107.44
2024/02/15 19:19:19 [info] service: control action: start
2024/02/15 19:19:19 [fatal] service: executing action "start": Failed to start AdGuard Home service: exit status 4

What am I missing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants