ScorpioTek Solutions
07-filler-left Information about ScorpioTek Services Offered by ScorpioTek Training Courses Offered by ScorpioTek Technology Blog by ScorpioTek Contact us for more information on training/services 08-filler-right

Archive for the ‘Uncategorized’ Category

Fix Live Migrations on Hyper-V 2012 when starting the LM from another computer

Tuesday, February 19th, 2013

This is not a very common case, nontheless I though I’d post in case someone faces the same issue.

This is my scenario:

  • I have one Hyper-V host (HostA) with VMs that I want to move to another host (HostB)
  • I’m doing this via PowerShell on a computer that is not HostA or HostB, I’ll call it ScriptComputer
  • I have enabled Live Migration on HostB
  • I have configured constrained delegation from HostA to HostB

When I tried the Live Migration, I got the following:

The Virtual Machine Management Service failed to establish a connection for a Virtual Machine migration with host ‘HostB’: No credentials are available in the security package (0x8009030E).
Failed to authenticate the connection at the source host: no suitable credentials available.

After battling for a bit, I configured constrained delegation on the ScriptComputer and the Live Migration finished successfully.  Seems like regardless of what the host is, the machine that starts the LM must have constrained delegation configured.


Remote Connection Failure After Upgrading WS 2008 R2 to WS 2012

Saturday, January 12th, 2013

I have been working on upgrading 40 servers from Windows Server 2008 R2 to Windows Server 2012.  The process is fairly straightforward:

  1. Remotely connect to Server
  2. Launch the WS2012 setup.exe
  3. Follow instructions

After starting the upgrade, the servers rebooted and I just waited for them to finish.

About an hour or so, I tried to remotely connect to the server with no luck.  I was able to ping them, and after going to the Datacenter, I noticed that it had WS2012 installed and had a valid IP – what gives?

After messing with the Firewall, I noticed that two Remote Desktop rules in the inbound Firewall rules were enabled and one Remote Desktop rule was enabled:

The two disabled Firewall rules

Enabling these rules allowed me to remotely connect again to the servers.

If you do not want to physically access the servers to make this change, you can always open an MMC console and create a Firewall Snap-In connected to the remote computer where you will be able to make these changes.

Additionally, you can enable the following rule before going through the upgrade in WS 2008 R2:

Disabled RDC Firewall Rule in Windows Server 2008 R2


HPC Server 2008 Heat Map Resuscitation: Now with more Vitamins

Saturday, June 5th, 2010

In a previous post, I cranked up a script using PowerShell and psexec to fix the heat map problems that may happen with Windows HPC Server 2008. The script waited for each node to complete, which could take hours to perform if your cluster is big.

In order to solve this problem, I upgraded the head node’s PowerShell to v2.0 (HPC Server ships with PowerShell 1.0) and was now able to use the Start-Process process. This leads to having the script run in no time at all. Here is the code:
#Uncomment line below if running from a regular PowerShell Window
#Add-PSSnapin "Microsoft.HPC"
#Change the HPC-HN value below to match the name of your head node

#Obtain Compute Nodes
$nodes = Get-HpcNode -GroupName ComputeNodes

Write-Host "Setting Head Node To:" $HEAD_NODE
#Stop Head Node Services
Stop-Service -Force HpcManagement
Stop-Service -Force HpcNodeManager
Stop-Service -Force HpcSdm

