差異處
這裏顯示兩個版本的差異處。
Both sides previous revision 前次修改 下次修改 | 前次修改 | ||
linux:commonsetting:dhcp:setup_ipv6_dhcp_on_centos7 [2020/02/21 10:33] tony |
linux:commonsetting:dhcp:setup_ipv6_dhcp_on_centos7 [2023/06/25 09:48] (目前版本) |
||
---|---|---|---|
行 43: | 行 43: | ||
</code> | </code> | ||
如果啟動有發生問題,請下systemctl status dhcpd6.service去看錯誤原因。 | 如果啟動有發生問題,請下systemctl status dhcpd6.service去看錯誤原因。 | ||
+ | ===== Setup DHCP Client ===== | ||
+ | DHCP Client我以CentOS6.8為範例,首先將設定網卡為Automatic, DHCP only:\\ | ||
+ | {{:linux:commonsetting:dhcp:centos6_ipv6_dhcp_only.png|}}\\ | ||
+ | \\ | ||
+ | 接著重新啟動網卡確認IP: | ||
+ | <code bash> | ||
+ | [root@localhost ~]# ifconfig eth1 down | ||
+ | [root@localhost ~]# ifconfig eth1 up | ||
+ | [root@localhost ~]# ifconfig eth1 | ||
+ | eth1 Link encap:Ethernet HWaddr 00:25:90:FB:C3:7F | ||
+ | inet addr:10.68.0.1 Bcast:10.68.0.255 Mask:255.255.255.0 | ||
+ | inet6 addr: fc00::1000/64 Scope:Global | ||
+ | inet6 addr: fe80::225:90ff:fefb:c37f/64 Scope:Link | ||
+ | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 | ||
+ | RX packets:547 errors:0 dropped:0 overruns:0 frame:0 | ||
+ | TX packets:381 errors:0 dropped:0 overruns:0 carrier:0 | ||
+ | collisions:0 txqueuelen:1000 | ||
+ | RX bytes:119818 (117.0 KiB) TX bytes:70964 (69.3 KiB) | ||
+ | Memory:fb100000-fb17ffff | ||
+ | </code> | ||
+ | 最後檢查路由表: | ||
+ | <code bash> | ||
+ | [root@localhost ~]# route -A inet6 | grep fc00 | ||
+ | fc00::1/128 fc00::1 UC 0 3 0 eth1 | ||
+ | fc00::/64 * U 256 0 0 eth1 | ||
+ | fc00::1000/128 * U 0 4 1 lo | ||
+ | </code> | ||
+ | 在CentOS6的情況下,你不需要額外做什麼事情,路由表就會設定完成;但如果在CentOS7上使用了DHCP only,在沒有與RA的互動下,路由表你就要自己來了。DHCP only相關的討論可以參考: | ||
+ | * [[https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/1193205|dhcp IPv6 sets accept_ra to 0 and doesn't get IPv6 route]] | ||
+ | * [[https://mail.gnome.org/archives/networkmanager-list/2015-October/msg00032.html|Re: IPv6 with DHCP -- how is default route set?]] | ||
===== ===== | ===== ===== | ||
---- | ---- | ||
\\ | \\ | ||
~~DISQUS~~ | ~~DISQUS~~ |