A little something about everything

internet marketing and website development made simple..

Step by Step static network setup for CentOS 7.x on Microsoft Hyper-V Server using Linux Integration Services Version 4.0.11

Create new VHD with a standard Network Adapter

Download CentOS-7-x86_64-Minimal-1503-01.iso (insert disk & install)

Download lis4-0-11.iso (insert disk)

mkdir -p /mnt/cdrom
mount /dev/cdrom /mnt/cdrom
cp -rp /mnt/cdrom /opt/linux_ic4011
umount /mnt/cdrom
cd /opt/linux_ic4011/RHEL71
./install.sh

Once the install is done, reboot the VPS

Update your network settings via vi

vi /etc/sysconfig/network-scripts/ifcfg-eth0

use "i" to insert text, (esc) to exit and ":wq" to write your changes.

It should look something like this:

DEVICE="eth0"
BOOTPROTO=none
ONBOOT="yes"
TYPE="Ethernet"
HWADDR=(MAC ADDRESS, This should match what is configured in Hyper-V)
IPADDR=(YOUR SERVER IP)
GATEWAY=(YOUR DEFAULT GATEWAY)
DNS1=(PRIMARY DNS SERVER IP)
DNS2=(SECONDARY DNS SERVER IP)
Networking=yes


If your system is still not online for static IP do this:

 ifconfig eth0 (IP) netmask (MASK) up

 service network restart

Comments (11) -

  • darren

    12/20/2012 3:29:21 AM |

    Just logged on to say thank you for the nice tutorial. Worked like a charm.

  • Recep YUKSEL

    12/20/2012 3:52:22 PM |

    It's worked, no any problem.

    Thank you very much Hyde..

  • Marco Faria

    1/18/2013 6:25:17 AM |

    And does it still work after you do a yum update?
    Whenever i do a yum update and get kernel updated to 2.6.32-279.19.1 and reboot the server it fails to start with kernel panic.
    I have to boot to the old kernel to successfully load the kernel.

  • Shawn Hyde

    1/18/2013 6:43:54 AM |

    I did not seem to have any issues doing yum update. maybe you had a bad yum, try it again.

  • Shawn Hyde

    1/18/2013 6:49:31 AM |

    You can also check the repositories, verify you are not installing the wrong version (ie plus kernel)

  • Lenny

    1/22/2013 8:00:14 AM |

    The ICS kernel modules are compiled for the stock kernel that ships with CentOS 6.3 - 2.6.32-279 It may be possible to copy them over to the new kernel directory and do a depmod to use them with the new kernel.

    The directory you'd need to copy is /lib/modules/2.6.32-279.el6.x86_64/extra/microsoft-hyper-v

    Bit of a PITA but then that's MicroShaft for you...

  • Jon

    3/7/2013 9:52:52 AM |

    Outstanding.  Thanks a bunch!

  • Alan

    3/10/2013 1:03:29 PM |

    Maybe you underestimated the stupidity of a newbie like me, or maybe there was a way around this, but I had a lot of problems until I attached the iso file to the virtual DVD/CDROM drive.  I don't actually have a cdrom in my machine, so I just downloaded the LinuxICv34.iso file to my virtual machine and mounted it there.  It didn't work.  I tried extracting the iso file and downloading it as a directory tree.  No difference.  I tried writting the iso image to disk on a different machine, copying the folders from there and downloading them.  Still no love.  Finally, I figured out how to attach the virtual DVD/CDROM drive to an iso file in Hyper-V settings.  Everything worked!  So I don't know what the difference is (did I mention I'm a Linux newbie?) but I think it would be helpful to some people if you added that step in your instructions.  Otherwise, this was incredibly helpful.  Thank you!

  • Anonymous Coward

    3/24/2013 7:36:38 PM |

    Thank you!

  • curt

    4/26/2013 4:08:58 PM |

    Thanks a lot!! Worked Great.

    One question that I have is..
    I have the outside ip configured correctly but I would also like to connect to other vm's internally. Do I create an internal switch in hyper-v and repeat the above process??

    Thanks

  • Shawn Hyde

    4/26/2013 4:26:42 PM |

    You should add an extra lan port both on the Hyper-V server and on the nix box, then vlan them or if you hyper-v has multiple physical nic cards you can have one go to a private switch and another go to public switch for best security.

Pingbacks and trackbacks (2)+

Add comment

Loading