When software attacks!

Thoughts and musings on anything that comes to mind

Speaking on DevOps at Future Decoded

I am now going to speaking on the DevOps track at Future Decoded. I’ll be channelling Richard to talk about how our dev-release pipeline is constructed at Black Marble and how the various Microsoft tools that we use could be swapped out for alternatives in a heterogeneous environment.

Whilst this isn’t an area that I usually speak around, it’s something that I am very involved in as Richard and I constantly look to improve our internal practices around development, test and deployment. Big thanks to Susan Smith for inviting me to participate.

If you haven’t come across Future Decoded yet, take a look. It spans a number of days, with the final day being the multi-track technical conference that I will be speaking at, along with such luminaries as Jonathan Noble and the usual DX suspects like Andrew Fryer and Ed Baker.

Hope to see you there!

A week with the Surface Pro 3

Robert unexpectedly (gotta love him!) gave me a surprise present in the form of a Microsoft Surface Pro 3. I’ve now been using it for a week and I thought it was time to put my thoughts into words.

You’ll pry it out of my cold, dead hands

Overall, this is a fantastic bit of kit and it’s the device I have used most at home, for meetings and even sometimes at my desk. The only reason it hasn’t replaced my stalwart ThinkPad X220T is that it has neither the memory nor the storage to run the virtual machines I still need. It’s light, comfortable to hold, has great battery life and the screen is gorgeous.

Specs – good enough?

The model I have is the core i5 with 8Gb of RAM and a 256Gb SSD. It’s quick. It also has ample storage for my needs once I remove VMs from the equation. It’s true – Visual Studio hasn’t been installed yet, but I know from conversations with Robert that I am not space-poor.

It’s quick to boot up – quick enough that I rarely bother with the connected standby and usually shut down fully. It has handled all of my Office-centric tasks without pause, from Word through PowerPoint to the ever-present OneNote. The screen is a pin sharp 2160x1440 which is easy to read when typing (although there are a few apps that appear a little blurry from the display scaling), although as with many other devices, the glossy glass screen can suffer from reflections in very bright sunlight.

I’m also very happy with the keyboard. I’m typing this post in my front room, sat on the sofa with the Pro on my lap. The revised ‘any-position’ kickstand makes it much more comfortable than the Surface and Surface Pro – neither of which I would have endured this process with. The new ‘double fold’ design of the type cover makes it less sit at a better angle than its predecessors. Yes, it still flexes on a single hinge when on my lap, but it does feel more stable than before.

The track pad is also much improved. I now have a collection of covers – touch, type and power, along with the new type cover. The power cover is great fgor battery life but the track pad was an abomination. This one is just fine – it feels good to touch, with enough resistance to the surface texture, and the buttons have a responsive click to them.

Shape and size

The first thing you notice about the Pro 3 is the size of it. It’s no thicker than my original RT and half the thickness of the original Pro. It’s also a different shape, and I think it’s that which makes all the difference. No longer 16:9, the device is very comfortable to use in portrait mode – much better than the Pro, although I tended to use that in portrait too. When you aren’t wanting to type, you naturally stand it on the short edge. Microsoft obviously expects that – the Windows button is on the right hand edge as you look at the tablet when using the type cover.

It’s also really light. Much lighter than the Pro, and it even feels lighter than the RT. I suspect the thickness of the glass helps a great deal, but it’s pretty impressive when you think that they’ve packed the same power as the Pro in to half the weight, half the thickness and managed to increase the battery life at the same time.

Battery Life

I’ve not run exhaustive battery tests, but I can report that I have charged the surface about three times during the week. It lasts all night when reading web pages, using the twitter app and other Windows Store applications; it quite happily ran through a four hour meeting with a copy of Word open (try doing that on a generation 1 Pro) so, thus far I’m impressed. I haven’t yet tried to last a full working day on a charge, though.

The Stylus

I was concerned when Microsoft switched from the Wacom technology used by the older Surface Pro to the new Ntrig active pen. I have been very pleasantly surprised, however. The inking experience is wonderful. The pen has a very soft feel to it – very unlike the Dell Venue 8 Pro and better even than the Wacom. I do miss being able to erase by flipping the pen, but having used the two-button Dell pen for six months now the switch wasn’t an issue. The accuracy of writing is great. Supposedly the distance between the LCD display and the surface of the glass has been reduced and I must say that the feel of writing is good – the lines I draw feel closer to the pen tip than the Dell, certainly.

My one little niggle

I only have one problem, and to be fair it’s pretty minor. One of the things I use the original Pro for is pulling photos off the SD card from my Canon EOS 450D. The new Pro, with it’s better screen would be great for that task. Except I can’t, because the SD card slot present on the Pro has gone, replaced by a MicroSD slot in the same place as on the RT. It makes sense for space, but it’s a bit of a pain. Time to try using a MicroSD card with adapter in my camera, I guess – I don’t really want to carry a USB adapter.

You’d think that I’d miss a physical ethernet port (I don’t – I can use a USB one if I need to ) or bemoan the single USB 3 port (if I’m stuck, my USB 3 ethernet dongle is also a hub, and how often do I need to use more than one USB device, since this thing has a keyboard and track pad!), but it’s the SD card which is the only thing I’ve wished had been present.

A panoply of devices

I’ll admit to being a device fiend. I now have an original Surface RT, a generation one Surface Pro and a Dell Venue 8 Pro. Of those, the RT has been used rarely since I got the Dell, although the Pro was something I would turn to regularly at home to work on, being larger than the Dell and lighter than the X220T (although with the Power Cover on, we could debate that).

Since I got the Pro 3, I haven’t touched anything else. As I said, I still use the X220T, because I have no alternative. Yes, I could run VMs in Azure or on our Hyper-V server, but the neither work without an internet connection and it’s quick and easy to roll forwards and backwards between checkpoints when VMs are on your own machine.

The fact that I haven’t touched the Dell is perhaps the saddest part of this. I find myself reaching for the Pro 3 every time. I am still using OneNote rather than typing or using paper, but the Pro 3 is nicer to write on than the Dell. Whether I will still use the Dell for customer meetings, where the size means I can leave my usual rucksack of equipment behind I have yet to find out, but it’s a telling change.

Dig a little deeper – enterprise ready?

Pretty much the first thing I did with the new device was wipe it clean. We have a Windows 8.1 image at Black Marble that we usually push out with SCCM. I grabbed that image, downloaded the Surface Pro driver pack from Microsoft and used dism to install the drivers into the image. I then deployed that image onto the Pro via USB.

Installation was completely painless, even including the automated installation of some firmware updates that were included in the driver pack. All devices were detected just fine and the end result is a Surface Pro 3 with our Enterprise image, domain-joined and hooked up to our DirectAccess service so I can work anywhere.

I have installed Office, but I will admit to not having used Outlook on this yet. Much of my usage has been in tablet mode and I prefer the Windows 8.1 Mail app over Outlook without the keyboard and trackpad. Office 2013 is not yet fully touch-friendly, whatever they try to tell you.

You know what would make it perfect?

You can see this coming, can’t you? Sure, I could get more storage and horsepower with the top-of-the-line model, but there is no point. The only reason I would need those is if I could have my one wish – 16Gb of RAM.

It’s s terrible thing – no Ultrabooks come with 16Gb of RAM. I don’t need a workstation replacement (like the W530s our consultants use) as I don’t run the number or size of VMs they do. But I, like Richard, do run VMs for demos and working on projects. 8Gb doesn’t cut it. 16Gb would be fine. I firmly believe that there is a market for a 16Gb ultrabook. Or a 16Gb Pro 3. In all honesty, I think I’d be happy with this as my one device, if I could solve the RAM problem. I think that says it all, really.

SharePoint 2013: Creating Managed Metadata Columns that allow Fill-In Choices

This is a relatively quick post. There’s a fair bunch of stuff written about creating columns in SharePoint 2013 that use Managed Metadata termsets. However, some of it is a pain to find and then some. I have had to deal with two frustrating issues lately, both of which boil down to poor sharepoint documentation.

 Wictor Wilén wrote the post I point people at for most stuff on managed metadata columns, but this time the internet couldn’t help.

First of all, I wanted to create a custom column which used a termset to hold data. This is well documented. However, I wanted to allow fill-in choices and could I make that work? My termset was open, my xml column definition looked right, but no fill-in choice. Update the column via the web UI and I could turn fill-in on and off with no problem. In the end, I examined the column with PowerShell before and after the change. It turns out (and this is not the only place they do it) the UI stays the same, but the settings changed in the background are different. For metadata columns the FillInChoice property is ignored – you must add a custom property called Open:

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
  <Field
       ID="{b7406e8e-47aa-40ac-a061-5188422a58d6}"
       Name="FeatureGroup"
       DisplayName="Feature Group"
       Type="TaxonomyFieldType"
       Required="FALSE"
       Group="Nimbus"
       ShowField="Term1033"
       ShowInEditForm="TRUE"
       ShowInNewForm="TRUE"
       FillInChoice="TRUE">
    <Customization>
      <ArrayOfProperty>
        <Property>
          <Name>TextField</Name>;
          <Value xmlns:q6="http://www.w3.org/2001/XMLSchema" p4:type="q6:string" xmlns:p4="http://www.w3.org/2001/XMLSchema-instance">{b7406e8e-47aa-40ac-a061-5188422a58d6}</Value>
        </Property>
        <Property>
          <Name>Open</Name>
          <Value xmlns:q5="http://www.w3.org/2001/XMLSchema" p4:type="q5:boolean" xmlns:p4="http://www.w3.org/2001/XMLSchema-instance">true</Value>
        </Property>
        <Property>
          <Name>IsPathRendered</Name>
          <Value xmlns:q7="http://www.w3.org/2001/XMLSchema" p4:type="q7:boolean" xmlns:p4="http://www.w3.org/2001/XMLSchema-instance">false</Value>
        </Property>
      </ArrayOfProperty>
    </Customization>
  </Field>

  <Field
    Type="Note"
    DisplayName="FeatureGroupTaxHTField0"
    StaticName="FeatureGroupTaxHTField0"
    Name="FeatureGroupTaxHTField0"
    Group="Nimbus"
    ID="{164B63F0-3424-4A9B-B6E4-5EC675EF5C75}"
    Hidden="TRUE"
    DisplaceOnUpgrade="TRUE">
  </Field>
</Elements>

Whilst we’re on the subject, if you want metadata fields to be correctly indexed by search, the hidden field MUST follow the strict naming convention of <fieldname>TaxHTField0.

When using the content by search web part, what gets indexed by search is the text of the term in the column within the content type. However, if you enter a search query wanting to match the value of the current page or item what gets pushed into the search column is the ID of the term (a GUID), not the text. It is possible to match the GUID against a different search managed property, but that only gets created if you name your hidden field correctly. Hat-tip to Martin Hatch for that one, in an obscure forum post I have not been able to find since.

Automating TFS Build Server deployment with SCVMM and PowerShell

Richard and I have been busy this week. It started with a conversation about automating the installation of new build servers. Richard was looking at writing PowerShell to install and configure the TFS build agent, along with all the various SDKs that we use across all out projects. Our current array of build servers have all been built by hand and each has a different set of SDKs to build specific project types. Richard’s aim is to make a single, homogenous build server configuration so we can then scale out for capacity much more quickly than before.

Enter, stage left, SCVMM. For my part, I’ve been looking at what can be done with VM Templates and, more importantly, service templates. It seemed to me that creating a Build Server service in SCVMM with a standard template would allow us to quickly and easily add and remove servers to the group.

There isn’t much written about the application/script side of SCVMM server templates, so I thought I’d write up my part.

Note: I’m not a System Center specialist. We use Config Manager, Virtual Machine Manager and Data Protection Manager at Black Marble for our own services rather than being a System Center partner.

Dividing up the problem space

Our final template uses a single PowerShell script to perform the configuration and installation work. Yes, I could have created steps in the service template to install each of the items Richard’s script deployed, but we decided against that. The reasoning is relatively simple: It’s much easier to modify the PowerShell script to add, remove or change the stuff that gets deployed. It’s hard to do that with SCVMM, as far as I can tell.

However, during testing I discovered that if I added windows roles and features through the template it was faster than when the various installers Richard called in his script triggered the feature addition.

The division of labour, then, became the following:

SCVMM Tasks:

  • VM Template is created for the target OS. The VM template is configured to automatically join the new machine to our domain and place the machine in the correct OU. It also sets the language correctly. More on that later.
  • Service Template is created for a Build Servers service. It’s a single tier service that has a minimum of one machine and a maximum of twenty (that maximum is a bit on an arbitrary value on my part). The service template adds the roles and features to the machine definition and runs two script application blocks:
    • The first simply runs xcopy to pull the contents of a folder on a share to the local PC. I do this because running a power shell PowerShell script from a network share doesn’t work – in an interactive session you are prompted before the script executes because it’s from an untrusted location and I haven’t worked out how to suppress the prompt yet.
    • The second application executes powershell.exe and feeds in the full path to Richard’s PowerShell script, newly copied onto the local disk.

