Now this is probably somewhat my fault for changing the start-network script ages ago but I do kind of rely on a working DNS setup.
I use NFS root on all 6 of my OSMC instances and this has been shown to be somewhat slightly different from a standard SD card install. Network startup specifically.
This used to be the fix to prevent connman from generating an empty resolv.conf file on DHCP lease renewal. Recent change meant it broke connman completely and was causing all sorts of weird errors at boot time.
I used to use this in /usr/bin/start-network:
exec /usr/sbin/connmand -n --nodnsproxy --noresolvmodify --config=/etc/connman.conf
but suddenly, and I assume a recent update caused this, connman refuses to run thanks to my noresolvmodify flag.
Job for connman.service failed because the control process exited with error code.
See “systemctl status connman.service” and “journalctl -xe” for details.
Process: 20944 ExecStart=/usr/bin/start-network (code=exited, status=1/FAILURE)
/usr/bin/start-network
Unknown option --noresolvmodify
So I removed the modification to start-network and connman works. Then my DHCP lease renews and my resolv.conf file is empty, again.
Back to the old fix.
sudo rm /etc/resolv.conf
sudo ln -s /proc/net/pnp /etc/resolv.conf
Which works and I hope permanently solves my DNS issues. Until the next time it gets broken of course.