The Deployment Bunny

OS Deployment, Virtualization, Microsoft based Infrastructure…

  • Archives

  • Meta

Archive for the ‘SCVMM’ Category

Nice to Know–Microsoft Virtual Machine Converter 3.0 released to web

Posted by Mikael Nystrom on October 13, 2014

image

Now with P2V, yes!

New Features in MVMC 3.0
The 3.0 release of MVMC adds the ability to convert a physical computer running Windows Server 2008 or above server operating systems or Windows Vista or above client operating systems to a virtual machine running on Hyper-V host.

Standard stuff is:

  • Converts virtual disks that are attached to a VMware virtual machine to virtual hard disks (VHDs) that can be uploaded to Microsoft Azure.
  • Provides native Windows PowerShell capability that enables scripting and integration into IT automation workflows.
    Note The command-line interface (CLI) in MVMC 1.0 has been replaced by Windows PowerShell in MVMC 2.0.
  • Supports conversion and provisioning of Linux-based guest operating systems from VMware hosts to Hyper-V hosts.
  • Supports conversion of offline virtual machines.
  • Supports the new virtual hard disk format (VHDX) when converting and provisioning in Hyper-V in Windows Server® 2012 R2 and Windows Server 2012.
  • Supports conversion of virtual machines from VMware vSphere 5.5, VMware vSphere 5.1, and VMware vSphere 4.1 hosts Hyper-V virtual machines.
  • Supports Windows Server® 2012 R2, Windows Server® 2012, and Windows® 8 as guest operating systems that you can select for conversion.
  • Converts and deploys virtual machines from VMware hosts to Hyper-V hosts on any of the following operating systems:
  • Windows Server® 2012 R2
  • Windows Server® 2012
  • Windows Server 2008 R2 SP1
  • Converts VMware virtual machines, virtual disks, and configurations for memory, virtual processor, and other virtual computing resources from the source to Hyper-V.
  • Adds virtual network interface cards (NICs) to the converted virtual machine on Hyper-V.
  • Supports conversion of virtual machines from VMware vSphere 5.5, VMware vSphere 5.0, and VMware vSphere 4.1 hosts to Hyper-V.
  • Has a wizard-driven GUI, which simplifies performing virtual machine conversions.
  • Uninstalls VMware Tools before online conversion (online only) to provide a clean way to migrate VMware-based virtual machines to Hyper-V.
    Important MVMC takes a snapshot of the virtual machine that you are converting before you uninstall VMware Tools, and then shuts down the source machine to preserve state during conversion. The virtual machine is restored to its previous state after the source disks that are attached to the virtual machine are successfully copied to the machine where the conversion process is run. At that point, the source machine in VMware can be turned on, if required.
    Important MVMC does not uninstall VMware Tools in an offline conversion. Instead, it disables VMware services, drivers, and programs only for Windows Server guest operating systems. For file conversions with Linux guest operating systems, VMware Tools are not disabled or uninstalled. We highly recommend that you manually uninstall VMware Tools when you convert an offline virtual machine.
  • Supports Windows Server and Linux guest operating system conversion. For more details, see the section “Supported Configurations for Virtual Machine Conversion” in this guide.
  • Includes Windows PowerShell capability for offline conversions of VMware-based virtual hard disks (VMDK) to a Hyper-V–based virtual hard disk file format (.vhd file).
    Note The offline disk conversion does not include driver fixes.

Posted in Hyper-V, SCVMM | Tagged: , | 1 Comment »

Issue (Hyper-V/SCVMM) – VMM cannot complete the host operation on the HOST server because of error:Storage for virtual machine ‘HOSTNAME’ failed with error ‘The device is not ready.’ (0x80070015)

Posted by Mikael Nystrom on August 28, 2014

Issue:

When trying to migrate a VM’s storage to a local device using SCVMM you could see this:

Error (12700)
VMM cannot complete the host operation on the HOST server because of the error: Storage migration for virtual machine ‘VM’ (GUID) failed with error ‘The device is not ready.’ (0x80070015).

Operation not allowed for virtual machine ‘VM’ because Hyper-V state is yet to be initialized from the virtual machine configuration. Try again in a few minutes.(Virtual machine ID )
Unknown error (0x800c)

When trying to migrate a VM’s storage to a local device using Hyper-V manager you could see this:

"Storage migration for virtual machine"HOST’ failed.
Operation not allowed because the replication state is not initialized.
Storage migration for virtual machine "HOST’ failed with error ‘The device is not ready’ (0x80070015)."

