Search code examples
apachetestingubuntudnslan

resolve subdomains on a LAN test server


I have a development machine "A" and a test server "B". A runs Windows, "B" runs ubuntu. I've set up correctly machine "B" (apache, /etc/hosts) so that e.g. curl site.B and curl site.localhost both give correct result. From windows (machine "A") when I curl site.B I get "curl: (6) Couldn't resolve host 'site.B'". Do you have any clues on how to resolve this issue? (HINT: it might be Windows or router hostname caching issue)


Solution

  • Windows also has a hosts file that you need to configure. The problem is that Microsoft spells /etc as %WINDIR%\System32\drivers\etc. :-)

    See http://en.wikipedia.org/wiki/Hosts_(file) for details.