SlideShare a Scribd company logo
1 of 12
DNS Server
CONCEPT AND CONFIGURATION (UBUNTU 14.04)
1
Agenda
1. What is DNS server?
2. What is Name server?
3. What are zones – forward and reverse zone?
4. What are master dns server and slave dns server?
5. What are the DNS server records type?
6. Setup DNS server master and slave on Ubuntu 14.04 64bit VPS.
2
What is DNS server?
A dns server is a computer name resolution service which helps to recognize computers by name
over ip network.
A dns server resolves hostname to ip address and ip address to hostname.
Without a name resolution server i.e a dns server it is not possible to surf a website by its human
readable name.
A computer communicates with another computer by identify their address and understands
only ip address. Hence a dns server works as a translator between human to computer.
Some example are :
Google public dns server
8.8.8.8
8.8.4.4
3
What is Name server? 4
A Name server is actually the dns server’s name.
To host a website or to resolve an address of a computer over internet you need to register the dns name
with a domain registrar.
You also need to register your dns server as name server to your domain registrar.
After the above two steps you need to configure DNS server as per name server registered and then you
can create record to your own dns server.
At least minimum two name servers required to register ( can have same wan IP)
Example :
Domain registrar : godaddy , bigrock, znetlive etc.
I purchase a domain name mevijay.in from bigrock.
I have two Ubuntu VPS having ip 158.85.163.100 & 158.85.163.103 hence I register both vps as name
server ns1.mevijay.in & ns2.mevijay.in
I also updated ns records from domain registrar to use as my vps ns1.mevijay.in and ns2.mevijay.in
So all the name resolution query will be forwarded to my dns server (name server) from my domain
registrar.
What are zones? 5
DNS server has two types of zones
1. forward zone
2. reverse zone
A forward zone resolves host name into ip address and holds record types – A , NS, MX, CNAME,
AAA, SPF.
A reverse zone resolves ip address to hostname and holds only PTR record type. If I need to
know an ip address is belongs to which hostname or dns name then it can be lookup by reverse
zone. Reverse zone is mandatory for mail server. If you have a mail server then a PTR records
corresponding to mail servers hostname must be entered as wel as mx record and A record also
must be entered in forward zone.
DNS server Types: 6
Two types of dns server mainly used.
1. Primary or master dns server
2. secondary or slave dns server
Master dns server is nothing but as its name it’s a master name server and holds both zone and
records.
Slave dns server works as secondary dns server and sync with master dns server for records. So
you do not need to update a slave dns server records and can simply restart the service when
a master dns server records got updated.
DNS server record types: 7
A DNS server consists two zones forward and reverse, depending upon the zone we have
following main record types-
Forward zone records:-
A
MX
NS
CNAME
Reverse zone record:-
PTR
Understanding forward zone records: 8
A record:-
an A record resolves hostname to ip address and is main record type to recognize a computer or
website by its name.
e.g. mail IN A 192.168.1.108
MX record:-
mx record is used to point a host name as mail exchanger server i.e. mail server. This record used to
tell network that pointed hostname is a mail server of domain.
e.g. @ IN MX 10 mail.mevijay.in.
Above example telling you that mail.mevijay.in A record or hostname is the mail server for domain
mevijay.in having mail priority 10.
NS record:-
ns record is used to point for your dns server (name server)address and is usually dns server itself.
e.g. @ IN NS ns1.mevijay.in.
Above example shows @ symbol which means zone i.e. mevijay.in for my case having name server is
ns1.mevijay.in
CNAME record:-
This also knows as alias of a domain name. perhaps it is quite easy to understand for a website that
opens with www and without. So we create a cname record of domain as www and it points on the
same hostname or same ip whether we use with www or not.
e.g. www IN CNAME mevijay.in.
Setup master dns server:- 9
# apt-get update
# apt-get install bind9 dnsutils –y
# cd /etc/bind
# mkdir zones ( to hold all zone records files)
# vim named.conf.default-zones
Remove all the lines and make changes like bellow
10
Save file and exit.
# cp db.local zones/mevijay.in
# vim zones/mevijay.in
Make changes for your domain and enter required records example in bellow snap. Save and exit
# service bind9 restart
Setup slave dns server:- 11
# apt-get update
# apt-get install bind9 dnsutils –y
# cd /etc/bind
# mkdir zones ( to hold all zone records files)
# vim named.conf.default-zones
Remove all the lines and make changes like bellow. Here we have given ip of our master server to sync
records.
# touch zones/mevijay.in
# service bind9 restart
Thank you!
VIJAY SHARMA
MAIL: SHARMAVIJAY86@GMAIL.COM
12