Solution:

So far the only solution I have found, tried (and it did work) is to restart the Hyper-V management service.

http://social.technet.microsoft.com/Forums/systemcenter/en-US/eb4511c5-23f9-4c1e-af32-88de0eeaaef1/vhdx-failed-to-migrate-to-local-storage?forum=virtualmachingmgrhyperv

Posted in SCVMM, System Center 2012 R2, System Center Virtual Machine Manager, System Center Virtual Machine Manager 2012 | Tagged: | Leave a Comment »

TechEd NA 2014 – The Scripts from my session – DCIM-B309 – Bare Metal OS Deployment in Microsoft System Center 2012 R2 Virtual Machine Manager

Posted by Mikael Nystrom on May 15, 2014

Here is the sample scripts from my session at TechEd NA 2014 (DCIM-B309 – Bare Metal OS Deployment in Microsoft System Center 2012 R2 Virtual Machine Manager: This Is How It Is Done!)

SkyDrive: http://1drv.ms/1n0vTm2

Channel 9: http://channel9.msdn.com/Events/TechEd/NorthAmerica/2014/DCIM-B309

/mike

Posted in Deployment, Hyper-V, SCVMM, System Center Virtual Machine Manager 2012, TechEd | Tagged: | Leave a Comment »

Nice to Know–Bare metal deployment in SCVMM using Custom script and Custom resources could fail

Posted by Mikael Nystrom on May 4, 2014

The bare metal OS deployment function in SCVMM has the ability to be customized by adding custom scripts (also know as GCE). Basically there is two ways to do this, you either make sure the  script is in the WinPE image or you add it using recourses in the SCVMM Library. There are two locations for those scripts, Pre and Post and the problem seems to be true when we are doing Pre OSD GCE’s. So how do I know it fails then?, well that is not that hard. It will give you a very informative message in the job log like this:

Error (2941)
VMM is unable to complete the request. The connection to the agent on machine SCVMM01.network.local has been lost.
Unknown error (0x80072efe)

Recommended Action
Ensure that the WS-Management service and the agent are installed and running and that a firewall is not blocking HTTPS traffic.

image

And if you open the vmmAgentPE.exe.log file on the host you are deploying you will se this:

058C.05C4::05/04-12:23:13.425#00:OSDDownloadFileFromUrl.cpp(88)[000000000306EB: ThrowOnWin32Failure : 80072efe. Operation attempted WinHttpReceiveResponse(m_hRequest, NULL)
058C.05C4::05/04-12:23:13.425#00:exceptions.cpp(97)[000000000306EB: CarmineException::CarmineException: CarmineError: 1051488,  hr: 0x80072efe

If you look at the last file it tries to download you will see that it is trying to download the SCVMMCRTag.cr file and if you check the size of the file you will se that the size is 0 bytes and “carmine” does not like to transfer 0 size files in WinPE.

Solution:

Modify the SCVMMCRTag.cr in notepad.exe and type whatever you like, close it, done. If you try once more it should work.

/mike

Posted in Deployment, SCVMM, System Center Virtual Machine Manager, System Center Virtual Machine Manager 2012, Virtual Machine Manager | Tagged: | Leave a Comment »

Nice to Know–Deploying Applications using System Center Virtual Machine Manager 2012 (SP1/R2) in UI or in PowerShell

Posted by Mikael Nystrom on August 21, 2013

Yes, I know, there other methods to deploy applications, but sometimes it make sense to use SCVMM to deploy applications to the host machines that you manage. If we look on this from a new and more modern way, SCVMM will be the System Center member that does the deployment of the “only” needed physical machines, that is the Hyper-V hosts and the fileservers used to store the VHDx files over the the SMB network, maybe there is no Configuration Manager Server in this datacenter for any reason.

The App = HP Service Pack

