[SOLVED] Unbound + Connman sysV init
by walker from LinuxQuestions.org on (#5SE95)
Testing the just released Devuan Chimera (more an Alpha considering the hours spent to tune it IMHO) I crashed against the error "Unbound can't connect to port 53 - port already in use".
I discovered that connman was the only tool able to connect using a Nokia 2 phone as hotspot and a D-Link 131 E1 as usb wireless dongle (neither ceni nor the supplied OOTB Gnome network manager were able to establish a connection) trying JWK-Kit iso https://dev1galaxy.org/viewtopic.php?id=4473 (I like JWM but I'm a little lazy a stroke is always a stroke also for someone certified as net admin).
The trouble came when I tried to install unbound on Chimera after I installed connman in chroot to have the connection.
First the above mentioned error, don't care about it as in windows it's enough to shutdown and reboot to have unbound starting before connman (why it listen on port 53 is anyway a mystery to me) and connman-ui-gtk (no need of full connman) already connected on login.
The second trouble was that connman-ui-gtk was always changing the /etc/resolv.conf and dns supplied by ISP doesn't work (connman get the gateway IP as DNS server) as hotspot from pc that's why unbound.
Never give up!
After a little search I discovered a few hints https://community.toradex.com/t/how-...l-v1-0a/4382/3 enough to solve the issue from cli.
To set the DNS you want without that it would be changed every time by connman is enough to get the name of the connection issuing
connmanctl services (as root)
which gives all the connection available with on top marked with AR the connection up
*AR xxxxx wifi_xxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxx_managed_psk
then it's enough to issue
connmanctl config wifi_xxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxx_managed_psk --nameservers 127.0.0.1
to have always unbound running on your machine set as DNS resolver.
Hope this helps, for systemd I've no experience nor hints, I'm an old fart loving plain vanilla old GNU/Linux still POSIX compliant.
I discovered that connman was the only tool able to connect using a Nokia 2 phone as hotspot and a D-Link 131 E1 as usb wireless dongle (neither ceni nor the supplied OOTB Gnome network manager were able to establish a connection) trying JWK-Kit iso https://dev1galaxy.org/viewtopic.php?id=4473 (I like JWM but I'm a little lazy a stroke is always a stroke also for someone certified as net admin).
The trouble came when I tried to install unbound on Chimera after I installed connman in chroot to have the connection.
First the above mentioned error, don't care about it as in windows it's enough to shutdown and reboot to have unbound starting before connman (why it listen on port 53 is anyway a mystery to me) and connman-ui-gtk (no need of full connman) already connected on login.
The second trouble was that connman-ui-gtk was always changing the /etc/resolv.conf and dns supplied by ISP doesn't work (connman get the gateway IP as DNS server) as hotspot from pc that's why unbound.
Never give up!
After a little search I discovered a few hints https://community.toradex.com/t/how-...l-v1-0a/4382/3 enough to solve the issue from cli.
To set the DNS you want without that it would be changed every time by connman is enough to get the name of the connection issuing
connmanctl services (as root)
which gives all the connection available with on top marked with AR the connection up
*AR xxxxx wifi_xxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxx_managed_psk
then it's enough to issue
connmanctl config wifi_xxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxx_managed_psk --nameservers 127.0.0.1
to have always unbound running on your machine set as DNS resolver.
Hope this helps, for systemd I've no experience nor hints, I'm an old fart loving plain vanilla old GNU/Linux still POSIX compliant.