More Related Content

What's hot

Presentation on dns
Presentation on dnsPresentation on dns
Presentation on dns
Anand Grewal
 

What's hot (20)

Course 102: Lecture 20: Networking In Linux (Basic Concepts)
Course 102: Lecture 20: Networking In Linux (Basic Concepts) Course 102: Lecture 20: Networking In Linux (Basic Concepts)
Course 102: Lecture 20: Networking In Linux (Basic Concepts)
 
Users and groups in Linux
Users and groups in LinuxUsers and groups in Linux
Users and groups in Linux
 
Linux basics
Linux basicsLinux basics
Linux basics
 
Linux fundamentals
Linux fundamentalsLinux fundamentals
Linux fundamentals
 
Introduction to linux ppt
Introduction to linux pptIntroduction to linux ppt
Introduction to linux ppt
 
Unix/Linux Basic Commands and Shell Script
Unix/Linux Basic Commands and Shell ScriptUnix/Linux Basic Commands and Shell Script
Unix/Linux Basic Commands and Shell Script
 
An Introduction To Linux
An Introduction To LinuxAn Introduction To Linux
An Introduction To Linux
 
What is active directory
What is active directoryWhat is active directory
What is active directory
 
Window server editions
Window server editionsWindow server editions
Window server editions
 
RPM (Red Hat Package Manager)
RPM (Red Hat Package Manager)RPM (Red Hat Package Manager)
RPM (Red Hat Package Manager)
 
Dns ppt
Dns pptDns ppt
Dns ppt
 
Presentation on dns
Presentation on dnsPresentation on dns
Presentation on dns
 
Linux Basic Commands
Linux Basic CommandsLinux Basic Commands
Linux Basic Commands
 
Introduction to Ansible
Introduction to AnsibleIntroduction to Ansible
Introduction to Ansible
 
Active Directory Trusts
Active Directory TrustsActive Directory Trusts
Active Directory Trusts
 
Access control list acl - permissions in linux
Access control list acl  - permissions in linuxAccess control list acl  - permissions in linux
Access control list acl - permissions in linux
 
Linux User Management
Linux User ManagementLinux User Management
Linux User Management
 
Linux command ppt
Linux command pptLinux command ppt
Linux command ppt
 
Nfs
NfsNfs
Nfs
 
Linux
Linux Linux
Linux
 

Similar to Dns server setup on ubuntu vps (master+slave)

Dns server
Dns serverDns server
Dns server
Muuluu
 
How to configure dns server(2)
How to configure dns server(2)How to configure dns server(2)
How to configure dns server(2)
Amandeep Kaur
 
Session 4 Tp 4
Session 4 Tp 4Session 4 Tp 4
Session 4 Tp 4
githe26200
 

Similar to Dns server setup on ubuntu vps (master+slave) (20)

Linux basics andng hosti
Linux basics andng hostiLinux basics andng hosti
Linux basics andng hosti
 
SFScon 22 - Dashamir Hoxha - Manage your own DNS.pdf
SFScon 22 - Dashamir Hoxha - Manage your own DNS.pdfSFScon 22 - Dashamir Hoxha - Manage your own DNS.pdf
SFScon 22 - Dashamir Hoxha - Manage your own DNS.pdf
 
Dns
DnsDns
Dns
 
Dns server
Dns serverDns server
Dns server
 
Dns server slide(h.m_merajul_hasan)
Dns server slide(h.m_merajul_hasan)Dns server slide(h.m_merajul_hasan)
Dns server slide(h.m_merajul_hasan)
 
Domain Name Service
Domain Name ServiceDomain Name Service
Domain Name Service
 
Dns
DnsDns
Dns
 
DNS and Troubleshooting DNS issues in Linux
DNS and Troubleshooting DNS issues in LinuxDNS and Troubleshooting DNS issues in Linux
DNS and Troubleshooting DNS issues in Linux
 
DNS.docx
DNS.docxDNS.docx
DNS.docx
 
7 understanding DNS
7 understanding DNS7 understanding DNS
7 understanding DNS
 
