[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: BIND DNS



Hi,

On Wed, 28 Jan 2004, Brian C wrote:

> Hi,
>
> I have a single machine running BIND and Apache. I've never used either
> before. I've just upgraded this box from stable to testing. I have never
> been able to get the web site to show up using its domain name. I can type
> my static IP address into a web browser and it will show up, and I just
> noticed tonight that I can type in nameofmachine.domainname.org and the web
> site will show up. BUT, if I just type www.domainname.org or domainname.org
> then I get NOTHING.
>
> Is it not possible for one and the same machine to be the primary DNS server
> of the website it hopes to serve for? Is this a problem with my domain name
> registrar? (I've been to their site and told them my primary dns is
> nameofmachine.domainname.org and I picked some free service to be the
> secondary dns. This was all months ago.)
>
> Anyone have suggestions? I'm uncertain which config files would be helpful
> and wonder how smart it is to post such files, containing my IP address, to
> a big archived list like this. Thanks for any guidance. I appreciate being
> CC'd.
>
you need to edit the zone files. If I am not mistaken, those files are in
/etc/bind/ . I assume you have edited named.conf and added something like:
// domainname.org naam -> adres
 zone "domainname.org" {
         type master;
         file "/etc/bind/db.domainname";
 };

// domainname.org adres -> naam
 zone "ZZZ.YYY.XXX.in-addr.arpa" {
         type master;
         file "/etc/bind/db.domainname-rev";
 };

where your IP is XXX.YYY.ZZZ.PPP . Then make db.domainname, for example:
; BIND data file for domainname.org

$TTL    86400
@       IN      SOA     ns.domainname.org.      root.domainname.org. (
                        2003021702      ; volgnummer
                        10800           ; Refresh
                        3600            ; Retry
                        3600000         ; Expire
                        86400   )       ; Default TTL
                IN      NS      ns1.domainname.org.
                IN      A       XXX.YYY.ZZZ.PPP
www             IN      A       XXX.YYY.ZZZ.PPP
ns              IN      A       XXX.YYY.ZZZ.PPP
ns1             IN      A       XXX.YYY.ZZZ.PPP
ns2             IN      A       XXX.YYY.ZZZ.PPP


and the db.domainname-rev:
; BIND data file for domainname.org

$TTL    86400
@       IN      SOA     ns.domainname.org.      root.domainname.org. (
                        2002030102      ; volgnummer
                        10800           ; Refresh
                        3600            ; Retry
                        3600000         ; Expire
                        86400   )       ; Default TTL
        IN      NS      ns.domainname.org.
PPP     IN      PTR     domainname.org.

replace PPP with the corresponding value of your IP.

Haven't worked with BIND for a while now, but this is the idea. Consult
the docs for more information.


Greetz,
Sebas

--

English written by Dutch people is easily recognized by the improper use of 'In principle ...'

The software box said 'Requires Windows 95 or better', so I installed Linux.

Als Pacman in de jaren '80 de kinderen zo had be?nvloed zouden nu veel jongeren rondrennen
in donkere zalen terwijl ze pillen eten en luisteren naar monotone electronische muziek.
(Kristian Wilson, Nintendo, 1989)




Reply to: