Thursday, 24 October 2013

Adobe flash on Windows server 2012

To get flash to work on Windows server 2012 you need to enable the desktop experience. The instruction on the Adobe website discuss disabling ActiveX filtering, but this is for Windows 8.

import-module ServerManager
Add-WindowsFeature -name Desktop-Experience,qWave ` -IncludeAllSubFeature -IncludeManagementTools

Thursday, 3 October 2013

Resetting the VMware ESXi trial period

Sometimes I am asked to build a vSphere environment on a trial license from VMware. By default this is 60 days. However after building the environment, updating and testing the trial period will have dropped a number of days. The customer rightly pointed out that this has reduced their trail of the product.

You can use this command at the ESXi shell to reset the trail period back to 60 days.

rm -r /etc/vmware/license.cfg
cp /etc/vmware/.#license.cfg /etc/vmware/license.cfg
/etc/init.d/vpxa restart

Tuesday, 10 September 2013

Check Hyper-V replica status across the cluster

If you would like to check the replication status of all the VMs across your cluster you can use this PwerShell command.

get-clusternode | ForEach-Object  {Invoke-command -computername $_.name -scriptblock {get-VMReplication}} | ft name, State, Health, PrimaryServer

Tuesday, 23 July 2013

Dell M1000e IOM firmware fails from CMC GUI

When trying to update the IOM firmware from the CMC GUI you see the error below. I tried pulling the standby CMC and vice-versa but this did not work either.



Fix:

Connect to the CMC management IP address via putty over SSH, and issue this command.

racadm fwupdate -s -m all

This should list all the modules that require a firmware update.

racadm fwupdate -u -m iominf-1

The command above will update the IOM is A1, so you will need to repeat this if you have more IOMs, changing the last digit. Be warned this command will reboot the switch!





Friday, 19 July 2013

Updating firmware on Force10 MXL Blade IOM

Attach to the switch via a console cable, or the CMC backdoor. Start TFTP on your PC with the firmware in the TFTP root.

Show system brief or show os-version
Conf
Int management 0/0
ip address 1.2.3.4 /24
no shutdown
exit
upgrade system tftp://1.2.3.1/FTOS-XL-8.3.16.4.bin A:
wr
reload
show os-version

Tuesday, 25 June 2013

Migrating public folders from Exchange 2007 / 2010 to another Exchange 2010 server

If you need to migrate to a new Exchange 2010 server; Either from Exchange 2007 or from an old Exchange 2010 installation, for example SBS 2011, you will need to move all the public folders to the new server. 

In this example there are two servers:

new-server and old-server

The first task to complete is to see what public folders are located on the old-server. To do that open the Exchange PowerShell as Administrator and enter:

Get-PublicFolderStatistics | Sort-Object -Descending ItemCount |ft -AutoSize

This gives us an idea of how many public folders there are and the item count. If you run the command on the new-server is should return only one result which is the NON_IPM_Subtree.

On the new-server open the Exchange PowerShell as Administrator and enter:

cd $exscripts


.\AddReplicaToPFRecursive.ps1 -TopPublicFolder “\” -ServerToAdd new-server
.\AddReplicaToPFRecursive.ps1 -TopPublicFolder “\NON_IPM_SUBTREE” -ServerToAdd new-server
This tells the old-server to add the new-server to it's list of servers to replicate public folders to for both System folder and User public folders.

Still on the new server run these commands to check that the new-server will take replicas from the old-server.

Get-PublicFolder \ -Recurse | ft name,parentpath,replicas
Get-PublicFolder \NON_IPM_Subtree -Recurse | ft name,parentpath,replicas

Still on the old-server, we can now tell the old-server to move all it's replicas to the new-server via this PowerShell script:

./MoveAllReplicas.ps1 -Server old-server -NewServer new-server

On the new-server we should be able to see the public folder item count increasing. This can take some time to complete.

Get-PublicFolderStatistics | Sort-Object -Descending ItemCount |ft -AutoSize

Because this was originally a migration from Exchange 2003 to 2010 the 'servers' container was still present in ADSIEDIT.MSC which needed removing to prevent replication back-fill from failing.

Hyper-V LiveMigration fails with Live migration did not succeed at the source

I built a Hyper-V 3.0 cluster for a customer moving away from SBS 2011. The cluster was created successfully but live migration was failing with these errors:

"Live migration did not succeed at the source"

"Failed to authenticate the remote node: The specified target is unknown or unreachable (0x80090303)"

The cluster validated without a problem. All the sources were pointing to a mismatch in Hyper-V Network name and vSwitch name. I knew this wasn't the issue as I have used the same PowerShell script to create the network team and vSwitch.

When i looked in the Event Viewer at the Hyper-V-VMMS log I could see the the SPN was not able to register on the SBS 2011 domain controller.



When I used SETSPN -L Hyper-V-node I could see that the Hyper-V SPNs were missing.  I checked the permissions on each node to make sure that 'SELF' has the permission "Validated write to service principal name" but that was correctly set.

I saw on forums that others with a SBS 2011 domain had the same issue. In the end, I worked around the issue by manually adding the required Hyper-V SPNs in AD.

Below are the correct SPNs for Hyper-V 3.0:

Microsoft Virtual Console Service/Hyper-V-node
Microsoft Virtual Console Service/Hyper-V-node.domain.local
Microsoft Virtual System Migration Service/Hyper-V-node
Microsoft Virtual System Migration Service/Hyper-V-node.domain.local
Hyper-V Replica Service/Hyper-V-node
Hyper-V Replica Service/Hyper-V-node.domain.local

After adding the SPNs for both cluster nodes manually on each computer object in DSA.MSC the Live Migration started working :) I did see that the Event ID 14050 were still appearing :( Later in the project a new Windows 2012 DC was added and the 14050 events stopped.

I can only guess this is an issue with the bespoke permissions/policies that Microsoft have built into the SBS solution. This will be an issue moving forward as companies move away from SBS now M$ has killed it off.

http://social.technet.microsoft.com/Forums/windowsserver/en-US/2b80845a-94de-4fc4-8963-ac8e7b41fca6/server-2008-r2-hyperv-live-migration-did-not-succeed-at-the-source-vmname-failed-to-migrate