1. primary dns using bind for a and cname record for ipv4 and ipv6
1. primary dns using bind for a and cname record for ipv4 and ipv61. primary dns using bind for a and cname record for ipv4 and ipv6
1. primary dns using bind for a and cname record for ipv4 and ipv6
 
How to configure dns server(2)
How to configure dns server(2)How to configure dns server(2)
How to configure dns server(2)
 
Nameserver: What Is It And What Does It Do?
Nameserver: What Is It And What Does It Do?Nameserver: What Is It And What Does It Do?
Nameserver: What Is It And What Does It Do?
 
Dns1111111111
Dns1111111111Dns1111111111
Dns1111111111
 
DNSPresentation.pptx
DNSPresentation.pptxDNSPresentation.pptx
DNSPresentation.pptx
 
Dns interview
Dns interviewDns interview
Dns interview
 
DomainNameSystem
DomainNameSystemDomainNameSystem
DomainNameSystem
 
Session 4 Tp 4
Session 4 Tp 4Session 4 Tp 4
Session 4 Tp 4
 
Zone in windows server 2012
Zone in windows server 2012Zone in windows server 2012
Zone in windows server 2012
 
DNS Delegation
DNS DelegationDNS Delegation
DNS Delegation
 

Recently uploaded

Hospital management system project report.pdf
Hospital management system project report.pdfHospital management system project report.pdf
Hospital management system project report.pdf
Kamal Acharya
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
jaanualu31
 
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
HenryBriggs2
 
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak HamilCara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Kandungan 087776558899
 
Introduction to Robotics in Mechanical Engineering.pptx
Introduction to Robotics in Mechanical Engineering.pptxIntroduction to Robotics in Mechanical Engineering.pptx
Introduction to Robotics in Mechanical Engineering.pptx
hublikarsn
 

Recently uploaded (20)

Hospital management system project report.pdf
Hospital management system project report.pdfHospital management system project report.pdf
Hospital management system project report.pdf
 
Introduction to Data Visualization,Matplotlib.pdf
Introduction to Data Visualization,Matplotlib.pdfIntroduction to Data Visualization,Matplotlib.pdf
Introduction to Data Visualization,Matplotlib.pdf
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
 
