歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
您现在的位置: Linux教程網 >> UnixLinux >  >> Linux基礎 >> Linux服務器

在Linux下配置網絡(命令式)

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


        # Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+
        DEVICE=eth0
        BOOTPROTO=none
        HWADDR=00:19:21:12:F3:4E
        ONBOOT=yes
        NETMASK=255.255.255.0
        IPADDR=192.168.1.188
        GATEWAY=192.168.1.254
        TYPE=Ethernet
        USERCTL=no
        IPV6INIT=no
        PEERDNS=yes
        [root@localhost ~]#

        [root@localhost network-scripts]# cat ifcfg-eth0
        # Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+
        DEVICE=eth0
        BOOTPROTO=none
        BROADCAST=192.168.1.255
        HWADDR=00:19:21:12:F3:4E
        IPADDR=192.168.1.188
        NETMASK=255.255.255.0
        NETWORK=192.168.1.0
        ONBOOT=yes
        GATEWAY=192.168.1.254
        TYPE=Ethernet
        [root@localhost network-scripts]# vi ifcfg-eth0

 

Copyright © Linux教程網 All Rights Reserved