Linux Basic Learning -6.2-NIC configuration file

Source: Internet
Author: User

1, the network card configuration file

[Email protected] ~]# #/etc/sysconfig/Network-script/ifcfg-eth0

[Email protected] ~]# #config

[[email protected] ~]# #c f g

[Email protected] ~]# Ll/etc/sysconfig/network-scripts/ifcfg-eth0

-rw-r--r--. 3 root root 229 Oct 16:55/etc/sysconfig/network-scripts/ifcfg-eth0

2. Detailed explanation of network card configuration file

[Email protected] ~]# Cat/etc/sysconfig/network-scripts/ifcfg-eth0

Device=eth0 #网卡的名字

HWADDR=00:0C:29:90:89:D9 #HWADDR HardWare Address hardware addresses MAC address

Type=ethernet #网络类型 Ethernet

uuid=ae779ae6-044d-43d5-a33b-48c89e8de10e #UUID unique identity that is unique in the system.

Onboot=yes #******boot on? Whether to start the network adapter when powering on or restarting the NIC

Nm_controlled=yes #是否受network程序管理

How the Bootproto=none #****** network card obtains the IP address of the IP Address Card

#dhcp get an IP address automatically

#none a fixed IP address

#static a fixed IP address

ipaddr=10.0.0.100 #IPADDR IP Address

netmask=255.255.255.0 #子网掩码 determine the maximum number of machines in this LAN

gateway=10.0.0.2 #GATEWAY Gateway to the entire building.

dns1=223.5.5.5

dns2=223.6.6.6

Userctl=no #普通用户是否能控制网卡

Peerdns=yes #网卡配置文件里面的DNS优先于/etc/resolv.conf

Exercises:

Explain in detail the meaning of each line in the NIC configuration file?

Linux Basic Learning -6.2-NIC configuration file

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.