Oracle® ILOM 配置和维护管理员指南(固件发行版 3.2.x)

退出打印视图

更新时间: 2015 年 10 月
 
 

示例:设置 DDNS 配置

本示例介绍了如何设置典型的 DDNS 配置。

假设:

以下假设适用于此 DDNS 配置示例:

  • 存在一个服务器,负责处理 SP 所在网络的 DNS 和 DHCP。

  • SP 网络地址为 192.168.1.0。

  • DHCP/DNS 服务器地址为 192.168.1.2。

  • 从 192.168.1.100 到 192.168.1.199 之间的 IP 地址用作地址池,为 SP 和其他客户机提供地址。

  • 域名为 example.com

  • 不存在现有的 DNS 或 DHCP 配置。如果存在,请参考本示例中的 .conf 文件对现有配置进行更新。


注 - 设置 DDNS 的具体方式取决于站点所使用的基础结构。Oracle Solaris、Linux 和 Microsoft Windows 操作系统都支持提供 DDNS 功能的服务器解决方案。 本示例配置使用 Debian r4.0 作为服务器操作系统环境。

可以使用此处提供的以下步骤和样例文件,进行特定于站点的修改后设置您自己的 DDNS 配置。

  1. 安装 Debian 分发包中的 bind9dhcp3-server 软件包。

    安装 dnsutils 软件包后可以访问 dignslookup 以及其他有用工具。

  2. 使用 dnssec-keygen,生成要在 DHCP 和 DNS 服务器之间共享的密钥,以控制对 DNS 数据的访问。
  3. 创建一个名为 /etc/bind/named.conf 的 DNS 配置文件,其中包含以下内容:
    options {
      directory "/var/cache/bind";
      auth-nxdomain no;    # conform to RFC1035
      listen-on-v6 { any; };
    };
    // prime the server with knowledge of the root servers
    zone "." {
      type hint;
      file "/etc/bind/db.root";
    };
    // be authoritative for the localhost forward and reverse zones, // and for broadcast zones as per RFC 1912
    zone "localhost" {
      type master;
      file "/etc/bind/db.local";
    };
    zone "127.in-addr.arpa" {
      type master;
      file "/etc/bind/db.127";
    };
    zone "0.in-addr.arpa" {
      type master;
      file "/etc/bind/db.0";
    };
    zone "255.in-addr.arpa" {
      type master;
      file "/etc/bind/db.255";
    };
    // additions to named.conf to support DDNS updates from dhcp server
    key server.example.com {
      algorithm HMAC-MD5;
      secret "your-key-from-step-2-here"
    };
    zone "example.com" {
      type master;
      file "/etc/bind/db.example.com";
      allow-update { key server.example.com; };
    };
    zone "1.168.192.in-addr.arpa" {
      type master;
      file "/etc/bind/db.example.rev";
      allow-update { key server.example.com; };
    };
    
  4. 为本地网络添加空区域文件。

    空区域文件的名称应为 /etc/bind/db.example.com/etc/bind/db.example.rev

    复制分发包中提供的 db.empty 文件即可;DNS 服务器将自动更新这些文件。

  5. 创建 /etc/dhcp3/dhcpd.conf 文件,其中包含以下内容:
    ddns-update-style interim;
    ddns-updates      on;
    server-identifier server;
    ddns-domainname   "example.com.";
    ignore client-updates;
    key server.example.com {
      algorithm hmac-md5;
      secret your-key-from-step-2-here;
    }
    zone example.com. {
      primary 127.0.0.1;
      key server.example.com;
    }
    zone 1.168.192.in-addr.arpa. {
      primary 127.0.0.1;
      key server.example.com;
    }
    default-lease-time 600;
    max-lease-time 7200;
    authoritative;
    log-facility local7;
    subnet 192.168.1.0 netmask 255.255.255.0 {
      range 192.168.1.100 192.168.1.199;
      option domain-name-servers 192.168.1.2;
    }
    
  6. 完成上述步骤 1 至 5 后,运行 /etc/init.d 脚本以启动 DNS 和 DHCP 服务器。

    这些服务器处于运行状态后,当已配置 DHCP 的任何新 Oracle ILOM SP 开机时,可使用这些 ILOM SP 的主机名自动访问这些 ILOM SP。如有必要,请使用日志文件、dignslookup 以及其他实用程序进行调试。

参考

有关本示例中使用的 Linux DHCP 和 DNS 服务器的更多信息,请参见 Internet Systems Consortium Web 站点,网址为:http://www.isc.org/