Step 1: VM Template

There’s a wealth of information about creating VM templates in the internet, so I’m not going to cover this in depth. I did, however, want to pull out a couple of things I discovered along the way.

I installed my base VM with the UK English regional settings. When SCVMM converted that into a template via sysprep, the resulting machine comes up in English US, which is really annoying. Had I been paying attention, I would have noticed that we already had an unattend.xml file to correct this, which I could have referenced in the VM template settings. However, I found a much more interesting way to address the issue (which of course led me down another rabbit hole).

A bit of research led me to a very interesting post by Gunter Danzeisen. In it he shows how to use powershell to modify an unattendsettings property of the VM template within System Center. This is at the same time both irritating and enlightening.

It’s irritating, because I am truly fed up of ‘hidden’ functionality in products that causes me pain. The VM Template clearly allows me to specify an unattend.xml file, so why have an internal one as an object property. Moreover, why not simply document it’s existence and let me modify that property – why do I need two different methods which then makes me constantly wonder which gets priority.

It’s enlightening, because I can modify that property really easily – it’s simply a collection of name/value pairs that marry against the unattend.xml settings.

There is a bit of snag with this approach, however, which I’ll come onto in a little while.

Anyway, back to the plot. I followed Gunter’s advice and used PowerShell to set the language values of the internal unattend. I then decided to use the same approach to see if I could add other settings – specifically the destination OU for the server when added to AD.

The PowerShell for the region settings is below:

$template = Get-SCVMtemplate | where {$_.Name -eq "My VM Template"} 
$settings = $template.UnattendSettings; 
$settings.add("oobeSystem/Microsoft-Windows-International-Core/UserLocale","en-GB"); 
$settings.add("oobeSystem/Microsoft-Windows-International-Core/SystemLocale","en-GB"); 
$settings.add("oobeSystem/Microsoft-Windows-International-Core/UILanguage","en-GB"); 
$settings.add("oobeSystem/Microsoft-Windows-International-Core/InputLocale","0809:00000809"); 
Set-SCVMTemplate -VMTemplate $template -UnattendSettings $settings

For reference, removing a setting is easy – simply reference the name of the setting when calling the remove method:

$settings.remove("oobeSystem/Microsoft-Windows-International-Core/UserLocale"); 

I then set the destination OU with the following setting:

$settings.add("specialize/Microsoft-Windows-UnattendedJoin/Identification/MachineObjectOU","OU=FileServers,DC=mydomain,DC=local"); 

The Snag

There is a problem with this approach. If you use an unattend.xml file, you can override that setting when you add the VM template to your service template. However, whilst I could find the unattendsettings property of the VM when referenced by the template, I couldn’t modify it.

If we access the Service Template object with:

$svctemplate = Get-SCServiceTemplate | where {$_.name -eq "TFS Build Service"}

We get an object that contains one or more ComputerTierTemplates (depending on how many tiers you gave your service). Each of those has a VMTemplate object that holds the information from our original VMTemplate, and therefor has our unattendsettings.

$svctemplate.ComputerTierTemplates[0].VMTemplate.UnattendSettings

So, we can grab those settings and modify them. Great. The trouble is, I haven’t found a way to update the stored configuration. Set-SCServiceTemplate doesn’t let me stuff the settings back in the same was as Set-SCVMTemplate does, and you can’t use the latter with a reference to the VMTemplate child of our template.

Now, I decided that I would create a copy of my original VM template just for Build Servers, so I could set a different target OU for the servers. In hindsight, I’m not sure whether this is better than overlaying unattend.xml files, and I haven’t experimented with how the unattend.xml might interact with the unattendsettings yet either. If you try, please let me know how you get on.

Step 2: Service Template

Once I’d got my VM Template sorted, the next step was to create a service. There’s a pretty nice design surface for these that allows you to pick a ‘starter’ template with the right number of tiers, although it’s dead easy to add a new tier.

I started with the Single Machine template, which gave me a single tier. You then need to drag a VM template from a list of available templates onto the tier. The screenshot below shows my single tier Service. The VM template has a single NIC and is configured to connect to my Black Marble network.

image

The light blue border on the large box (the service tier) indicates it’s selected. That will show the tier properties at the bottom of the design window. In here I have set a minimum and maximum number of servers that can be deployed in the tier.

image

Notice also the availability set option – if I needed to ensure that VMs in this service were spread across multiple hosts for resilience I could tick this option. I don’t care where build servers get deployed (they go onto our Lab VM hosts and are effectively ‘disposable’) so I have left this alone.

Open the properties of the tier (right-click or choose View All Properties in the property pan) and a dialog opens with machine properties. In here I have configured the roles and features for the build server (I deliberately haven’t set these in the VM Template so I can have fewer, more general VM templates).

image

Also in here are the Application Configuration settings that cause the VM to run Richard’s PowerShell. The first is a simple one that references cmd.exe to run xcopy. All the settings on this are default.

image

The second app runs Powershell.exe and passes in a file parameter. This was a source of much frustration – I wanted to use the –ExecutionPolicy parameter to ensure the script ran successfully but if I added this (as the first parameter, –File has to be the last one) the whole command failed. As it happens I set the execution policy in Group Policy for all the Build Servers but I like the belt and braces approach.

The biggest point here is the timeout setting. Richard’s script can take an hour or so to run, so the timeout is a BIG number. The first few times I deployed the script task failed because of this, although in reality the script itself was still running happily and completed fine.

image

I have changed the advanced settings for this script, though. To make debugging a little easier (the VM is a black box whilst deploying, so it’s tricky to see what’s going on) I have directed standard output and standard errors to a file. I’ve also turned off the options to automatically ‘detect’ failures through watching output, error and exit codes. Richard’s script can be run repeatedly with no ill-effect, so I’ve left the restart option to restart the script. That means that if I restart the deployment job from SCVMM if it fails, the script will be run.

image

Once the service template is created, I deployed the service with a single server. We then added a second server by scaling out the tier.

image

We can do this via the SCVMM console, or using the virtualmachinemanager PowerShell module:

$serviceInstance = Get-SCService -Name "TFS Build Servers"
$computerTier = Get-SCComputerTier -Service $serviceInstance | where { $_.Name -eq "TFS Build Server" }
New-SCVirtualMachine -ComputerTier $computerTier -Name "Build03" -Description "" -ReturnImmediately -ComputerName "Build03" -StartAction "NeverAutoTurnOnVM" -StopAction "SaveVM"

Lessons Learned

It’s been an interesting process overall. I think we’ve made the right choice in using a single, easily modifiable powershell script to do the heavy lifting here. Yes, I could have created Application Profiles in SCVMM for each of the items Richard installed, but it would have been harder to make changes (and things like the Azure SDK are updated faster than I can blink!).

I’m still considering whether my choice of adding the domain location to the unattendsettings in the VM template object was a good choice or not. I’m happy that the language settings should go in there – we never change those. I need to experiment with how adding an unattend.xml file affects the settings in the template object.

Service Templates are a great way to go. When you think about it, most of our IT systems tend to be service-focused. Using service templates for things like SharePoint or CRM are a no brainer, but also things like web servers, where we have a number of relatively heterogeneous VMs that host internal web services or sites. Services in SCVMM collect those VMs into manageable groups that can be easily spread across multiple hosts for resilience if required. It’s also much easier to find VMs in services than in a very long list of hosts!

In terms of futures, I’m interested in where Desired State Configuration will take us. Crafting the necessary elements for this project would be extremely complicated with DSC right now, but when all the ducks are in order it should make life much, much easier, and DSC is certainly on my learning list.

Safely modify SharePoint 2013 Web.Config files using PowerShell

One of the things we learn early in our SharePoint careers was not to manually edit the web.config files of a web application. SharePoint involves multiple servers and has its own mechanisms for managing web.config updates.

Previously, I’ve created xml files with web.config modifications and copied those to each WFE. Those changes are merged into the initial web.config by SharePoint.

I’ve always been vaguely aware of there being a better way, but never needed to track it down from an IT point of view. Last week, however we wanted to change a setting to enable blobcache on the servers hosting a particular web application so decided to use the opportunity to figure out a ‘best way’ to do this.

