# How to make a nameserver?

## InVekz

hiya!

How to make a nameserver?

Do i need anything special?

Any special agreement with someone?

Is it hard to set up a name server on a gentoo?

Got any info on how to do this?

Any disadvantages is running one?

Anything else?  :Smile: 

thanks !

----------

## steveb

 *InVekz wrote:*   

> hiya!
> 
> How to make a nameserver?
> 
> Do i need anything special?
> ...

 

setting up a name server is easy as 1-2-3 and you don't need a special agreement with anyone, as long as you don't want to put that dns server on the inet and handle internet domains.

when you want to be able to use it as a dns for inet domains, then you need serval things to do, wich is diffrend from country to country (mostly it is the same, just you need to talk/write with diffrend ppl).

cheers

SteveB

----------

## HogRider

First, decide what you want your nameserver to do.  Are we talking about a caching nameserver (stores names you've already resolved), a private, internal DNS, or a public DNS server?  I do caching & internal DNS.

Once you've decided what to do with it, you'll need to decide which 'named' to use.  Do you want the ISC Bind? v4.x or v8.x? djbdns? others?  Personally, I use the djbdns.

Unless you're setting up a public DNS, no 'agreements' are necessary.  If you're hosting your own public namespace, you'll need to update your domain records with your public, static IP as the authoratative NS.

With regards to documentation, it's everywhere.  Once you've decided which software you want to use, we can point you in the right direction.

Finally, disadvantages.  None with regard to caching or internal NS.  If you're looking to host a public NS, you'll be responsible for uptime, security, etc.  I wouldn't recommend it at this time due to inexperiance.

Mike

----------

## InVekz

Hiya thx for quick respond  :Smile: 

Iv read  a bit on linuxdocs.org on dns howto.

They refer to bind(named) 9.2.2 which I have installed aswell now. Should i use another?

I want a nameserver because currently the ns server im using for my domains is not accessiable for me 24/7 regarding small corrections if i want to change some records. I know there are other services around but i rather use the local one i use now or even better a local one on my own machine. 

So when i configured a nameserver where i have registered the domains i would point these to my nameserver and then make diffrent records such as foo.domain.com also i would like to be able to forward foo2.domain to someone else.

So then i would need to use public ns option and this would both hard and needing special agreements etc?

Am i so strongly advised not to proceed?

edit:

i also read this now: [url] http://www.siliconvalleyccie.com/dns-static.htm[/url]

And by this howto it seems fairly easy and also i see nothing about agreements with someone else?

----------

## InVekz

I also spooke to a friend and he said he ran a ns without agreements just fine  making his own records for everyone to use etc..

----------

## InVekz

Hiya again

I have set  up one primary and one secondary ns server. They work well transfering zones etc.

However i created a CNAME record but it doesnt appear

I think this is caused by:

1. My domain is first pointed to my old ns server and then pointed to my own new ns server, even thou i think iv pointed everything from the old this might be the problem it using the old ns server as the ns.

domain register -> old ns -> new ns <-> slave ns

Sounds in my head that this isnt possible.

2. I need to wait some time before the CNAME takes effect

3. Im not having any agreement but iv heard it wasnt needed.

To solve this ill first wait 24 hours and see what happens then ill probably change the domain to point directly to the new ns as it should. However why i dont want to do this is because if this doesnt work then my mail etc will get downtime  :Sad: 

Any info on what the problem probably is?

thx!

----------

## InVekz

hmm ok i have registered a test domain and when registering it to my new ns servers i got an error telling me those ns server werent in the register.

Does this mean i need to get some special agreement or does this mean my ns servers arent configured correctly?

----------

## r0cket-

 *InVekz wrote:*   

> hmm ok i have registered a test domain and when registering it to my new ns servers i got an error telling me those ns server werent in the register.
> 
> Does this mean i need to get some special agreement or does this mean my ns servers arent configured correctly?

 

No offense, but this is pretty far outside of anything Gentoo-related. You might try contact the support department at whatever company you used to register the domain, or perhaps try finding a mailing list or user forum for whatever nameserver application you're using.

----------

## InVekz

Well ya im looking into other ways aswell i just like this community, alot people know things like this here. For ex they guys above seemed to know a bit about this.

----------

## fatcat.00

Can you post any hard information?  If the DNS is Internet-reachable please post the domain name you are trying to get working.

You say you registered a domain.  I assume you also gave your registrar (Network Solutions, Register.com etc.) at least *one* DNS server that is authoritative for you domain.  Is that so?

If that is so, then that server *must* be authoritative for the domain you registered.  To figure that out, do this:

```
 # dig yourdomain.com soa
```

The output should read something like:

```
.

.

.

;; AUTHORITY SECTION:

youdomain.com.   900   IN   NS   ns1.yourdomain.com.

.

.

.
```

If the "Authority Section" doesn't look familiar to you, then your registrar probably doesn't have the correct information about your domain.

It is quite possible that I didn't understand your question, as it seemed to be strung out over several messages...if you still need help, please summarize the issue you are having again and provide as much info as possible.

----------

## InVekz

Hiya 

I already have a mydomain.com pointing towards my jobs ns. Now i bought a  

mydomain.net but  this time i want to have it pointing onto my own ns.

But when i registered the mydomain.net it said:

Request failed validation: Name server  mydomain.com  is not found at the

registry

same for the second ns

The ns adress i handed to them were only the dns point from my jobs ns pointing towards my computer like:

register -> jobs ns -> www.mydo... mail.mydom.. and also mydomain.com to my computer. So i thought it would be possible to just use the dns i had pointed.

Hence this didnt work i have now used a option available on my domain register configuration:

Create Name Server Host Records

This option should only be used by experienced users. It allows you to create Name Server host records based on this domain name.

Inside that option i can set up something.mydomain.com pointing to an ip so iv set up ns and ns2 pointing to my two ns server. I hope this will mean that my ns will show up in their register.

If I do a dig on mydomain.com that is already registered and pointing to my jobs ns i of course get their ns. If i dig mysoontobee.net domain that i have registered but said its pointing to a not registered ns i will see ns.mydomain.com BUT this is locally on the two ns servers meaning the ns.mydomain.com doesnt exist to the outside world. im hoping that when i made those new nameserver host records for ns, ns2 they will show up and work.

Note: dig as in the bind tool. Also before when i first registered I used two other dns mydomain.com and bla.mydomain.com that are pointing towards the computer from my jobs ns. However these are not any registered ns at my register but i thought that would work anyway.

So im now hoping that that option will make my servers the register or likewise to let me use em as ns servers. Or am i totally wrong about all this?

----------

## InVekz

;; QUESTION SECTION:

;slynix.net.                    IN      SOA

;; ANSWER SECTION:

slynix.net.             259200  IN      SOA     ns.slynix.com. martin.slynix.com. 200304294 28800 7200 2419200 86400

;; AUTHORITY SECTION:

slynix.net.             259200  IN      NS      ns.slynix.com.

in the named.conf i have notify no; on all zone maybe thats wrong? thought that should only have to do with the updating of slaves right?

----------

## RagManX

Well worth the money.

RagManX

----------

## fatcat.00

Yup the notify is just for slaves to tell them when updates to a zone are available.

Your SOA looks correct locally, so I think you have BIND setup correctly.  The whois listing for slynix.com yields:

# whois -h whois.tucows.com slynix.com

Registrant:

 REAB

 Skanegatan 37A

 Gothenburg, VG 41252

 SE

 Domain name: SLYNIX.COM

 Administrative Contact:

    Roggentin, Martin  martin@roggentin.com

    Skanegatan 37A

    Gothenburg, VG 41252

    SE

    +4631167324

 Technical Contact:

    Roggentin, Martin  martin@roggentin.com

    Skanegatan 37A

    Gothenburg, VG 41252

    SE

    +4631167324

 Registration Service Provider:

    UKReg, domains@fasthosts.co.uk

    +44 1452 541252

    +44 1452 538485 (fax)

http://www.ukreg.com/

 Registrar of Record: TUCOWS, INC.

 Record last updated on 20-Apr-2003.

 Record expires on 20-Apr-2004.

 Record Created on 20-Apr-2003.

 Domain servers in listed order:

    NS.REAB.SE   

    NS2.REAB.SE   

Whereas the whois listing for slynix.net yields:

# whois -h whois.tucows.com slynix.net

Can't get information on non-local domain SLYNIX.NET

This tells me that the domain isn't registered properly with tucows.  I *think* this is what you were trying to say before, but I kept getting thrown off that because you kept bringing your BIND config into the picture.

I believe I now understand the source of your confusion.  The registration process is separate from the configuration of BIND.  In order for the domain to resolve correctly for the Internet, you *must* get your registration done first.  

To get your new domain using your home DNS server, go to your registrar (tucows) and instead of putting in a name for your DNS server, just put the IP address.  I think that will work.

I hope I understand the problem...if not, tell me where I am going wrong  :Smile: 

-- Fatcat

----------

## InVekz

Thx for reply  :Smile: 

Well your right about several things  :Wink: 

However slynix.com is pointed to my jobs ns and all that work correctly

I recently tried to register slynix.net, it got register but as the supplied ns server was not in the registry it wouldnt complete the total registration so iv e-mailed them regarding that problem because i cant access the domain to change the ns info if the registration process isnt done. And it seems sense the ns are invalid the process will not end. An endless loop  :Wink: 

About entering the ip of the ns: When i registered the domain it said:

This domain will be hosted by another ISP using the DNS servers given. (Specify the host name of each DNS server, not the IP address. eg: ns1.dnsserver.co.uk)

ns1:

ns2:

Maybe i could try to enter ip anyway.

So my problems are instead a few now however some should be solved soon.

So lets see if i got this right..

In order to set up my own ns and own domain i could do the following way:

set up 2 computer running bind on static ip

Register a domain

chooce the nameservers for the domain to be my computers ip adresses

Right..?

----------

## InVekz

Ah well i tried to change a working domain that uses a working ns to one of my new ns servers ip and i got the this:

The Name Servers entered do not appear to be valid.

Please ensure the names entered contain only alphanumeric characters and are not an IP Address or contain "http://"

so it seems i really cant enter the ip  :Sad: 

edit:

i tried to put in www.slynix.com as ns but it didnt work but then i thought what the heck and tried ns.slynix.com and it work  :Razz: 

So now i only need to get my new domain registration bug fixed and i think ill be all set  :Smile: 

----------

## fatcat.00

Right.  First, you are correct in that you must have a working resolvable (this is the correct technical term to use;  "registered" means something different  :Smile:  ) name server in order to register a domain *unless* you can use an IP address.

Since ns.slynix.com is a resolvable hostname, tucows allowed you to point to it for slynix.net.  

I am surprised that tucows will not allow an ip address, as you get in a circle unless you have a *name* to use.  The name must be in an already working domain, and can't be part of the domain you are trying to register.

Obviously, the very first name server ever registered on the internet *had* to be done via its IP.  For tucows to not support this doesn't say much for them.  :Sad: 

Now that you have the domain registered, you *should* be able to point it to where ever you want.  That will be an additional request with tucows.  You will want to change the authoritative dns from "ns.slynix.net" to whatever IP address of the server is.  

This will make slynix.net completely separate and autonomous from slynix.com.  If you don't have a static IP, don't despair.  You can always use a dynamic DNS service like http://www.dyndns.org if your DNS server gets a DHCP address from your ISP.

As a general rule, if you are trying to setup a domain you have two choices:

1) Make the authoritative DNS be an IP address

  or

