实验环境:
RHEL5 DNS Server 1台  IP:10.0.0.114/8
RHEL5 DHCP Server 1台  IP:10.0.0.150/8
Windows 客户端一台
因为只备忘,不是指导作业,固执给出主配置文件<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

DNSServer

/var/named/chroto/etc/named.conf --------à文件修改如下:

key Bhanv {

        algorithm hmac-md5;

        secret QdShv7aM16UxJo7Bb0GYYw==;

};

options {

        listen-on port 53 { 127.0.0.1; any;};

        listen-on-v6 port 53 { ::1; };

        directory       "/var/named";

        dump-file       "/var/named/data/cache_dump.db";

        statistics-file "/var/named/data/named_stats.txt";

        memstatistics-file "/var/named/data/named_mem_stats.txt";

        // Those options should be used carefully because they disable port

        // randomization

        // query-source    port 53;

        // query-source-v6 port 53;

        allow-query     { localhost; any;};

        allow-query-cache { localhost; };

};

logging {

        channel default_debug {

                file "data/named.run";

                severity dynamic;

        };

};

view localhost_resolver {

        match-clients      { localhost;any; };

        match-destinations { localhost;};

        recursion yes;

        zone "yema.com" IN {

        type master;

        file "yema.zone";

        allow-update { key Bhanv;

};

        };

        zone "0.0.10.in-addr.arpa" IN {

        type master;

        file "yema.local";

        allow-update { keyBhanv; };

        };

};

 

DHCP Server

/etc/dhcpd.conf             ------------à文件显示如下:

ddns-update-style interim;

ignore client-updates;

key Bhanv {

        algorithm hmac-md5;

        secret QdShv7aM16UxJo7Bb0GYYw==;

};

zone yema.com.{

      primary 10.0.0.114;  

      key Bhanv;

        }

zone 0.0.10.in-addr.arpa. {

         primary 10.0.0.114;

         key  Bhanv;

}

subnet 10.0.0.0 netmask 255.0.0.0 {

# --- default gateway

#       option routers                  192.168.0.1;

#       option subnet-mask              255.255.255.0;

 

#       option nis-domain               "domain.org";

        option domain-name              "yema.com";

        option domain-name-servers      10.0.0.114;

        option time-offset              -18000; # Eastern Standard Time

#       option ntp-servers              192.168.1.1;

#       option netbios-name-servers     192.168.1.1;

# --- Selects point-to-point node (default is hybrid). Don't change this unless

# -- you understand Netbios very well

#       option netbios-node-type 2;

       range dynamic-bootp 10.0.0.5 10.0.0.7;

        default-lease-time 21600;

        max-lease-time 43200;

#       # we want the nameserver to appear at a fixed address

#       host ns {

#               next-server marvin.redhat.com;

#               hardware ethernet 12:34:56:78:AB:CD;

#               fixed-address 207.175.42.254;

#       }

}

具体怎样做详细看MAN dhcpd.conf 文档
 
客户端验正结果:
 

C:\>hostname

04-13

C:\>ipconfig /renew

Windows IP Configuration

Ethernet adapter VMware Network Adapter VMnet1:

        Connection-specific DNS Suffix  . : yema.com

        IP Address. . . . . . . . . . . . : 10.0.0.7

        Subnet Mask . . . . . . . . . . . : 255.0.0.0

        Default Gateway . . . . . . . . . :

C:\>nslookup

Default Server:  server.yema.com

Address:  10.0.0.114

> ls yema.com

[server.yema.com]

 yema.com.                      NS     server = yema.com

 yema.com.                      A      10.0.0.114

 04-13                          A      10.0.0.7

 www                            A      10.0.0.115

 
 
今天是我人生最难受的一天,想用知识麻醉自己,最后还是在blog上给自己留点东西把,域名用所在学校,表示一种感激吧.