In this case we are going to deploy the HP Service Pack to our hosts since we need that to be able to monitor correctly using OpsMgr (When using an Agent) amongst many things. The Application can be “pushed” from a central location but in this case we are going to run the application locally on each and every server and reboot it if needed. The Command to make a silent express install is HPSUM.exe /express_install and you download the Service Pack for the Proliant servers from HP.com (https://h20392.www2.hp.com/portal/swdepot/displayProductInfo.do?productNumber=HPICE#Download). After downloading the ISO, mount and extract and share the folder so it is accessible to all your hosts.

The GUI Method

Rater easy actually, we can use the “Run Script Command” that is available on every server in the SCVMM Console and then fill out all the parameters

image

Fill out the parameters like this:

-Executable program: \\vmm01\CD\hp\swpackages\hpsum.exe

-Parameters: /express_install

-Timeout: 1800

-Advanced:

–Standard Output: Do not match

–Standard error: Do not match

–Exit Code: Do not Match

–Action when matched: Warn and Continue

–Job restart action: Ignore Script

–Always restart after the script has finished running: Checked

–Restart the computer or virtual machines if the specified exit code is returned: Unchecked

image

Summary using the UI:

This will work, but not they way I wanted it to, the problem is that I cannot define my own values in the dialg boxes, as an example the application HPSUM.exe will return exit code 1,2 or 3 when it needs a reboot and that cannot be “picked” in the dropdown list, however, using PowerShell well be easier, better and faster since you can define all the applications in an XML file wit all the different settings. so lets drop the UI and switch over to what works and make sense, PowerShell :-)

The PowerShell Method

In this case we will use the same engine, but fire it of using PowerShell instead, it gives us more flexibility and more control

Step Number One – Create the Apps.XML

Here we create an XML file that contain all the settings for all the different application we would like to deploy and here it how it looks:

image

as you can see it contains the application, arguments, reboot settings and all the return codes this application could return when it “feels” that it needs a reboot

Step Number Two – Create the Deploy-Apps.ps1 script

The script uses the Parameter function to read in data from the command line and then it reads the XML file, we also need to make sure that some of the data from the XML file is parsed correctly as strings or as Boolean. Then we use all that data set some static settings and last we use the Invoke-SCScriptCommand to execute the command on the host, the script looks like this:

image

Step Number Three – Execute!

Execute the script like this:

image

And wait for the job in the log and after a while it will inform you that the job did finish with warnings, the reason for the warning is that is actually a real warning from the application that is picked up up by the output :-)

The hpsum.exe detects the version of windows as 6.2 (and that is correct), but even if HP claims that is supported, the HPSUM.exe does not have the same opinion :-). Hopefully HP will fix this later.

image

So in the Job log it will show up like this:

image

Summary using PowerShell:

This gives a more stable solution which can be extended and automated and that I like…

You can download the scripts from here:

Posted in Deployment, PowerShell, SCVMM, System Center 2012, System Center 2012 R2, System Center Virtual Machine Manager 2012, Virtual Machine Manager | Tagged: , , | 4 Comments »

Nice to Know – Video: Hybrid Cloud (Swedish)

Posted by Mikael Nystrom on July 3, 2013

FrontPage

Jag fick jobbet att spela in en packe filmer, vilket jag nu har gjort, det blev totalt 17 stycken om Windows Server 2012, Windows 8, Office 2013, System Center 2012, Private Cloud, Public Cloud, Partner Cloud kring saker JAG tycker är viktigt att förstå och kunna. Hur kan man ha roligare

Nionde filmen handlar om Hybrid Moln (vilket är skitballt)

/mike

Posted in Azure, Cloud, Hyper-V, SCVMM, System Center 2012, Windows Server 2012 | Tagged: | Leave a Comment »

Nice to Know – Video: Private Cloud med SCVMM 2012 (Swedish)

Posted by Mikael Nystrom on July 3, 2013

FrontPage

Jag fick jobbet att spela in en packe filmer, vilket jag nu har gjort, det blev totalt 17 stycken om Windows Server 2012, Windows 8, Office 2013, System Center 2012, Private Cloud, Public Cloud, Partner Cloud kring saker JAG tycker är viktigt att förstå och kunna. Hur kan man ha roligare

Åttonde filmen handlar om Private Cloud baserat på System Center 2012 SP1

Posted in Hyper-V, SCVMM, System Center 2012, Windows Server 2012 | Tagged: | Leave a Comment »

OS Deployment – Deploying Hyper-V hosts using System Center Virtual Machine Manager 2012 SP1 PowerShell Prompt – Part 1(2)

Posted by Mikael Nystrom on June 22, 2013

Working with OS deployment pretty much means that, I don’t really care if it is a client OS or a server OS, its still Windows from my perspective, there are small differences, but basically it is the same. One of the challenges you might have is to deploy Hyper-V host machines using System Center Virtual Machine Manager 2012 SP1 and with challenge I mean its is very opposite from MDT or SCCM, or even WDS since all of those belongs to “controlled my client/agent” but when it comes to SCVMM it is more of “controlled by SCVMM”. In this first part I will cover the Server Deployment, not the network configuration and reason is that I do this in a 2 –step process for many reasons, but the most obvious is:

  • If a customer would like to use any other method for the OS deployment part I can easily remove this part and replace it with the customer demands and still keep my script that does the network configuration easily
  • Using this method it pretty much work with any hardware in any configuration

