0

Fixing “DRS Invocation Not Completed”

I ran into an error today that I haven’t seen before. My vSphere 5.0 cluster displayed the message “DRS invocation not completed” on the Summary tab and, I noticed, it stopped moving VMs around automatically too.

screenshot305

I tried changing some of the DRS settings and running DRS from the DRS tab of the cluster just to try and see if that would get things going but to no avail.

Interestingly, I couldn’t find any mention of the message on the VMware KB site or anything useful in Google. I was tempted to turn DRS off completely and then try re-enabling it but that would have removed my resource pools.

It was then that I noticed that some of the hosts weren’t reporting any memory or CPU utilisation even though I knew them to be hosting VMs.

screenshot307

As an experiment I tried disconnecting and then reconnecting these hosts in turn. Once reconnected I started seeing DRS initiated vMotions occur to rebalance the cluster and the message disappeared from the cluster’s summary tab.

So, I’m not sure why it happened but a simple, non-disruptive solution fixed it.

Just thought I’d share…

0

Do my ESXi hosts have the same VLANs?

PowerCLIIn a small vSphere environment that I’ve recently been working on, I started to notice that some of my VMs were disappearing off the network from time to time. Reboots of the VM didn’t seem to fix the issue but a quick vMotion of the VM to another host did.

If you haven’t figured it out yet, one of my hosts was missing a VLAN and VMs connected to a certain portgroup were affected whenever they ran on the host.

vSphere will warn you if a host that you’re trying to migrate a VM to doesn’t have the right portgroup and host profiles (if you’re using Enterprise Plus licensing) will alert you to the fact that a portgroup isn’t configured with the right VLAN ID but nowhere in vSphere will you get an alert if a required VLAN is not being presented to a host. So you have to use other means to check this information.

You could manually examine the properties of each physical NIC in turn but that could take some time. The method that I used on this occasion was a PowerCLI script. I could have written one myself but a quick google lead me to a script written by Luc Dekens that did what I wanted already (and a little more besides). I modified it to suit my needs (demonstrating to the person in the remote datacenter that there was a network misconfiguration) and ran it. The output is below:

[ps]Host:  esx1.mydomain.com

vmnic0  VLAN224 VLAN227

vmnic1  VLAN224 VLAN227

vmnic2  VLAN250 VLAN252 VLAN251

vmnic3  VLAN250 VLAN252 VLAN251

Host:  esx2.mydomain.com

vmnic0  VLAN227 VLAN226 VLAN224

vmnic1  VLAN227 VLAN226 VLAN224

vmnic2  VLAN251 VLAN252 VLAN250

vmnic3  VLAN251 VLAN252 VLAN250

Host:  esx3.mydomain.com

vmnic0  VLAN224 VLAN227 VLAN226

vmnic1  VLAN224 VLAN227 VLAN226

vmnic2  VLAN250 VLAN252 VLAN251

vmnic3  VLAN250 VLAN252 VLAN251

Host:  esx4.mydomain.com

vmnic0  VLAN224 VLAN226

vmnic1  VLAN224 VLAN226

vmnic2  VLAN250 VLAN251

vmnic3  VLAN250 VLAN251 VLAN252[/ps]

As you can see, there are some discrepancies in which VLANs are presented to the four hosts that I ran it against and vmnic2 on Host4 was the one causing my problems. The hosts are supposed to have the vmnics paired (vmnic0/vmnic1 in one pair and vmnic2/vmnic3 in another) with identical configuration between the hosts.

The modified script that I used is attached below. Many thanks, as always, LucD.

Show-PNICVLANs.ps1

0

Installing SQL 2008 R2 on 2008 R2 Server Core

Following on from previous posts on a similar theme, I wanted to make a quick note of how SQL 2008 R2 is installed on a 2008 R2 Server Core VM.

SQL 2008 R2 has a number of feature dependencies that must be present before an installation can take place. Assuming that you’ve deployed your VM, given it some network settings and joined it to your domain (if you want) then there are three further things you need to address to get SQL installed.

The first is adding some disk space to the VM. If, like me, you deploy Windows server VMs with a reasonable 40Gb of C: drive space you’ll need to add something to have enough room for SQL and some databases. I like to keep databases and log files on separate drives to the main OS so I tend to add extra disks to the VM. I’ve covered that off in a previous post.

Next up – those pesky dependencies. You could do this remotely with Server Manager running on another machine somewhere or you could just use the command line. Hint: if you’ve got the commands written down somewhere then the command line is so much quicker. Just RDP to your 2008 R2 Server Core VM and paste the following into the command prompt:

[text]dism /online /enable-feature /featurename:NetFx2-ServerCore
dism /online /enable-feature /featurename:NetFx3-ServerCore
dism /online /enable-feature /featurename:NetFx2-ServerCore-WOW64
dism /online /enable-feature /featurename:NetFx3-ServerCore-WOW64
dism /online /enable-feature /featurename:IIS-WebServerRole
dism /online /enable-feature /featurename:IIS-ISAPIFilter
dism /online /enable-feature /featurename:IIS-ISAPIExtensions
dism /online /enable-feature /featurename:IIS-NetFxExtensibility
dism /online /enable-feature /featurename:IIS-ASPNET[/text]

The final stage is installing SQL itself. Simply mount the DVD ISO and run setup! Note though that I think SQL 2008 may not be supported on Server 2008 Core versions. SQL 2012 seems to be but I haven’t played with that yet.

0

Adding disks to 2008 R2 Server Core VMs

In a lab environment, sometimes anything can go. Solutions aren’t always standards compliant or don’t always follow best / sensible practices. One that I can’t shake off though is using separate drives in my VMs for operating systems and data. It’s too ingrained.

Given my new found penchant for using Windows 2008 R2 Server Core for VMs in my lab though I hit a little niggle that I thought I ought to note down for when I inevitably forget about it.

When deploying a VM from a template for a specific purpose, it’s natural to add extra disks to it. In the normal version of windows, using the DiskManagement snapin to bring the disk online automatically makes it read-write as well. In Server Core, you can’t use the snapin locally. Firewalls permitting, you should be able to use it remotely (via RSAT tools installed on another machine) but if you’re in a hurry and comfortable with DISKPART then you might be tempted to use that. And that’s where the niggle is.

In DISKPART when you online a new disk, it changes the disk’s state but not whether it is read-only or read-write. And you can’t create a partition on a readonly disk!

So, what do you do? It’s just a couple of extra steps really.

1. In the command prompt window on the VM’s console, start up DISKPART.

2. First, list the disks present on the VM:

You notice that Disk 1 is 100% free but Offline.

3. Next we select that disk and then turn it Online.

If you tried to create a partition now you’d get a fairly non-specific error.

4. Look at the disk’s detail and you see why though.

“Current Read-only State: Yes”, not the clearest way of saying it but the disk is read-only at present.

5. To make the disk writable you need only type ATTRIBUTE DISK CLEAR READONLY.

Now you can create a partition as you normally would.

Job done.

0

Installing VMtools on Windows 2008 Server Core

Not having a full GUI to use, it can sometimes be difficult to install software on Windows 2008 Server Core machines. You need to get used to scripted installations, software distribution methods and / or silent installs.

If you’ve gone as far as initiating the tools installation for a VM you could be forgiven for wondering what the heck you’re going to do next. The install doesn’t autorun (Windows Explorer does this normally but Windows Explorer isn’t there). Even if you run setup64.exe manually it won’t help.

If you run setup64.exe /? though you get a little bit of help.

A typical (and silent) install of VMtools can therefore be performed by running:

[text]setup64.exe /s /v /qn[/text]

The VM will automatically reboot though, just so you know…

Note: Jonathan Medd has a very similar (and excellent) post about installing VMtools on Windows Server 8 Beta.

0

Windows 7 Printer Sharing with a Mac

For quite some time I had my home printer connected to a USB port on one of my ESXi hosts. To save a bit of memory I doubled up my home lab’s AD domain controller as a print server. I did this because the only other non-virtual computer at home capable of printer sharing was running Windows 7 and for some reason I could not get my Mac to work properly with the printer when it was shared from that. (Authentication would fail when trying to connect to it via SMB.)

The downside of this arrangement though was that my AD VM was tied to that single ESXi host. I couldn’t vMotion it without losing the printing functionality – something that my wife quite rightly complained to me about on several occasions! Obviously I should probably just get a new wireless printer and solve the problem that way. Believe me it’s tempting but I so rarely print that it seems slightly wasteful whilst the old printer still works and I was also determined to make it work and bend it to my will.

Finally I did some digging and found a way to make it work. The printer is now shared from the Windows 7 desktop and usable by me and my Mac, my wife from her laptop and the children from the PC itself.

How? Like this…

On the PC:

1. Open The Control Panel.

2. Select “Programs and Features”.

3. Click the link to “Turn Windows Features on of off”.

4. Under “Print and Document Services” enable the “LPD Print Service”. Click “OK”.

5. Finally share your Windows printer as normal.

On the Mac:

1. Open System Preferences

2. Open “Print & Fax”.

3. Click the little “+” icon to add a new printer.

4. In the “Add Printer” dialog select the “Advanced” section.

  • Select “LPD/LPR Host or Printer” as the type.
  • In the “URL” field enter the URL in the format lpd://ipaddressorhostname/printersharename
  • Give the printer a suitable name.

5. Select a driver by selecting “Select Printer Software” from the “Print Using” dropdown (note that I have CUPS+Gutenprint drivers installed to give me a wider selection of drivers).

6. Finally “Add” your chosen printer.

It should be noted that this solution of course requires that the PC be on for printing to be possible. Most of the time the one that I am using is asleep or hibernated and I just give it a poke with a WOL packet generated from a local webpage when I need to print. It’s not like I do a lot of printing anyway.

0

Fixing “HostDatastoreSystem.QueryVmfsDatastoreCreateOptions” Issue

Having recently made a right old mess of my home lab, I set about building it from scratch over the weekend. Having installed some nice, fresh builds of ESXi 5.0 I started adding in my SATA disks and began to create VMFS datastores on the hosts.

The first one worked ok. The second one didn’t for some reason. I got an error part way through the “Add Storage” wizard. The error stack wasn’t too helpful:

Call “HostDatastoreSystem.QueryVmfsDatastoreCreateOptions” for object “datastoreSystem-9” on vCenter Server “svr-vcenter.vspecialist.co.uk” failed.

Continue Reading

0

vCenter Orchestrator Silent Install

Article by Michael Poore (@mpoore)

Is it possible to install vCO on a Windows server silently? Yes.

If you have the EXE file (DVDDrive:vCenter-ServervCOvCenterOrchestrator.exe) available on the server then installing is as simple as:

[text]D:vCenter-ServervCO>vCenterOrchestrator.exe -i silent[/text]

It takes a few seconds to complete but at the end of it the vCO Configuration service is present and running:

Of course that’s just installing vCO, it’s not configured – that’s still to be done (see my earlier article on configuring vCO).

So, what’s the point of doing such an install then? Where’s the benefit? If you look at vCO’s Configuration Maximums it’s not entirely obvious is it?

Item Maximum
Connected vCenter Server systems 10
Connected ESX/ESXi servers 300
Connected virtual machines spread over vCenter Server systems 15000
Concurrent running workflows 150

You’d need a very large environment to *need* more than one vCO server let alone to need a method of automatically deploying them. Either that or a very particular use case.

0

Install vCenter Orchestrator on a Dedicated Server

Article by Michael Poore (@mpoore)

The binaries for vCenter Orchestrator (vCO) come bundled alongside vCenter Server and are installed by default when vCenter is installed. But what if, and it’s probably a better practice, you want to install vCO on a separate server to vCenter. How’s that done?

Before running through that, first let’s cover requirements. vCO server components must be installed on a 64-bit Windows OS. The client component can happily sit on 32-bit. The minimum recommended RAM is 4GB but in a lab or non-production environment you can get away with less depending on if the database is co-located or not. Continue Reading

0

Configuring vCenter Orchestrator

Article by Michael Poore (@mpoore)

vCenter Orchestrator (vCO) is a no charge extra for vCenter Server owners. In fact the binaries are installed alongside vCenter Server itself.

This post covers what you need to configure vCO and start to use it. It’s based on the GA release of vCenter 5.0. (Of course I should point out that other orchestration products are available.) Continue Reading