j> If I'm understanding correctly, you set up two servers, [...]
j> The internal server forwards requests to the external server [...]
That's one way of setting up "split horizon" DNS service, but not the
best one.
<URL:
http://homepages.tesco.net./~J.deBoynePollard/FGA/dns-split-horizon.html>
For far better results, the "external" DNS server should serve your
DNS database content only. It should not provide proxy DNS service
for lookup of the rest of the world's DNS database content. Recursion
should be disabled. Providing promiscuous proxy DNS service is as bad an idea as providing promiscuous proxy HTTP service, or promiscuous
SMTP Relay service.
As such, your "internal" DNS server should either perform query
resolution itself, using root hints, or should forward to another
proxy DNS server closer to the rest of Internet that performs query
resolution. (Your ISP may provide you with proxy DNS service, for
example.)
j> What I don't understand is how anything (maybe the web server)
j> on the outside finds out about where resources are on the
j> inside (like the database server the web data resides on)?
Concepts such as "on the outside" and "on the inside" are too
simplistic and misleading. The fact that a content HTTP server
listens on a publically reachable IP address does not mean that
it is required to see the "public" view of the DNS namespace.
The fact that the rest of Internet uses the "public" view of the
DNS namespace to locate your content HTTP server's IP address
does not mean that your content HTTP server is required to have
that view _itself_.