Domain Name System (for Linux)
Apa itu DNS? Sebuah protokol layer 7 yang berisi database records (domain +ip) yang bertugas memappingkan ip dengan hostname (domain name) yang diminta client.
DNS Host di Internet menggunakan alamat IP sebagai identitas ex: 202.95.158.17 Numeric ID tidak human friendly Alphanumeric lebih mudah diingat
Mengapa perlu DNS? Perlu skema pemetaan antara IP dengan nama Pada awalnya menggunakan file
Hosts file tidak praktis Network berkembang, makin sulit update database Solusi: menggunakan DNS RFC 1034 dan 1035 Port 53
Primary Purpose Resolve hostnames to IP addresses www.planeted.net 209.175.170.14 Resolve IP addresses to hostnames 209.175.170.14 www.planeted.net
Cara kerja DNS Hirarki proses Database distribution
Terminologi Terms Domain – a collection of records with a contiguous namespace mydomain.com Subdomain – a collection of records with a contiguous namespace that are hierarchically beneath another domain newyork.mydomain.com cincinnati.mydomain.com Zone – a collection of records that comprise a DNS domain Name Server or DNS Server A server capable of either answering queries for records it owns or answering queries on behalf of DNS clients, or both.
Terminologi lanjutan Terms (continued) Record – either a forward or reverse name mapping “A” Record – Maps hostname to IP Address www.planeted.net. 209.175.170.14 “CNAME” Record – Maps an alias to a hostname www.planeted.net. redmond.jeffneddie.com. PTR Record – Maps an IP address to a hostname 209.175.170.14 redmond.jeffneddie.com. MX Record – Defines a mail exchanger for a host or domain MX mymailserver.mydomain.com. SOA Record – Start of Authority – contains a list of authoritative name servers, TTL values, etc. SOA mydomain.com. NS Record – Lists authoritative name servers for a domain NS mydnsserver.mydomain.com. SRV Record – Maps a service to a hostname LDAP mydc.mydomain.com.
Root DNS Server edu DNS Server Org DNS Server Com DNS Server
DNS name space Top Level Domain Second Level Domain Generic (com, edu, net, biz, org dll) Country code ( id, au, my, jp, sg dll) Second Level Domain
DNS name space Second level domain: co.id ac.id or.id Dll
Server dan client Name server Resolver (client) Menyimpan/mengatur domain name Melayani permintaan dari client Resolver (client)
Resolver Client part of DNS Trigger DNS query Bagian dari OS
Name Server Authoritative DNS Server DNS Server Organisasi, melayani mapping hostname ke IP yang ada di org tsb Di kelola oleh org tsb atau ISP
Name Server Local Name Server Dimiliki oleh setiap ISP Default name server Jika sebuah host memilik DNS query, query tsb dikirim ke name server lokal
DNS Name Resolution Iterative (request perulangan sampai kondisi terpenuhi) Recursive (request sekali, yang penting kondisi terpenuhi)
Iterative
Recursive Request it.intel.com Root name server Name server for .com client name server for intel.com name server for it.intel.com