Enter, stage left, the SPWebConfigModification class (note, that link is to SharePoint 2010, but SP2013 works the same way).

We can create a collection of configuration changes that get applied by SharePoint via a timer job. That collection is generated through code and is persistent – we can add and remove changes over time, but they are stored in the farm config and will get applied each time we add a new server or update the web application IIS files.

A search of the web turned up an article by Ingo Karstein that had the right approach but brute forced everything by referencing SharePoint DLLs directly. A bit of experimentation showed that we didn’t need to do this – SharePoint PowerShell has everything we need.

Sample code is below. The code will first enumerate the collection of SPWebConfigurationModifications for our web application and remove any that have the same owner value as our script uses. It then adds a new modification to set the value of an attribute (the blobcache ‘enabled’ setting) to true. More modifications can be added into the script and these will be added to the collection. The mods are applied by SharePoint in sequence.

It needs some tidying but it works well. Read the documentation on how the modifications work carefully – it’s possible to work with an element or an attribute and you can add and remove stuff. Remember that other solutions may be adding modifications as well – make sure you don’t remove those.

As always, this stuff is provided ‘as is’ and I am not responsible for the damage you can wreak on your SharePoint farm. Test first and make sure you understand what this code does before using on production.

# Load SharePoint PowerShell PSSnapIn and the main SharePoint .net library
Add-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue

#set a few variables for the script
$owner = "NimbusPublishingModifications"
$webappurl = "https://share2013.proj.local/"

#Get the web application we want to work with
$webapp = get-spwebapplication $webappurl

#get the Foundation Web Application Service (the one that puts the content web apps on servers)
$farmservices = $webapp.Farm.Services | where { $_.TypeName -eq "Microsoft SharePoint Foundation Web Application" }

#get the list of existing web config modifications for our web app
$existingModifications = @();
$webapp.WebConfigModifications | where-object { $_.Owner -eq $owner } | foreach-object { $existingModifications = $existingModifications + $_}
#remove any modofications that match our owner value (i.e. strip out our old mods before we re-add them)
$existingModifications | foreach-object{ $webapp.WebConfigModifications.Remove($_) }

#create a new web config modification
$newModification = new-object "Microsoft.SharePoint.Administration.SPWebConfigModification"
$newModification.Path = "configuration/SharePoint/BlobCache"
$newModification.Name = "enabled"
$newModification.Sequence = 0
$newModification.Owner = $owner
$newModification.Type = 1           #for the enum value "SPWebConfigModification.SPWebConfigModificationType.EnsureChildNode"
$newModification.Value = "true"

#add our web config modification to the stack of mods that are applied
$webapp.WebConfigModifications.Add($newModification)
$webapp.Update()

#trigger the process of rebuildig the web config files on content web applications
$farmServices.ApplyWebConfigModifications()

Microsoft People-centric IT Roadshow

Microsoft UK have been running technical events around the UK for a couple of years now, and it’s a great thing. Too many events are focused in the south of England and there are lots of IT pros north of the M25!

Starting on Monday, the latest series of events kicks off. The People-Centric IT roadshow content is being delivered by MVPs from across the UK and Ireland. Covering hot-topics like Bring Your Own Device (BYOD) and information security, the sessions will talk about using the appropriate tooling from across the Microsoft stack to address these real-world problems.

You should think about attending if you want to learn more about:

  • Using System Center and Intune for managing desktops, operating systems and devices.
  • Managing desktop and application delivery with VDI
  • Using technologies like DirectAccess, Work Folders and Dynamic Access Control to give easy and secure access to data.
  • Using Active Directory Federation Services as part of your identity portfolio.

As always, the more people support these roadshows, particularly outside London, the more Microsoft will deliver similar events.

More information about each of the days can be found on the event pages, here:

11th June 2014 – Edinburgh

12th June 2014 – Sunderland

13th June 2014 – Birmingham

16th June 2014 – Bristol

17th June 2014 – Reading

The Sunderland event is being supported by our good friends at NEBytes, too!

Adding USB 3 to my Lenovo X220 Tablet

My X220 is a stalwart machine. It’s built like a tank and can be upgraded in a numb of ways. Mine now has 16Gb of RAM and two SSDs which allow me to run multi-VM environments for development and demo. Unfortunately, however, there is no USB 3 on the laptop. That’s a pain if I need to copy stuff on and off via USB, or run VMs from a USB 3 pod.

