【Linux】Linux網路配置基礎3 編輯配置檔案設定網路卡子介面ip

海星星hktk發表於2016-01-18
Linux網路配置基礎3 
編輯配置檔案設定網路卡子介面ip

OS:Red Hat Enterprise Linux 6.4
目前eth0 通過host-only網路卡與win7通訊
規劃給eth0配置子網路卡ip eth0:0   地址192.168.7.101
使用win7能夠通過此ip正常訪問linux作業系統


[root@rhel64 ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth0





1 複製eth0網路卡配置檔案 生成eth0:0
[root@rhel64 ~]# ifconfig eth0
[root@rhel64 ~]# cd /etc/sysconfig/network-scripts/
[root@rhel64 network-scripts]# cp ifcfg-eth0 ifcfg-eth0:0


2 編輯網路卡配置檔案
[root@rhel64 network-scripts]# vi ifcfg-eth0:0


3 重啟網路服務
[root@rhel64 ~]# service network restart


[root@rhel64 ~]# ifconfig


4 host-only 虛擬網路卡增加7網段ip地址







5 win7 ping 測試 eth0:0 ip網路通



呂星昊
2016.1.18

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/29475508/viewspace-1978212/,如需轉載,請註明出處,否則將追究法律責任。

相關文章