[plug] Hosting Help

Craig Ringer craig at postnewspapers.com.au
Sun Oct 24 18:19:55 WST 2004


On Sun, 2004-10-24 at 16:06, Joong Cho wrote:

> I have configured my /etc/hosts, /etc/resolv.conf files to match my domain 
> name server hosting. However, everytime I type in my domain name on the 
> address bar in Mozilla, I get the modem's web page management login page and 
> get the Server Error: 401 Unauthorized error message if I don't login. I 
> have configured my modem to allow port forwarding etc, but it still won't 
> work.

This isn't surprising, as the modem is unlikely to forward traffic from
the _internal_ network back to a host on the internal network. Try
accessing the site from an outside host like xbox.plug.linux.org.au. If
you don't have an account ... well, membership is cheap :-)

If you wish to be able to access your vhost from inside your network,
you can try an ugly /etc/hosts hack, some iptables tricks to SNAT local
traffic, or possibly run your modem in bridged mode and do the PPPoE on
your computer, so it really _is_ the Internet host it's pretending to
be. The other alternative is not to bother, and simply do your testing
by running a web browser remotely on a system outside your network.

Also, it may be obvious, but your domain will need to be configured so
that the 'A' record points back to your IP address. Otherwise nobody
knows that your webserver is running on your computer. Try something
like this:

$ dig +short @ns1.iinet.net.au mydomain.blah

to ask iiNet's domain name server who it thinks is hosting your server.
Here's what the POST's shows:

$ dig +short @ns1.iinet.net.au www.postnewspapers.com.au
202.0.185.27

Yours should show the external IP address assigned to your DSL modem. If
you're not sure what the IP refers to and it doesn't look familar, try
using dig -x:

$ dig +short @ns1.iinet.net.au -x 202.0.185.27
www.postnewspapers.com.au.

Omit the "+short" from both commands if you want a bit more detail. Also
feel free to omit the "@ns1.iinet.net.au" if you are not running a local
DNS server or are running one but not hosting any authorative zones that
may confuse things.

> Are there any more files that I have to configure in order for my domain 
> name server to work or any other files that I have to tweak?

I'm a little confused - we're talking about a domain name server. I'm
not sure I see how a DNS server fits into this discussion. Some context
on this question, such as why you are running a domain name server, what
you wish it to do, and what problem you are having with it, would be
very helpful.

If you in fact meant "web server for my domain", please ignore the above
paragraph. A "domain name server" is the name server that maps IP
addresses (like 192.168.0.1) to names like mail.blah.com.au .

--
Craig Ringer




More information about the plug mailing list