首頁  >  文章  >  運維  >  centos7的網卡如何重啟

centos7的網卡如何重啟

藏色散人
藏色散人轉載
2020-08-12 17:31:106114瀏覽

以下由centos教學專欄跟大家介紹centos7的網卡重啟方法,希望對需要的朋友有幫助!

centos7的網卡如何重啟

centos7的網路卡重新啟動方法

1、centos6的網路卡重啟方法:service network restart

      centos7的網路卡重新啟動方法:systemctl restart network

2、DNS設定檔:cat /etc/resolv.conf

設定主機與IP綁定資訊:cat /etc/hosts

#設定主機名稱:cat /etc/hostname

3、可以使用nmtui文字方塊方式修改IP

4、關閉防火牆並設定開機不啟動

查看防火牆狀態:systemctl status firewalld.service

關閉:systemctl stop firewalld

開啟:systemctl start firewalld

開機自動關閉:systemctl disable firewalld

#開機自動自動關閉:systemctl disable firewalld

#開機自動自動。啟動:systemctl enable firewalld

查看開機是否啟動:chkconfig --list|grep network(RHLE6)

5、暫時和永久關閉Selinux

暫時關閉:

_getenforce
Enforcing
_setenforce 0
setenforce:SELinux is disabled

永久關閉:

_vim /etc/selinux/config
更多centos技術文章,請造訪

centos入門教學###專欄! ###

以上是centos7的網卡如何重啟的詳細內容。更多資訊請關注PHP中文網其他相關文章!

陳述:
本文轉載於:csdn.net。如有侵權,請聯絡admin@php.cn刪除