1. Specific steps to modify eth0 are as follows
Vi/etc/sysconfig/network-scripts/ifcfg-eth0,
I, enter the Insert edit mode, the specific parameters are set as follows:
Device=eth0
Bootproto=none (can also be set to static IP address)
Onboot=yes
Type=ethernet
netmask= Subnet Mask
Ipaddr=ip No.
gateway= Gateway (virtual machine Gateway)
ESC, exiting edit mode
shift+:wq! Save and Exit commands
2.ifconfig-a to see if it takes effect.
3.service network restart, Web server restart
"Pop-up interface eth0 is deciding eth0 IP information ... Failure: No link, do you want to check the cable? ”
This problem, change the bootproto=dhcp to Bootproto=static
4.ping +ip (IP of Linux), prompt success
5.ping + Gateway (gateway to Linux)
If Ping+ip succeeds, ping+ gateway fails, manually set DNS, command (vi/etc/resolv.conf)
(Add nameserver 10.0.0.1)
If you failed to set up DNS or ping the gateway, consider the problem with the virtual machine.
(Note: The virtual machine is NAT-networked, and the IP gateway in Linux must be consistent with the virtual Machine network segment)
Redhot cannot be networked ifconfig command only shows the way Lo does not show eth0 solution!