I’ve tried adding USB 3 before – I bough a Startech ExpressCard 54 with two ports. That singularly failed to work – the card is detected but the system either fails to recognise connected devices, or sees them yet can’t access them.

Whilst at Build I was involved in a conversation with the Kinect product team. They said that when using the Kinect with Windows they had issues with USB 3, and it boiled down to chipset issues, where the manufacturer hadn’t implemented something quite in accordance with spec. This spurred me to look for another ExpressCard, carefully looking for a different chipset.

Enter, stage left, Targus. not a name I’d associate with this kind of periperal, but careful reading of their specs showed their card to be a totally different chipset from the Startech device.

I ordered mine from Amazon. It arrived the next day, plugged in and simply worked. It’s an ExpressCard 34, so only one port. However, it puts out enough power to run my Western Digital USB 3 pod without needing to use the included cable to draw additional power from another USB port. I get the same transfer speed from the disk as my colleagues USB 3-equipped W540 laptops, so I really can’t argue.

The one thing I did add was a 34-54 adapter (from Startech, ironically) to plug the hole left in my ExpressCard 54 slot.

With the current move to ultrabooks I can see no real replacement device for my X220 – a sealed unit with no more than 8Gb and a single drive doesn’t come close to my needs, and a 15” luggable workstation is just too heavy. Hopefully I can keep tweaking the X220 for a while yet.

Our TFS Lab Management Infrastructure

Richard and I spend a good deal of time talking about Lab Manager and our environments. I’ve written here before about our migration to the latest versions of the various components of Lab and both Richard and I have delivered sessions at user groups and conferences.

Richard was in Belgium last week for Techorama, after which he was asked about the specifics of our setup. Between us, we came up with a diagram of our Lab Environment and Richard recently posted that to his blog. Hopefully some of you will find it useful.

Enabling Data Deduplication on my Windows 8.1 Laptop

Lets get the disclaimer out of the way first: What I’ve done is absolutely unsupported by Microsoft. Just because it works for me does not guarantee it will work for you and I am not in any way recommending that you follow my lead!

I use a great many virtual machines for both customer work, internal projects and just tinkering. My ThinkPad X220T is tricked out with extra RAM and two SSDs. Space is still an issue, though, and I can’t squeeze any more storage into my little workhorse.

Windows Server 2012 introduced Data Deduplication – a fantastic feature that is saving us huge amounts of disk space on our SCVMM library. I’d love to be able to use that on Windows 8.1 Sadly, Microsoft didn’t see fit to enable the feature.

There are a good many people out there who thought like I do and some of them decided to to figure out how to get data deduplication working on Windows 8.1. I’m not going to repeat those instructions here – I will instead post a link to the best of the articles I read before taking the leap, that of Mike Bijl.

Having installed and enabled the Data Deduplication feature I enabled dedupe on my D drive – a 500Gb Crucial M500 SSD. Note that you cannot dedupe your OS partition – you need OS and data volumes to get anywhere with this process. I started with about 12Gb of free space, gobbled up by ISO files and VHDs of installed VMs. Those dedupe beautifully, and I now have 245Gb of free space.

Have I encountered any problems yet? No. All my VMs run fine. I have a scheduled dedupe job running at noon to keep things tidy that has given no problems so far.

It is important to reiterate Mike’s point, however: If you enable dedupe on a volume and reinstall Windows 8.1 you will not be able to access any data on the drive until you re-enable dedupe (or stick the volume in a Windows Server 2012 or 2012 R2 machine). I’m happy with that – it’s no big deal for me. I would not, however, allow any of our developers to do this on their workstations, for example.

Doing all this, however, has got me thinking… Homegroup support is missing from Server 2012 and 2012 R2. I wonder if the same process might be used to enable features in the opposite direction…?

Getting ready for Global Windows Azure Bootcamp 2

It’s a busy week. I’m speaking at the Black Marble-hosted GWAB2 event this Saturday, along with Steve Spencer and Andy Westgarth. Richard and Robert will also be on hand which means between us we should be able to cover questions on much of the newly re-monikered Microsoft Azure.

I’ll be running through IaaS, Azure AD and looking at hybrid cloud solutions from an IT perspective while Steve and Andy talk through the other platform services from a developer point of view.