$services = "HpcManagement", "HpcNodeManager"
#Stop the services on all compute nodes
foreach ($node in $nodes)  {
foreach ($service in $services) {
 $serviceStop = "net stop $service"
 $computer = $node.NetBiosName
 $computer = "\\$computer"
 Write-Host ("Executing command: psexec " + $computer + " " + $serviceStop)
 Start-Process psexec -args ($computer + " " + $serviceStop)

Write-Host("Waiting 10 seconds for services to stop")
#Change the value below if you have a large number of nodes

foreach ($node in $nodes)  {
foreach ($service in $services) {
 $serviceStart = "net start $service"
 $computer = $node.NetBiosName
 $computer = "\\$computer"
 Write-Host ("Executing command: psexec " + $computer + " " + $serviceStart)
 Start-Process psexec -args ($computer + " " + $serviceStart)
Write-Host("Waiting 20 seconds for services to start")
#Change the value below if you have a large number of nodes
#Start Services on Head Node
Start-Service HpcManagement
Start-Service HpcNodeManager
Start-Service HpcSdm
Write-Host("Your nodes should show up in the heat map in a about a minute")
And of course, we need to have a video. Here is the script in action with 4 nodes that are not displaying their info on the heat map:

Snow Leopard is a Mess

Sunday, August 30th, 2009

Like many Apple fanbois did yesterday, I took the plunge and installed Snow Leopard (10.6), Apple’s next release of it’s operating system, the successor of Leopard (10.5). The install was very straightforward, no issues, fairly easy and in no time I was running the new cat.

I am going to avoid the “I really wanted to like Snow Leopard” cliché and admit that I was ready to dislike the snow feline. I had played with a pre-release version of it about 2 months ago and I was not impressed. Apple claimed that this update, was not rich in features but mostly optimizations made under the hood, such as taking advantage of multiple cores in systems and 64-bit technology. When I heard that, my immediate reaction was “this update is going to suck”.

Let’s start with the good: The OS boots faster, apps launch faster and that’s about it. There have been some refinements made to the dock, such as a change in the appearance, and stacks having some tweaks to make it more usable:

These features, while nice to have, are something one would expect from a minor update, not something marketed as something new of the OS.

The services menu that no one ever uses has also changed in the hopes of being used more, which is not going to happen anytime soon.

That’s it, from my perspective, those are the features that make me feel I’m not using Leopard. Would it really have killed Apple to update the dreaded, old as mold Finder? This so called ‘file manager’ cannot cut files, it does not have tabs, and pales in comparison with Pathfinder from CocoaTech, which makes the best file manager in the world, period.

In terms of stability, Snow Leopard feels like it was not tested enough. This message has been popping on my screen every minute:

Problem Report for trustevaluationagent.jpg
I have looked everywhere, posted on the forums and have yet to receive an answer. If I just let it sit there, it won’t pop up anymore, but eventually I will lose keyboard input for a while, and that is perfectly fine because who needs the keyboard to work to start with?

The whole 64-bit is kind of flawed, as Macs that are not Xserves will boot by default on 32-bit mode unless you press 6 & 4 at boot time. Doing so will have an adverse effects with any system prefs that are not 64-bit mode. One of the best monitoring applications, Menu Meters, will not work in Snow Leopard because of this.

My frustration has reached new levels and as soon as I finish publishing this post, I am downgrading (fortunately, doing so on OS X is a piece of cake). I think I would wait for 10.6.1 but then again I thought “Why?”. There is no killer feature in this OS that makes upgrading worthwhile. Even at $29, this upgrade is a ripoff. The features implemented here are analogous to Vista’s SP2, and that my friends, was a free upgrade.

Then there’s the whole debate of comparing Snow Leopard with Windows 7, to which I say ‘don’t even bother’. Windows 7 has a plethora of under-the-hood features (on-demand background services, multithreading capabilities, etc.) as well as lots of features on the GUI. Even though it’s ‘Vista done right’, it feels like a new OS, which is not the case with Snow Leopard.

I really cannot stress enough how much I recommend NOT going for the Snow Leopard upgrade. It lacks in every department one would expect from an OS update, let’s hope whatever cat is next delivers more than this so-called ‘OS update’.

Compiling Parallel Extensions Samples from CTP Release in VS2010

Saturday, August 22nd, 2009

This might be a bit obvious to some but just in case I’m posting it anyways. If you have some code that you wrote for parallelizing your application with the CTP of the Parallel Extensions of .Net and compile in Visual Studio 2010 Beta1, you might get the following:

Error 1 The name ‘Parallel’ does not exist in the current context ….

Looking at your references folder, you will find that System.Threading is no longer available. So before rushing out and installing CTP on VS2010, which would probably be a big mess, just get properties on your project and specify to compile for the .Net 4.0 Framework:

How to Continue Using the CTP of Visual Studio 2010

Tuesday, June 30th, 2009

When you download the CTP of Visual Studio 2010, you will notice that when configured under Hyper-V, will prompt you with the following error message:

The evaluation period for Visual Studio Trial has ended.

Click Upgrade to find out how you can continue to use the application by purchasing a full edition.

The workaround for this is very straightforward: set your date to November 2008 and that’s it. If you are doing this change and the date reverts back to today, then you must make sure the following conditions are met:

  1. The option to Synchronize with an Internet time server (on the guest) is disabled.
  2. In Hyper-V, Time Synchronization with the guest has to be disabled:


Once you’ve made these changes, Visual Studio 2010 CTP will launch w/o any issues.

Hyper-V Additions in Visual Studio CTP 2010

Tuesday, June 30th, 2009

Not so long ago Microsoft released a CTP of Microsoft Visual Studio 2010. The release was made through a VHD that you could download and try on your computer. The VHD contained the additions for Virtual PC pre-installed. Yes, yoy heard that right, Virtual PC 2007.

Why was a VPC 2007 image chose over Hyper-V is well beyond me, but this is somewhat ironic considering the fact that VS 2010 has lots of tools for building multi-core applications and VPC has support for just one processor. This means that no matter how your application is written to multitask in VS2010, you will only see the performance of 1 proc/core -which defies the whole purpose.

The VHD can be modified to work with Hyper-V. It’s just a matter of removing the VPC additions from the Programs and Features control panel and then installing the Hyper-V additions. Unfortunately, the modified HAL will not be picked out of the box by the OS, so you need to tweak something else.

Open a run command and type msconfig, access the Boot tab, then Advance Options and make sure rthe Detect HAL option is selected.


Once you reboot with Hyper-V additions installed, it will detect the new HAL and your changes will take place.

Perhaps your question now is “why on Earth are you using the CTP given that Visual Studio 2010 Beta 1” is available? We need to run some screencasts on the Concurrency Runtime (CRT), and unfortunately Beta 1 does not offer support for C++0x lambdas, which makes working with CRT a lot simpler.

[June 30, 2009, 5:27 PM: Christian Saborío] : Just found this blog post that explains this process in detail: Converting VS2010 CTP to Hyper-V

Microsoft Campus Maps

Monday, June 16th, 2008

Microsoft campus is huge. The following maps are a great way to get around:

Main Campus:
West Campus:
North Campus:

Just in case the links die someday:

Main Campus


West Campus


North Campus


How to Write a Custom Validator for the Validation Application Block : Prerequisites

Saturday, March 15th, 2008

in the land of all things geek, The Code Project, I found a nice page explaining how to create a custom validator using the Validation Application Blocks from Microsoft. I was about to start the lab and on step 1 I was lost…nice.

The problem is, IMHO, that it has not been documented on what is needed to create a custom validator. So, here is what you need to do:

Once I made those changes, I was able to get to Step 2!!!

Now this is what I am up against:


At this point, this is how I feel like:


[March 14, 2008, 11:06 PM: Christian Saborío] :

The problem is circumvented by selecting Provider Library (C#) No tests:



How to Debug a COM EXE consumed by a Managed Application

Thursday, November 29th, 2007

Today I was working on creating a COM EXE that would be used by a managed application. Everything was going fine until my COM exe crashed and I needed to find what was wrong. After some help from Phil, I was able to get debug the COM exe in no time.

Before I start, let’s see what you will need:

  1. A Visual Studio instance with your COM exe set as your start project (this will be referred to from here onwards as the COM project)
  2. A Visual Studio instance with your managed application set up as the start up project (this will be referred to from here onwards as the Managed project)

Here is what you need to do:

1. From the COM project, got to the place where you would like to stop and set a breakpoint:

2. Press F5 in your COM project to start debugging

3. Press F5 in your Managed project to start debugging

The breakpoint will be hit and you will be on your way:

Seems pretty straightforward, huh? The main issue I had was that I had my COM project and Managed project inside the same solution, and apparently it was not possible to debug managed and unamanaged code like that. If you know a way around this, please let me know!