See the IP address under CentOS 7

Source: Internet
Author: User

In the newly installed CentOS7 and the previous version of the CentOS6, the initial state is no network configuration, you need to use the dhclient command to obtain an IP address automatically, to see the IP address obtained using the command IP addr, you will see the network card information and LO card information, Enter configuration file to modify IP information

Vi/etc/sysconfig/network-scripts/ifcfg-enoxxxxxxx

Modified: Onboot=yes

Bootproto=static

Added: Ipaddr= #IP地址

gateway= #默认网关

netmask= #子网掩码

dns1= #DNS


Save exit, restart NIC

Service network restart;


At this point, using the ifconfig prompt without the command, you need to install the Net-tools tool, Yum install-y net-tools, installation is complete ifconfig, view network card information

This article is from the "Tea Incense" blog, please be sure to keep this source http://chinawu.blog.51cto.com/10692884/1742027

See the IP address under CentOS 7

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.