Presentation is loading. Please wait.

Presentation is loading. Please wait.

Web Server Administration Chapter 4 Name Resolution.

Similar presentations


Presentation on theme: "Web Server Administration Chapter 4 Name Resolution."— Presentation transcript:

1 Web Server Administration Chapter 4 Name Resolution

2 Overview Understand the domain name service (DNS) Identify the components of DNS Configure zone files Install and configure DNS in Linux Understand name resolution in Windows Install and configure DNS in Windows 2000 and 2003 Troubleshoot DNS Use WINS to resolve computer names in Windows

3 Name Resolution Converting a URL to the IP address Also called Address Resolution DNS – Domain Name Server Converts URL to IP address Converts IP address to URL

4 Understanding the DNS DNS is most known as an Internet wide service Goal is to decentralize administration Local DNS servers keep track of local IP addresses Unknown addresses use a forwarder – a public DNS server to find IP address IP addresses are cashed locally based on Time To Live (TTL)

5 Understanding DNS Local DNS servers manage local domain namespace Root DNS servers – control top level domains DNS database is an inverted tree

6 DNS Namespace DNS hierarchy naming system Root level Top level (TLD) Second level (SLD) Subdomains/hosts

7 Domain Namespaces The root level domain is "." Significant in creating DNS files Top-level domains include com, org, fr Second-level domains are often owned by companies and individuals microsoft.com, edinboro.edu A subdomain is a further division of a second- level domain For edinboro.edu, there is cs.edinboro.edu

8 Top-Level Domains First seven: com, edu, gov, mil, net, org, in-addr.arpa Others added over the years TOP Level Domains

9 Second Level Domains Second-level domains, such as spidermonkey.com have control over naming within their domain. SLD is a registered domain name with Top level domain registry.

10 Sub-domains Create hosts such as www, ftp, bb We could create subdomains such as csci325 csci325.cs.edinboro.edu Fully qualified domain name (FQDN) – name that absolutely identifies a computer. Ends in a period to indicate absolute vs relative. csci325.cs.edinboro.edu.

11 Host Names The first portion of a URL is typically a host name Not the same as the “name” of the computer Many hosts can be associated with the same Web server

12 How DNS Works

13 DNS System Components Name server – also known as DNS server supports name-to-address and address-to-name resolution Name resolver – also called DNS client Can contact DNS server to lookup name Used by browsers, e-mail clients, and client utilities such as ping

14 DNS System Components Two categories of DNS servers – 1. Primary and secondary servers store the host names for a specific domain 2. Caching and forwarding servers search the Internet for host names Root server (for TLD) contacted by the caching and forwarding server Root Servers

15 Primary and Secondary Servers Primary Server – master server Defines the hosts for the domain Maintains the database for the domain (DNS Zone) It has authority for the domain Secondary Server – slave server Retrieves data from primary server at regular intervals Provides fault tolerance and load distribution Required for Internet domains

16 Primary and Secondary Servers If you use DNS, you will often work with your ISP simplest environment: the ISP will have both the primary and secondary DNS servers You contact them for changes You can also split the servers ISP has primary, you have secondary You have primary, ISP has secondary

17 Resolve Host Names Caching Server Resolves host names Caches (saves) the results Automatically installed when DNS is installed No more configuration necessary Forwarding Server Caching server that has access to the Internet and forwards traffic from other caching servers

18 Caching and Forwarding Servers

19 DNS server summary Primary and secondary servers are accessed by users on the Internet to determine IP addresses of your domain Caching and forwarding are accessed by your users to determine IP addresses of hosts on the Internet

20 Zone Files for Primary and Secondary DNS Server Records that specify the hostnames in your domain and their IP addresses When you register a domain name you must provide primary and secondary DNS server. ISP could control this and would provide a way to edit the zone files You could control it and then configure files yourself.

21 Zone Files for Primary and Secondary DNS Server All systems in your network must have TCP/IP configuration with IP address of primary DNS server Can also have IP address of secondary DNS server (could be ISP)

22 Zones Domain is divided into zones Data for each zone is stored in a zone file Small domains are divided into one zone Large organizations (such as IBM) with many subdomains can be divided into separately maintained zones Each zone typically has a separate DNS

23 Zones There must be one primary DNS server in each zone (plus a secondary server) Each zone can have multiple secondary DNS servers

