-1

I need to configure a DNS on a new domain registered on freenom.com as follows

Domain: mydomain.ga

My Server IP: 1.2.3.4

My need is to ask mydomain.ga (1.2.3.4) for a specific subdomain (for example abc.mydomain.ga)

For example, using the command "dig abc.mydomain.ga" (without using the @1.2.3.4 parameter), the dig question must be delivered to mydomain.ga or something like ns1.mydomain.ga (maybe to configure) instead of the default ns0?.freenom.com.

Could you help me to configure it? Here is a starting point with some question marks.

  1. Manage Freenom DNS:
NAME               TYPE TTL     TARGET
                   A    3600    1.2.3.4
                   TXT  3600    this is a test
ns1.mydomain.ga?   A?   3600    1.2.3.4?
?                  ?    3600    ?
?                  ?    3600    ?

2. Management Tools -> Nameservers (2 or more) -> Use custom nameserver (enter below)

Fieldname: Nameserver 1
Value: ???

Fieldname: Nameserver 2
Value: ???

3. Management Tools -> Register glue records (is it needed?) something like...

HOSTNAME             IP Address
ns1.mydomain.ga?     1.2.3.4?

Thanks

Ryuk
  • 1
  • 2
  • If I'm understanding your question correctly, the first problem you have here is you only have one server when it's clearly saying you need 2 or more. I would question the need for running your own DNS server(s) however. If you get this basic service wrong, nothing else for your domain will work at all. Just use Freenom's DNS that they've provided unless you have a real need. If you do have a real need that prevents you from using the existing service, it would be helpful to include that in the question for context. –  May 08 '20 at 15:58
  • It's for test purposes only, so no need to configure a web server or anything else. I would try to simulate catching the subdomain prefix string "abc" listening with tcpdump on the server, when the client invokes a dig command like "dig abc.mydomain.ga" (manually testing what tools like iodine do) – Ryuk May 08 '20 at 16:36

2 Answers2

0

It looks like Freenom provides a DNS service, then you don't need to configure custom nameservers or glue records.

Then all you need is an A record for abc.mydomain.ga, if it's hosted at 1.2.3.4.

NAME               TYPE TTL     TARGET
@                  A    3600    1.2.3.4
abc                A    3600    1.2.3.4

A slightly more improved way is to do it like this:

NAME               TYPE  TTL     TARGET
@                  A     3600    1.2.3.4
webserver          A     3600    1.2.3.4
abc                CNAME 3600    webserver.mydomain.ga
www                CNAME 3600    webserver.mydomain.ga

That way you only need to create a single A record for your web server, and then point all other names as CNAMEs to that record. It's a bit tidier, since if you ever need to move your web server you don't need to change all records, just the single record.

The @ record at the start is for the root of the domain, aka. if you type just mydomain.ga into your web browser. It can't be a CNAME, so you still need to add an A record for that, if you want to use it.

Stuggi
  • 3,366
  • 4
  • 17
  • 34
0

I don't think that it's the best choice to choose a FQDN from a domain as nameserver of that same domain. Let's imagine what will happen if the domain expires just for one day... If I were you, I would just use Freenom DNS to make A record pointing to MY IP

@    IN NS ns01.freenom.com
@    IN NS ns02.freenom.com
@    IN NS ns03.freenom.com
@    IN NS ns04.freenom.com

ns.mydomain.ga IN A 1.2.3.4

Then for next domains,let's say (newdomain.ga), I can do this:

@ IN NS mydomain.ga