I ran in to a similar issue on Windows, which is described here: [1]
After following that article's suggestion to disable the Windows "DNS Client" service name resolution returned to normal.
[1] - https://tinyapps.org/blog/201809300700_large_hosts_file.html