Hyper-V netinstall fine, boots into OS with no internet

Issues related to configuring your network
Post Reply
ckorea
Posts: 1
Joined: 2014/11/30 08:33:17

Hyper-V netinstall fine, boots into OS with no internet

Post by ckorea » 2015/05/03 22:05:08

Hi! I'm trying to get CentOS 7.1 networking up and running under Hyper-V on Windows 8.1 Pro.

I created a Virtual Switch (non-legacy) under Hyper-V which was immediately picked up by the netinstall iso setup. I selected "Server with GUI" and the components downloaded and installed successfully.

But now that I'm in a freshly installed OS, internet connectivity has been lost. In GNOME I can see the networking icon at top right of the screen showing it's trying to connect. It just seems to hang there, and of course I can't browse to any web pages or ping google.com.

Tried googling around and found posts about similar problems but they refer to CentOS 6.x. I hear that one of 7.x's major changes are
Updated Hyper-V network drivers
* so I'm not that sure where to start.

In case it's useful info, I've tried installing Debian 8 under the same Hyper-V setup, and in that case network connectivity did in fact persist after I booted into the newly installed OS. Thanks for any help!

*http://wiki.centos.org/Manuals/ReleaseNotes/CentOS7

smallbizguy
Posts: 1
Joined: 2015/06/01 15:50:55

Re: Hyper-V netinstall fine, boots into OS with no internet

Post by smallbizguy » 2015/06/01 16:15:25

I struggled with it for a while with Centos 7.1, here's what worked for me.

1. Use 'Network Adapter' instead of 'Legacy Network Adapter' on Hyper-V settings

2. Installed Hyper-V Integration Services 4.0, https://www.microsoft.com/en-us/downloa ... x?id=46842
Download the iso file on your host and plug it into the VM's DVD drive. Run "install.sh" script in there as superuser. Reboot VM.

3. As per the TechNet Note 2 (https://technet.microsoft.com/en-us/lib ... 31026.aspx), you need to turn off Centos Network Manager for eth0 when injecting static address. That is to say, in your ifcfg-eth0, set NM_CONTROLLED=no

4. So here's my ifcfg-eth0 file:

TYPE=Ethernet
BOOtPROTO=static
NM_CONTROLLED=no
NAME=eth0
DEVICE=eth0
ONBOOT=yes
HWADDR=xx:xx...
IPADDR=x.x....
GATEWAY=x.x...
NETMASK=x.x...
DNS=x.x....

5. here's my network file:
NETWORKING=yes
GATEWAY=x.x....
HOSTNAME=yyy...

The VM comes up with the Network icon crossed out since the Network Manager is turned off for eth0, but I have the internet connectivity.

Post Reply