Challenges?

Yes, there are some

  • You need to have a PXE environment and it cannot co-exists with Configuration Manager and it needs to be added to SCVMM
  • The server/compute/host needs to be configured to boot in PXE mode
  • The server needs to support IPMI or SMASH and you also need the password for that
  • SMBiosGuid mess: This is the bad and ugly, some vendors have ONE SMBiosGuid number when you ask IPMI and an other when the server boots and contacts WDS and therefore we need to know the “real” SMBiosGuid number (Easy, just boot the machine into PXE and check the WDS log

image

In the picture you can see the SMBiosGuid number that is used by the server when presenting it self to the PXE server, if that is correct it all works, otherwise we need to “cheat” just a bit and we do that by providing the real SMBiosGuid (can only be done using PowerShell)

The solution:

For this to work you need to have created the basic things in SCVVM, tings like logical network and such and now over to PowerShell :-) and here is how it looks:

Here is all the variables we use

  • $OSDComputername = “The name of the computer to be installed”
  • $BMCAddress “The IP address of the BMC”
  • $MGMMacAddress “The Mac Address that should be used as the management NIC”
  • $MGMIPAddress “The IP address the computer should have as the Management IP address”
  • $SMBIOSGUID “The REAL SMBIOSGUID Number”
  • $HOSTProfileName “The name of the Host Profile to be used”
  • $HostGroup “The host group in SCVMM to put it”
  • $IPv4Subnet “The subnet of the Management IP address”
  • $RunAsAccount “The IPMI RunAsAccount that has the correct permissions to perform IPMI operations”
Section 1 :

The Parameter section, this section is created so that you can either read all the information from an .csv file or provide it on command like like it was a CMDLet

image

Section 2 :

We have all data, now we just need to get the data from SCVMM so we can start deploying, we also add a DNS A record for the machine, now that should NOT be needed, but to increase the odds to success I have started to add it since I hate “almost”

image

Section 3:

Time to deploy

image

Section 4:

You also need the CSV file to put in all the data and here is an example

image

And the you need to kick of the deployment

Import-Csv SCVMMostDeploy.csv | Deploy-HostII.ps1

/mike

Download here

Posted in Deployment, SCVMM, System Center 2012, Virtual Machine Manager | Tagged: , | 3 Comments »

Sommarkollo 2013 – Hybrid Moln skapar förutsättningar för en elastisk infrastruktur

Posted by Mikael Nystrom on June 19, 2013

Under denna session kommer vi att visa hur du kan koppla ihop din egna lokala infrasctruture med Azure Virtual Machine för att på så sätt skapa möjligheten att enkelt kunna expandera vid formtoppar.

4/7 Anmäl dig till sessionen här >

22/8 Anmäl dig till sessionen här >

Posted in Azure, Hyper-V, SCVMM, System Center 2012, System Center 2012 R2, Virtual Machine Manager, Windows Server 2012, Windows Server 2012 R2 | Tagged: | Leave a Comment »

Sommarkollo 2013 – Djupdykning i Nätverk och Storage i System Center Virtual Machine Manager och Windows Server 2012 – en magisk upptäcksfärd

Posted by Mikael Nystrom on June 19, 2013

Det finns två saker i nya Windows Server 2012 som man måste förstå och som har en flexibilitet som få har förstått. I denna session rätar vi ut alla frågetecken när vi dyker ner i detaljerna kring Virtual Switches, Virtual Network Adapters, Q o S, SMB3, Storage Spaces, FibreChannel, ISCSI, Cluster Shared Volumes och självklart blir det mycket PowerShell då det mesta av detta endast kan konfigureras med hjälp av PowerShell.

Notera att dessa seminarium är kostnadsfria

2/7 Anmäl dig till sessionen här >

13/8 Anmäl dig till sessionen här >

Posted in SCVMM, System Center 2012, System Center 2012 R2, Virtual Machine Manager, Windows Server 2012, Windows Server 2012 R2 | Tagged: | Leave a Comment »

 
Follow

Get every new post delivered to your Inbox.

Join 4,036 other followers