8th International Conference on Soft Computing, Mathematics and Control (SMC ...
8th International Conference on Soft Computing, Mathematics and Control (SMC ...8th International Conference on Soft Computing, Mathematics and Control (SMC ...
8th International Conference on Soft Computing, Mathematics and Control (SMC ...
 
Electromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptxElectromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptx
 
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARHAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
 
Employee leave management system project.
Employee leave management system project.Employee leave management system project.
Employee leave management system project.
 
Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...
 
Post office management system project ..pdf
Post office management system project ..pdfPost office management system project ..pdf
Post office management system project ..pdf
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and properties
 
School management system project Report.pdf
School management system project Report.pdfSchool management system project Report.pdf
School management system project Report.pdf
 
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
 
fitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .pptfitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .ppt
 
Online food ordering system project report.pdf
Online food ordering system project report.pdfOnline food ordering system project report.pdf
Online food ordering system project report.pdf
 
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak HamilCara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
 
Ground Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth ReinforcementGround Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth Reinforcement
 
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
COST-EFFETIVE  and Energy Efficient BUILDINGS ptxCOST-EFFETIVE  and Energy Efficient BUILDINGS ptx
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
 
Max. shear stress theory-Maximum Shear Stress Theory ​ Maximum Distortional ...
Max. shear stress theory-Maximum Shear Stress Theory ​  Maximum Distortional ...Max. shear stress theory-Maximum Shear Stress Theory ​  Maximum Distortional ...
Max. shear stress theory-Maximum Shear Stress Theory ​ Maximum Distortional ...
 
Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)
 
Introduction to Robotics in Mechanical Engineering.pptx
Introduction to Robotics in Mechanical Engineering.pptxIntroduction to Robotics in Mechanical Engineering.pptx
Introduction to Robotics in Mechanical Engineering.pptx
 

Dns server setup on ubuntu vps (master+slave)

  • 1. DNS Server CONCEPT AND CONFIGURATION (UBUNTU 14.04) 1
  • 2. Agenda 1. What is DNS server? 2. What is Name server? 3. What are zones – forward and reverse zone? 4. What are master dns server and slave dns server? 5. What are the DNS server records type? 6. Setup DNS server master and slave on Ubuntu 14.04 64bit VPS. 2
  • 3. What is DNS server? A dns server is a computer name resolution service which helps to recognize computers by name over ip network. A dns server resolves hostname to ip address and ip address to hostname. Without a name resolution server i.e a dns server it is not possible to surf a website by its human readable name. A computer communicates with another computer by identify their address and understands only ip address. Hence a dns server works as a translator between human to computer. Some example are : Google public dns server 8.8.8.8 8.8.4.4 3
  • 4. What is Name server? 4 A Name server is actually the dns server’s name. To host a website or to resolve an address of a computer over internet you need to register the dns name with a domain registrar. You also need to register your dns server as name server to your domain registrar. After the above two steps you need to configure DNS server as per name server registered and then you can create record to your own dns server. At least minimum two name servers required to register ( can have same wan IP) Example : Domain registrar : godaddy , bigrock, znetlive etc. I purchase a domain name mevijay.in from bigrock. I have two Ubuntu VPS having ip 158.85.163.100 & 158.85.163.103 hence I register both vps as name server ns1.mevijay.in & ns2.mevijay.in I also updated ns records from domain registrar to use as my vps ns1.mevijay.in and ns2.mevijay.in So all the name resolution query will be forwarded to my dns server (name server) from my domain registrar.
  • 5. What are zones? 5 DNS server has two types of zones 1. forward zone 2. reverse zone A forward zone resolves host name into ip address and holds record types – A , NS, MX, CNAME, AAA, SPF. A reverse zone resolves ip address to hostname and holds only PTR record type. If I need to know an ip address is belongs to which hostname or dns name then it can be lookup by reverse zone. Reverse zone is mandatory for mail server. If you have a mail server then a PTR records corresponding to mail servers hostname must be entered as wel as mx record and A record also must be entered in forward zone.
  • 6. DNS server Types: 6 Two types of dns server mainly used. 1. Primary or master dns server 2. secondary or slave dns server Master dns server is nothing but as its name it’s a master name server and holds both zone and records. Slave dns server works as secondary dns server and sync with master dns server for records. So you do not need to update a slave dns server records and can simply restart the service when a master dns server records got updated.
  • 7. DNS server record types: 7 A DNS server consists two zones forward and reverse, depending upon the zone we have following main record types- Forward zone records:- A MX NS CNAME Reverse zone record:- PTR
  • 8. Understanding forward zone records: 8 A record:- an A record resolves hostname to ip address and is main record type to recognize a computer or website by its name. e.g. mail IN A 192.168.1.108 MX record:- mx record is used to point a host name as mail exchanger server i.e. mail server. This record used to tell network that pointed hostname is a mail server of domain. e.g. @ IN MX 10 mail.mevijay.in. Above example telling you that mail.mevijay.in A record or hostname is the mail server for domain mevijay.in having mail priority 10. NS record:- ns record is used to point for your dns server (name server)address and is usually dns server itself. e.g. @ IN NS ns1.mevijay.in. Above example shows @ symbol which means zone i.e. mevijay.in for my case having name server is ns1.mevijay.in CNAME record:- This also knows as alias of a domain name. perhaps it is quite easy to understand for a website that opens with www and without. So we create a cname record of domain as www and it points on the same hostname or same ip whether we use with www or not. e.g. www IN CNAME mevijay.in.
  • 9. Setup master dns server:- 9 # apt-get update # apt-get install bind9 dnsutils –y # cd /etc/bind # mkdir zones ( to hold all zone records files) # vim named.conf.default-zones Remove all the lines and make changes like bellow
  • 10. 10 Save file and exit. # cp db.local zones/mevijay.in # vim zones/mevijay.in Make changes for your domain and enter required records example in bellow snap. Save and exit # service bind9 restart
  • 11. Setup slave dns server:- 11 # apt-get update # apt-get install bind9 dnsutils –y # cd /etc/bind # mkdir zones ( to hold all zone records files) # vim named.conf.default-zones Remove all the lines and make changes like bellow. Here we have given ip of our master server to sync records. # touch zones/mevijay.in # service bind9 restart
  • 12. Thank you! VIJAY SHARMA MAIL: SHARMAVIJAY86@GMAIL.COM 12