如何在 Ubuntu 12.04 中設定 DHCPv6 和 DNSv6 配置?

如何在 Ubuntu 12.04 中設定 DHCPv6 和 DNSv6 配置?

我計劃在我的網路中設定 DHCPv6 和 DNS 伺服器。

  1. 我想了解是否可以使用 isc-dhcp-server 服務來設定 DHCPv4 和 DHCPv6?
  2. 當我嘗試 nslookup 網域時,它回傳的是 IPv4 位址而不是 ipv6 位址。
  3. 當我嘗試為同一台機器的兩個不同介面配置兩個 IPv6 IP 時,只有一個介面提供了 IP。

有人可以指引我為 IPv6 設定 dhcpv6 和 DNS 伺服器嗎?

#1 查詢的資訊 # 這是一個非常基本的子網路宣告。

 subnet 10.222.190.0 netmask 255.255.255.192 {
 range 10.222.190.54 10.222.190.61;
#  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
}

 subnet6 2001:1:1:1::0 netmask 64 {
 range6 2001:1:1:1::15 2001:1:1:1::35;
#  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
}

#3 查詢的資訊。

eth1      Link encap:Ethernet  HWaddr 08:00:27:f4:63:54
          inet addr:10.222.190.55  Bcast:10.222.190.63  Mask:255.255.255.192
          inet6 addr: 2001:1:1:1::9/64 Scope:Global
          inet6 addr: fe80::a00:27ff:fef4:6354/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:77414 errors:0 dropped:0 overruns:0 frame:0
          TX packets:234 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:5207783 (5.2 MB)  TX bytes:32631 (32.6 KB)

eth2      Link encap:Ethernet  HWaddr 08:00:27:38:fc:87
          inet addr:10.222.190.70  Bcast:10.222.190.127  Mask:255.255.255.192
          inet6 addr: fe80::a00:27ff:fe38:fc87/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:174 errors:0 dropped:0 overruns:0 frame:0
          TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:45035 (45.0 KB)  TX bytes:988 (988.0 B)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:268 errors:0 dropped:0 overruns:0 frame:0
          TX packets:268 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:20504 (20.5 KB)  TX bytes:20504 (20.5 KB)

介面設定檔

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
#auto eth0
#iface eth0 inet dhcp

# Primary entry node Enterprise NAT
auto eth1
iface eth1 inet static
address 10.222.190.55
netmask 255.255.255.192
network 10.222.190.0
broadcast 10.222.190.63
gateway 10.222.190.1

iface eth1 inet6 static
address 2001:1:1:1::9
#address fd01:1:1:1::9
netmask 64
gateway 2001:1:1:1::1

# Exit Node Access NAT
auto eth2
iface eth2 inet static
address 10.222.190.70
netmask 255.255.255.192
network 10.222.190.64
broadcast 10.222.190.127
gateway 10.222.190.65

iface eth2 inet6 static
address 2001:1:1:2::6
#address fd01:1:1:2::6
netmask 64
gateway 2001:1:1:2::1

已實施的IPv6規劃:

Interface name  Eth:IP Address  Gateway IP  Routing Prefix
ETH2    2001:1:1:1::6   2001:1:1:1::1   64
ETH1    2001:1:1:1::7   2001:1:1:1::1   64
ETH4    2001:1:1:1::8   2001:1:1:1::1   64
ETH1    2001:1:1:1::9   2001:1:1:1::1   64
ETH2    2001:1:1:2::6   2001:1:1:2::1   64
ETH4    2001:1:1:2::7   2001:1:1:2::1   64
ETH3    2001:1:1:2::8   2001:1:1:2::1   64
ETH4    2001:1:1:2::9   2001:1:1:2::1   64
ETH0    2001:1:1:2::10  2001:1:1:2::1   64
ETH0    2001:1:1:2::11  2001:1:1:2::1   64
ETH1    2001:1:1:3::6   2001:1:1:3::1   64
ETH5    2001:1:1:3::7   2001:1:1:3::1   64
ETH4    2001:1:1:3::8   2001:1:1:3::1   64
ETH5    2001:1:1:3::9   2001:1:1:3::1   64

相關內容