S
S
Sharov Dmitry2015-07-20 10:28:21
css
Sharov Dmitry, 2015-07-20 10:28:21

Set up your own dns server?

Hello.
Actually a subject here in what.
There is a server in germany and vds russia and i plan to rent it in vds usa. I would like to raise my own dns server on vdees, in order to throw fluff on myself and have my own ns ala ns1.mydomain.ru and ns2.maydomain.ru
As far as I understood this issue, I realized that I should configure it as follows.
1) In the domain control panel in the delegation section for the maydomain.ru domain, register ns1.mydomain.ru and ip vds which is in the USA, ns2.mydomain.ru and ip vds which is in Russia
2) Configure bind on vds
on both servers / etc/bind/hosts/mydomain.hosts

$ttl 38400
@       IN      SOA     ns1.mydomain.ru. info.mydomain.ru. (
                        2015071901
                        10800
                        900
                        604800
                        3600 )
                       
@       IN      A       xxx.xxx.xxx.xxx
www     IN      A       xxx.xxx.xxx.xxx
 
@       IN      NS      ns1.mydomain.ru.
@       IN      NS      ns2.mydomain.ru.
 
ns1     IN      A       101.220.33.44
ns2     IN      A       11.44.204.34

on the server which is in the USA to the file /etc/bind/named.conf.local
zone mydomain.ru {
    type master;
    file "/etc/bind/hosts/mydomain.hosts";
};

on the server which is in Russia to the file /etc/bind/named.conf.local
zone mydomain.ru {
    type slave;
    file "/etc/bind/hosts/mydomain.hosts";
    masters {
        101.220.33.44;
    };
};

xxx.xxx.xxx.xxx - server ip in Germany
101.220.33.44 - ip vds in the USA
11.44.204.34 - ip vds in Russia
And based on the above, there are questions
1) Do I have the right train of thought when setting up this miracle?
2) How to synchronize records on vds 1 and vds 2
I have not taken any action yet, I am studying the theory

Answer the question

In order to leave comments, you need to log in

4 answer(s)
S
sadieff, 2018-12-05
@kachurinets

Take a closer look at the carousel slick kenwheeler.github.io/slick
there is an example of Slider Syncing

D
Dmitry, 2018-12-04
@dimoff66

How can I make clicking on the thumbnail change the main image?

Make pictures invisible, when clicking on the thumbnail of the corresponding large picture, the visible class is set, which makes it visible, for the rest this class is removed.

M
mureevms, 2015-07-20
@vlom88

1. Yes
2. Not exactly.
On each server, /etc/bind/named.confinsert a line into the file. include "/etc/bind/named.conf.zones";
The contents of the file "/etc/bind/named.conf.zones";on the master will be as follows:

zone "mydomain.ru" {
        type master;
        file "/etc/bind/master/mydomain.ru";
        allow-transfer { 11.44.204.34; };  // IP адрес слэйв сервера
        allow-query { any; };
        notify yes;
};

The content of the file "/etc/bind/named.conf.zones";on the slave :
zone "mydomain.ru" {
        type slave;
        file "/etc/bind/slave/mydomain.ru";
        masters { 101.220.33.44; };  // IP адрес мастер сервера
        allow-query { any; };
};

On the wizard, create a zone file/etc/bind/master/mydomain.hosts
$TTL    1d
@       IN      SOA     mydomain.ru. info.mydomain.ru. (
                2015072000      ; Serial
                3600                  ; Refresh [1h]
                600                    ; Retry [10m]
                1209600            ; Expire [14d]
                36000   )            ; Minimum TTL [1h]
@         IN      A       xxx.xxx.xxx.xxx
www     IN      A       xxx.xxx.xxx.xxx
@         IN      NS     ns1.mydomain.ru.
@         IN      NS     ns2.mydomain.ru.
ns1       IN      A       101.220.33.44
ns2       IN      A       11.44.204.34

Pay attention to 2015072000 - the serial number of the zone. Each time the zone is changed, the number must also change.
On the slave, simply create a directory /etc/bind/slave, the zone file will be created by itself when the server is notified. If it doesn't work, see the link at the end.
They are synchronized by the command on the master
And yet, if there are incomprehensible errors on the slave, then look at this note .

M
Max, 2015-07-20
@MaxDukov

synchronize themselves - the slave will take the zone from the master.
the rest is very similar to the truth.
I only strongly advise you to first raise both DNSs, check that they have come to life - and only then change the domain binding to them.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question