24 Zone File Configuration Forward Lookup These zones contain entries that map names to IP addresses Reverse Lookup These zones contain entries that map IP addresses to names

25 Common DNS Records DNS recordFunction Address (A)Associates a host to an IP address. Canonical name (CNAME) Creates an alias for a specified host. Internet (IN)Identifies Internet records; precedes most DNS record entries. Mail Exchanger (MX) Identifies a server used for processing and delivering e-mail for the domain. Name server (NS)Identifies DNS servers for the DNS domain. Pointer (PTR)Performs reverse DNS lookups. Resolves an IP address to a host name. Start of Authority (SOA) Identifies the DNS server with the most current information for the DNS domain.

26 BIND BIND - Berkley Internet Name Daemon Carries out the DNS translation Bind documentation files Need to install BIND Connect to the internet yum –y install bind bind-utils

27 DNS Configuration in Linux /etc/named.conf describes the files that configure the zones There are two primary files that it describes (saved in /var/named/) Forward lookup is described by named.zimmer.edu It has the host names and how to handle e-mail Reverse lookup is described by named.0.168.192 Can be necessary for e-mail (SMTP) and security programs

28 /etc/named.conf Creating a DNS for the zimmer.edu domain Default setup is for localhost 127.0.0.1 In named.conf add the following line zone “zimmer.edu" { type master; file “named.zimmer.edu”; }; This allows zimmer.edu to be resolved by /var/named/name.zimmer.edu There can be multiple domains in a single named.conf file

29 /etc/named.conf Also, we can add the following line zone “0.168.192.in-addr.arpa” IN { type master; file “named.0.168.192”; }; This allows for reverse lookup for the domain It uses all or part of the 192.168.0.0 network

30 /etc/named.conf options { directory “/var/named”; recursion yes; allow-recursion { 192.168.0.0/24; }; allow-query {“localhost”; 192.168.0.0/24; }; }; zone "zimmer.edu" IN { type master; file "named.zimmer.edu"; }; zone "0.168.192.in-addr.arpa" IN { type master; file "named.0.168.192"; };

31 /var/named.zimmer.edu $TTL 2d @ IN SOA ns.zimmer.edu. admin.zimmer.edu. ( 2015010900 ; Serial 3h ; Refresh 1h ; Retry 1w ; Expire 1d ) ; Minimum zimmer.edu. IN NS ns.zimmer.edu. zimmer.edu. IN A 192.168.0.101 zimmer.edu. IN MX 10 mailserver1.zimmer.edu. ns.zimmer.edu. IN A 192.168.0.101 www IN CNAME ns.zimmer.edu. www.support IN CNAME ns.zimmer.edu. mailserver1.zimmer.edu. IN A 192.168.0.201

32 named.0.168.192 $TTL 2d @ IN SOA ns.zimmer.edu. admin.zimmer.edu. ( 2015010912 ; Serial 3d ; Refresh 1h ; Retry 1w ; Expire 1d ) ; Minimum @ IN NS ns.zimmer.edu. 101.0.168.192.in-addr.arpa. IN PTR ns.zimmer.edu. 201.0.168.192.in-addr.arpa. IN PTR mailserver1.zimmer.edu.

33 Starting DNS in Linux To start DNS /etc/rc.d/init.d/named start To restart DNS /etc/rc.d/init.d/named restart To stop DNS /etc/rc.d/init.d/named stop Make DNS start when you boot Linux Add the command to start DNS to /etc/rc.d/rc.local

34 Configuring Client DNS in Linux Modify /etc/resolv.config The following line directs the client to use the DNS server at 192.168.0.100 nameserver 192.168.0.100 The following line associates this computer with the zimmer.edu domain domain zimmer.edu

35 Troubleshooting DNS - ping ping displays name resolution even if the computer cannot be contacted

36 Troubleshooting DNS nslookup nslookup can display information from the DNS server

37 Troubleshooting DNS dig – available on Linux

38 Summary DNS is an application that translates names to IP addresses and IP addresses to names Organized in a hierarchical structure Servers come in many forms: primary, secondary, caching, forwarding To configure DNS, set up a forward and reverse zone lookup file Use ping, nslookup, and dig to troubleshoot DNS


Download ppt "Web Server Administration Chapter 4 Name Resolution."

Similar presentations


Ads by Google