久久96国产精品久久久-久久发布国产伦子伦精品-久久精品国产精品青草-久久天天躁夜夜躁狠狠85麻豆

技術員聯盟提供win764位系統下載,win10,win7,xp,裝機純凈版,64位旗艦版,綠色軟件,免費軟件下載基地!

當前位置:主頁 > 教程 > 服務器類 >

linux 關閉停用ipv6方法

來源:技術員聯盟┆發布時間:2018-09-25 00:00┆點擊:

  .修改/etc/sysconfig/network 相應網卡,追加:

 代碼如下      

NETWORKING_IPV6=no

 

  2.修改/etc/hosts,把ipv6的那句本地主機名解析的也注釋掉:

 代碼如下      

#::1   localhost localhost6 localhost6.localdomain6

 

  3.創建文件/etc/modprobe.d/ipv6off.conf(名字隨便起)

  注:RHEL6.0之后沒有了/etc/modprobe.conf這個文件

 代碼如下      

alias net-pf-10 off
options ipv6 disable=1

 

  4. 重啟系統,然后確認:

 代碼如下      
[root@test ~]# lsmod | grep -i ipv6
[root@test ~]# ifconfig | grep -i inet6
 

  如果上述2個命令執行的結果沒有任何顯示,那么說明ipv6已經被完全禁止了。

  其它:

  在不加載ipv6模塊的方法里,有人會有類似這樣的設置方法:

 代碼如下      
alias net-pf-10 off
alias ipv6 off
options ipv6 disable=1
 

  雖然這樣在系統重啟后,ipv6的確沒被加載,但是因為第二句,在有的版本的系統里,當我們重啟網絡的時候,會出現錯誤:FATAL: Module off not found.

  RedHat 5.x

  To disable IPv6 in a virtual machine running RedHat 5.x:

  1.Log in as root or superuser.

  2.If the /etc/sysconfig/network file contains the line NETWORKING_IPV6=yes, change the line to:

  NETWORKING_IPV6=no

  3.In the file /etc/modprobe.conf, add this line:

  options ipv6 disable=1

  4.Save the file and reboot the system.

  After you disable IPv6, you should be able to install and configure VMware Tools successfully.