How to Configure Internet access on a CentOS Minimal install
By default a CentOS minimal install can't connect to the network or the internet, in order to configure it to access the outside world you need to follow the following steps:
Configure the DHCP client on the default network interface eth0 by executing the following command:
dhclient eth0
Edit the main network configuration file to make sure networking is enabled using the command
vi /etc/sysconfig/network
and make sure that it has networking set to yes
NETWORKING=yes
Edit the network configuration file for eth0 to enable it to use a dynamic ip using dhcp
vi /etc/sysconfig/network-scripts/ifcfg-eth0
Modify the file to have the following
DEVICE="eth0" BOOTPROTO="dhcp" ONBOOT="yes" NM_CONTROLLED="no"
Save the file and then restart the network service using the following command
service network restart
Make sure that eh0 has pulled an IP using the following command
ifconfig