OpenWRT upgrade: Dnsmasq problem solved

After upgrading OpenWRT to version 18.06.2 (current release at the time of writing) on one of my Xiaomi MiWiFi Mini routers I started seeing this error in System Log:

unknown user or group: dnsmasq

In addition to that users were not able to connect to WiFi due to not received DHCP configuration.

Luckily, on this page I've found a workaround:

echo "dnsmasq:*:453:dnsmasq" >> /etc/group
echo "dnsmasq:*:453:453:dnsmasq:/var:/bin/false" >> /etc/passwd
echo "dnsmasq:*:0:0:99999:7:::" >> /etc/shadow
chown dnsmasq.dnsmasq /usr/sbin/dnsmasq

Apparently Dnsmasq (which is DHCP server on OpenWRT) was not having it's user setup properly on the image.


My name is Gytis Repečka, I am Solution Architect and data professional. I enjoy using, promoting and contributing to open source software and love communicating about tech to both advanced and non-tech people. Visit Inretio for consulting services. Comment by mentioning me @gytisrepecka@social.gyt.is on Fediverse.