IPv6 是下一代 IP Address 的通訊協定,因為目前 IPv4 的 address 在網路使用者的快速倍增下很快就會面臨用完的困境,所以 IPv6 勢必會成為未來的趨勢。

而絕大多數的 Linux 環境都支援 IPv6 協定,甚至很多主流的 Linux 預設安裝起來就直接啟用。可惜從目前的應用面來說 IPv6 還是很遙遠,啟用它不但會影響系統效能,若是有使用 Linux XWindows 當桌面的話,更是嚴重影響上網的速度。

所以想要停用 IPv6 的支援,可以參考下列的處理方法:

1. 停用 IPv6 網路支援

編輯 /etc/sysconfig/network 修改

NETWORKING_IPV6=yes

變更成

NETWORKING_IPV6=no

2. 停用 Kernel 中的 IPv6 通訊協定堆疊

編輯 /etc/modprobe.conf

增加下列兩行設定

alias net-pf-10 off
alias ipv6 off

3. 停用 IPv6 版的防火牆

先執行下列指令停止服務

[www@root ]$ /etc/init.d/ip6tables stop
Flushing firewall rules: [ OK ]
Setting chains to policy ACCEPT: filter [ OK ]
Unloading ip6tables modules: [ OK ]

調整 IPv6 防火牆服務不要在開機自動啟動

[www@root ]$ chkconfig –level 35 ip6tables off

4. 檢查 localhost 名稱解析

編輯 /etc/hosts 若是 localhost 項目有 IPv6 格式的可以直接移除

::1 localhost.localdomain   localhost

不過要確定下列 IPv4 格式的 localhost 項目存在,不然會造成問題

127.0.0.1   localhost.localdomain   localhost

這樣就完成 disable IPv6 的調整作業了。

原文資料參考:
http://www.mjmwired.net/resources/mjm-fedora-fc6.html#ipv6