Knowledge Base
How To Assign an IP Address to CentOS Linux Server
This tutorial shows you how to assign an IP Address to your CentOS Linux Server.
Step 1. | Log in to the server console as root user. | ||||
Step 2. | Open the file /etc/sysconfig/network-scripts/ifcfg-eth0 in a text editor, such as VI, if your default network interface is eth0. | ||||
Step 3. | Edit the file and add this information: | ||||
Below is a description of the fields: | |||||
|
|||||
Step 4. | Save and restart the network service. | ||||
Step 5. | If you check with the command ifconfig -a, you can see the assigned IP address. | ||||
Congratulations, you have assigned a hostname IP Address to your CentOS Linux Server.
* Your feedback is too short