newbie: redirect 1st url --> 2nd url

Michael Kjorling michael at kjorling.com
Mon Apr 15 21:47:26 UTC 2002


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Apr 15 2002 16:06 -0400, Cate wrote:

> Greetings and please try to forgive me my trespass. I'm in a situation where
> I need to very quickly (info erroneously published that says this is so)
> forward one url, scrlc.org, to another, lakenet.org. (ie., I want to http to
> scrlc.org but get pointed immediately to lakenet.org) We own both but only
> use the latter. I only understand enough about this to know to check
> /var/named for a file called db.scrlc (it's there). I actually have the DNS
> & Bind book (2nd ed.), but I don't even know the name of what I'm trying to
> do. I think, in vaguest terms, that I need to 1) set up the db.scrlc file so
> that it resolves to something 2) set up either the db.scrlc file or the
> db.lakenet file to accept (?) the redirect from scrlc.org and 3) set up
> [something] to redirect scrlc.org to lakenet.org
>
> Would somebody who's still reading please give me the terminology of what
> I'm trying to do? Then I can understand what it is I'm to be looking up.
>
> Thanks,
> Cate

This question comes up every now and then, and the answer is the same
every time: this is nothing you can do with DNS alone.

First, though, I would suggest that you pick up a newer copy of DNS
and BIND. The fourth edition is out, and the second seems to be way
old (hey, even the third edition is quite old).

What you can do is configure your web server to treat requests for
scrlc.org in the same way as lakenet.org. In Apache, this is done
using the ServerAlias directive, either on a virtual host or server
level (depending on your setup). Remember to do the same for your mail
server.

Searching for "virtual hosting" in the documentation for your web and
mail server should turn up some interesting pages. As far as the DNS
goes, unless you are using Dynamic Update (an allow-update{} directive
that says anything but ``none'' either under options{} or the zone
statements for lakenet.org or scrlc.org) you can name the same file
using the ``file'' directive in the zone statement, so you don't have
to maintain two separate copies of the same data. Just be sure to only
use relative names on the left hand side (labels) - and this only
works on a master, not on slave servers.


Michael Kjörling

- -- 
Michael Kjörling  --  Programmer/Network administrator  ^..^
Internet: michael at kjorling.com -- FidoNet: 2:204/254.4   \/
PGP: 95f1 074d 336d f8f0 f297 6a5b 2aa3 7bfd 8a70 e33e

``And indeed people sometimes speak of man's "bestial" cruelty, but
this is very unfair and insulting to the beasts: a beast can never be
so cruel as a man, so ingeniously, so artistically cruel.''
(Ivan Karamazov, in Dostoyevsky's 'The Brothers Karamazov')
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: Public key is at http://michael.kjorling.com/contact/pgp.html

iD8DBQE8u0pwKqN7/Ypw4z4RAtYoAKDczJatf4BypQm81F6tV5BFucn8FQCg/o0a
JBW2KzsSw4Kfxu6XfRf21lo=
=dz9h
-----END PGP SIGNATURE-----




More information about the bind-users mailing list