2) Make the authoritative DNS be a name (ns.slynix.net), but this option *requires* a working, resolvable DNS server to work.

BTW, "Authoritative" just means "the server that is really the chief DNS for this domain."

I think you are all fixed now, but as someone already suggested, the O'Reilly DNS book is really great.  Its how I learned DNS (plus a couple years as hostmaster for a large American telephone company).

Good Luck!

----------

## InVekz

Ah well im not sure on how tucows themself handles the ns part etc because i have bought my domains from elsewere. I however think they buy theyr domains from tucows

I changed the working domains second ns to ns.slynix.com and it worked, check www.opensrs.com and do a whois on slynix.com

However now when i thought it worked i registered another domain at their place with ns.slynix.com and it said it was valid so now i have two domains in the endless loop lol. I hope they will fix this bug for me so I can change to the right ns soon.

I think this has something to do with ns.slynix.com not being global yet so someone in the register process couldnt see the ns. When i just changed them on the existing one it probably somehow saw that i had made that record etc.

----------

## InVekz

Hey btw anyone wanna share some zone files? Iv set up a few and looked at a few. However i cant just stop getting a better zonefile each time I look at a new zone file

Share your zone files!  :Smile: 

one of mine looks like this:

```

$TTL 3D

@       IN      SOA     ns.slynix.com. martin.slynix.com. (

                        200304301       ; serial#

                        8H            ; refresh, seconds

                        2H            ; retry, seconds

                        4W            ; expire, seconds

                        1D )          ; minimum, seconds

;

                NS      ns.slynix.com.  ; Inet Address of nameserer

                NS      ns2.slynix.com.

                MX      10 mail         ; Primary Mail Exchanger

                TXT     "Martin.Roggentin, DNS guru"

;

localhost       A       127.0.0.1

gw              A       194.23.250.1

ns              A       194.23.250.154

dark            A       212.159.79.241

vex             A       194.23.250.142

slynix.com.     A       194.23.250.154

www             CNAME   slynix.com.

test            CNAME   slynix.com.

mail            A   194.23.250.154

murra           CNAME   ns

```

----------

