A little something about everything

internet marketing and website development made simple..

How to install Linux Integration Services 4.2.5 for Linux VM on Microsoft HyperV

After you install your Linux OS from the Microsoft HyperV terminal access do the following:

  • Click "Media", "DVD Drive" > "Insert Disk..."
  • Choose LinuxIC-4.2.5.iso
  • Login to the server and do the following:
#mount /dev/cdrom /media
mount: /dev/sr0 is write-protected, mounting read-only

#cd /media
#./install.sh
#reboot

After doing this you will be able to setup networking and use kvm via HyperV on linux.

Step by Step install of CentOS7 on Microsoft Hyper-V Server with Linux Integration Services Version 4.0

Step by Step install of CentOS7 on Microsoft Hyper-V Server

 

  1. Create new VHD Generation 1
  2. Install from iso
  3. Configure network
    • Check, "Automatically connect to this network when it is available"
    • If manual IP allocation configure IPv4 & IPv6 as needed.
  4. Set root password
  5. Finish install

Download and install Linux Integration Services 4.0 from microsoft

 

  1. Download Linux IC4.0
  2. attach the ISO from HyperV
  3. run the following commands:
    # mount /dev/cdrom /media
    # cd /media
    # ./install.sh
    # reboot
Update Network settings
  1. right click on the virtual machine and click settinsg then expand network adapter select advanced features and note the mac address.
  2. run the following commands:
    # vi /etc/sysconfig/network-scripts/ifcfg-eth0
  3. use "i" to insert text, (esc) to exit and ":wq" to write your changes to make the file look like this:
    TYPE="Ethernet"
    BOOTPROTO=none
    DEFROUTE=yes
    IPV4_FAILURE_FATAL=no
    IPV6INIT=yes
    IPV6_AUTOCONF=yes
    IPV6_DEFROUTE=yes
    IPV6_FAILURE_FATAL=no
    NAME=eth0
    UUID=(leave this as is)
    DEVICE="eth0"
    ONBOOT=yes
    HWADDR=(MAC ADDRESS, This should match what is configured in Hyper-V)
    Networking=yes
    IPADDR=(YOUR SERVER IP)
    PREFIX={your network prefix ie /24 = 24}
    GATEWAY=(YOUR DEFAULT GATEWAY)
    DNS1=(PRIMARY DNS SERVER IP)
    DNS2=(SECONDARY DNS SERVER IP)
    IPV6_PEERDNS=yes
    IPV6_PEERROUTES=yes
    IPV6+PRIVACY=no
  4. now restart the network:
    service network restart

Instalation should be complete

Be sure to run > yum update

If you receive "could not resolve host mirror.centos.org" be sure that onboot=yes in the network config.

The volume (DRIVE:) was not optimized because an error was encountered: Neither Slab Consolidation nor Slab Analysis will run if slabs are less than 8 MB. (0x8900002D)

This error appears in the event viewer when the scheduled task "ScheduledDefrag" runs.

Cause: In most cases this is cause by the -k switch which tells the defrager to perform a slab consolidation on the selected volume. This will cause an error for slabs that are less than 8 MB, and will commonly toss an error on HyperV VM's.

Solution: remove the -k switch from the task.

  • Open scheduled tasks, Microsoft, windows, defrag: "ScheduledDefrag"
  • Now click properties, actions, edit [start a program]
  • under add arguments(optional): remove the -k and click "ok", "ok"

That's it, your done.