Linux 0-1 modifying host names and IP addresses

Source: Internet
Author: User
1. Modify host name hostname view hostname vi/etc/sysconfig/network Modify hostname= hostname vi/etc/hosts Modify 127.0.1 hostname service Network restart #/etc/ Hosts in the domain name resolution precedence over DNS server 2.IP address Ifconfig view current network card information cd/etc/sysconfig/network-scripts LS view network equipment VI ifcfg-eth0 #设定静态IPDEVICE = " Eth0 "Specify device bootproto=" Static "Specify is static iphwaddr=" 00:0c:29:a7:57:d5 "MAC address onboot=" yes "boot ipaddr=192.168.150.131 IP address netmask=255.225.255.0 Subnet mask gateway=192.168.150.255 Gateway (where you can write UUID DNS information) #动态IPBOOTPROTO = "DHCP" is specified as a static IP Summary: Through these two can ensure that the cluster Server ping IP address and ping host name can

Linux 0-1 modifying host names and IP addresses

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.