Install CentOS on Windows 8 Hyper-V

For some courses at KTSI we need a CentOS to test some Linux spesific things like Apache and other stuff. The good thing, Windows 8 got Hyper-V and Hyper-V supports CentOS.

With Version 3.2 oft the Linux Integration Services Microsoft fixed also a bug which occurred in Windows 8.

  1. First download CentOS
  2. Download the Linux Integration Services Version 3.2 for Hyper-V
  3. Start Hyper-V Manager and create a new Virtual Machine
  4. Install CentOS 6.x
    centos hyper-v
  5. Reboot the virtual machine
  6. Login as root
    centos hyper-v
  7. Mount the Linux Integration Services ISO from step 2
  8. Now run the following commands in the virtual machine
    sudo mount /dev/cdrom /media
    sudo /media/install.sh
    

    centos hyper-v

  9. After you the Installation is completed you have to reboot the virtual machine again
    centos hyper-v
  10. done ;-)

 

Lenovo ThinkPad T430u

Lenovo ThinkPad T430u

In the last days Lenovo showed pictures of the Lenovo ThinkPad T430u for the first time. The ThinkPad T430u is a 14-inch ultrabook which will be release in 2012. There is not a lot of information about the specs of the T430u but it will use one of the new Intel Ive Bridge CPUs and should also be available with Nvidia discrete graphics options.

This could be a very interessting notebook option for business users. My hope for the T430u is that it will bring a great high-resolution display option. But we will see it later this year or maybe at CES 2012.

More Information about the T430u on theverge.com.

Happy New Year

Another great year ends and 2012 is just around the corner. 2011 was a successful year but I think 2012 will be even better. The private cloud products we all have talked about in the past months like System Center 2012 and Windows Server 8 will finally be released. And I am sure a lot of other stuff is coming in 2012.
I hope you all had fun reading my blog posts and tweets. I have learned a lot in the past year and had the chance to talk to a lot of interesting people.

Some predictions for 2012:

  • 2012 will be the year of Hyper-V (by Aidan Finn)
  •  Windows 8 will be released ;-)
  • I will buy my first Windows Tablet
  • My blog will hit the magic line of 2000 unique visitors a day
  • A lot of interesting project
  • System Center 2012 change the datacenter
  • Windows Phone will get some market share
  • I will do my private cloud proof of concept for my diploma thesis

Thank you all and happy new year.

Hyper-V 3: Import and Export VMs with PowerShell

Hyper-V-Powershell02

Aidan Finn (Virtual Machine MVP) just made a blog post about Hyper-V & PowerShell in Windows Server 8 and how you can enable Hyper-V via PowerShell in Windows Server 8. So this gave me the idea about doing a little more with PowerShell and Hyper-V 3.

I already did a blog post about how you can attach multiple VHDs to a SCSI Controller with PowerShell in Windows Server 8. In this post I will show how easy you can export and import a lot of Virtual Machines.

First you can run a Get-VM Test*, to check which VMs you will export.


Get-VM Test*

Now you can export the Virtual Machines


Get-VM Test* | Export-VM -Path "C:\VMs"

Now I removed the Virtual Machines in Hyper-V with Powershell (You could also add the -confirm parameter so you don’t have to press “y” for each VM.


Get-VM Test* | Remove-VM

And now you can import the Virtual Machines again


Get-Childitem "C:\VMs" -Recurse *.xml | Import-VM

Hyper-V-Powershell01

I will post more about PowerShell in Windows 8 and Windows Server 8 (Hyper-V 3) in the next upcommig weeks. If you want know more about what new Hyper-V features and improvments are coming in Windows Server 8, you can read the following blog post: “Hyper-V: Version 3 kills them all

 

Enable RSAT on Windows Server 2008 R2 for Hyper-V

Hyper-V R2 SP1

With the Remote Server Administration Tools (RSAT) you can administrate the Server with remote consoles. Now you can download the Remote Server Administration Tools for Windows 7, but if you are on Windows Server 2008 R2 you can just enable the tools per ServerManagerCmd.exe.


ServerManagerCmd -install RSAT-Hyper-V
ServerManagerCmd -install RSAT-Clustering

 

Automated Active Directory Deployment with PowerShell

Powershell

For a small presentation at KTSI I created a PowerShell script will automatically will deploys Active Directory Servers, adds other member servers, creates Organization Units and adds users via Powershell Remoting. As source there is a XML configuration file and CSV files for User Data.

Install AD with Powershell

This script is just for Lab deployments not for production, and it is not perfect, but I think maybe some people will enhance this script with their own code.

I do not support this script. it is just something I need to deploy my test environments and nothing more. More it shows diffrent

You can find more information about it works in this document.

XML Config file:


<?xml version="1.0" encoding="utf-8"?>
<lab>
<config>
<servers>
<server name="ADS01" ip="192.168.100.11" id="1" adminpw="passw0rd"/>
<server name="ADS02" ip="192.168.100.12" id="2" adminpw="passw0rd"/>
</servers>
<ad>
<domain name="ktsi.local" netbiosname="ktsi" forestlevel="4" domainlevel="4" safemodepw="passw0rd" />
</ad>
<ous>
<ou name="UserAccounts" path="DC=KTSI,DC=LOCAL" />
<ou name="BASEL" path="OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="CHICAGO" path="OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="NEWYORK" path="OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="SALES" path="OU=BASEL,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="IT" path="OU=BASEL,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="ADMINISTRATION" path="OU=BASEL,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="PRODUCTION" path="OU=BASEL,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="SALES" path="OU=CHICAGO,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="IT" path="OU=CHICAGO,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="ADMINISTRATION" path="OU=CHICAGO,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="PRODUCTION" path="OU=CHICAGO,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="SALES" path="OU=NEWYORK,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="IT" path="OU=NEWYORK,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="ADMINISTRATION" path="OU=NEWYORK,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
<ou name="PRODUCTION" path="OU=NEWYORK,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
</ous>
<users>
<file name="users.csv" path="OU=ADMINISTRATION,OU=BASEL,OU=USERACCOUNTS,DC=KTSI,DC=LOCAL" />
</users>
<members>
<member name="PC101" ip="192.168.100.21" />
<member name="PC101" ip="192.168.100.22" />
<member name="PC101" ip="192.168.100.23" />
</members>
</config>
</lab>

The PowerShell Script:

Continue reading