一、需求
因不需要ipv6功能,是以可以将其關閉。
二、步驟
1.修改/etc/sysconfig/network 相應網卡,追加:
代碼如下
<code>NETWORKING_IPV6=no</code>
2.修改/etc/hosts,把ipv6的那句本地主機名解析的也注釋掉:
<code>#::1 localhost localhost6 localhost6.localdomain6</code>
3.建立檔案/etc/modprobe.d/ipv6off.conf(名字随便起)
注:RHEL6.0之後沒有了/etc/modprobe.conf這個檔案
<code>alias</code> <code>net-pf-10 off</code>
<code>options ipv6 disable=1</code>
4. 重新開機系統,然後确認:
<code>[root@</code><code>test</code> <code>~]</code><code># lsmod | grep -i ipv6</code>
<code>[root@</code><code>test</code> <code>~]</code><code># ifconfig | grep -i inet6</code>
如果上述2個指令執行的結果沒有任何顯示,那麼說明ipv6已經被完全禁止了。
其它:
在不加載ipv6子產品的方法裡,有人會有類似這樣的設定方法:
<code>alias</code> <code>ipv6 off</code>
雖然這樣在系統重新開機後,ipv6的确沒被加載,但是因為第二句,在有的版本的系統裡,當我們重新開機網絡的時候,會出現錯誤:FATAL: Module off not found.
<code>RedHat 5.x</code>
<code>To disable IPv6 </code><code>in</code> <code>a virtual machine running RedHat 5.x:</code>
<code>1.Log </code><code>in</code> <code>as root or superuser. www.111cn.net</code>
<code>2.If the </code><code>/etc/sysconfig/network</code> <code>file</code> <code>contains the line NETWORKING_IPV6=</code><code>yes</code><code>, change the line to:</code>
<code>3.In the </code><code>file</code> <code>/etc/modprobe</code><code>.conf, add this line:</code>
<code>4.Save the </code><code>file</code> <code>and reboot the system.</code>
<code>After you disable IPv6, you should be able to </code><code>install</code> <code>and configure VMware Tools successfully.</code>
原文連結:http://www.3lian.com/edu/2013/12-28/119848.html
本文轉自獨彈古調 51CTO部落格,原文連結:http://blog.51cto.com/hunkz/1883390,如需轉載請自行聯系原作者