Deliberations

Thoughts on the problems and solutions I work with every day, along with musings on random topics

NAVIGATION - SEARCH

Win2012 - Storage Spaces: Rebuild == Gone?

No, don't fret - it just LOOKS like they're not there any more. By default Windows Server sets any storage space drives to manual attachment mode rather than auto-attach mode. To fix it we need PowerShell.

First, get the list of Virtual Disks:

PS C:\Windows\system32> Get-VirtualDisk

FriendlyName        ResiliencySettingNa OperationalStatus   HealthStatus        IsManualAttach                     Size
                    me
------------        ------------------- -----------------   ------------        --------------                     ----
ReFS RAID 10        Mirror              OK                  Healthy             True                               4 TB
RAID 5 ReFS         Parity              OK                  Healthy             True                               5 TB

Now, you know the names of the virtual disks to modify. Get the properties of the virtual disk and you'll see the source of the problem (the screenshot should make it more obvious where to look):

PS C:\Windows\system32> Get-VirtualDisk "ReFS RAID 10" | fl

ObjectId                          : {73c0ad00-f4d5-11e1-93ee-001b21b01e8b}
PassThroughClass                  :
PassThroughIds                    :
PassThroughNamespace              :
PassThroughServer                 :
UniqueId                          : 00ADC073D5F4E11193EE001B21B01E8B
Access                            : Read/Write
AllocatedSize                     : 71672266752
DetachedReason                    : None
FootprintOnPool                   : 143344533504
FriendlyName                      : ReFS RAID 10
HealthStatus                      : Healthy
Interleave                        : 262144
IsDeduplicationEnabled            : False
IsEnclosureAware                  : False
IsManualAttach                    : True
IsSnapshot                        : False
LogicalSectorSize                 : 512
Name                              :
NameFormat                        :
NumberOfAvailableCopies           : 0
NumberOfColumns                   : 3
NumberOfDataCopies                : 2
OperationalStatus                 : OK
OtherOperationalStatusDescription :
OtherUsageDescription             :
ParityLayout                      :
PhysicalDiskRedundancy            : 1
PhysicalSectorSize                : 4096
ProvisioningType                  : Thin
RequestNoSinglePointOfFailure     : True
ResiliencySettingName             : Mirror
Size                              : 4398583382016
UniqueIdFormat                    : Vendor Specific
UniqueIdFormatDescription         :
Usage                             : Other
PSComputerName                    :

 

Since you already know a little PowerShell you have probably worked out that you next need to use the Set-VirtualDisk cmdlet:

PS C:\Windows\system32> Set-VirtualDisk "ReFS RAID 10" -IsManualAttach $False

Check your results with the Get-VirtualDisk command:

PS C:\Windows\system32> Get-VirtualDisk "ReFS RAID 10" | fl

ObjectId                          : {73c0ad00-f4d5-11e1-93ee-001b21b01e8b}
PassThroughClass                  :
PassThroughIds                    :
PassThroughNamespace              :
PassThroughServer                 :
UniqueId                          : 00ADC073D5F4E11193EE001B21B01E8B
Access                            : Read/Write
AllocatedSize                     : 71672266752
DetachedReason                    : None
FootprintOnPool                   : 143344533504
FriendlyName                      : ReFS RAID 10
HealthStatus                      : Healthy
Interleave                        : 262144
IsDeduplicationEnabled            : False
IsEnclosureAware                  : False
IsManualAttach                    : False
IsSnapshot                        : False
LogicalSectorSize                 : 512
Name                              :
NameFormat                        :
NumberOfAvailableCopies           : 0
NumberOfColumns                   : 3
NumberOfDataCopies                : 2
OperationalStatus                 : OK
OtherOperationalStatusDescription :
OtherUsageDescription             :
ParityLayout                      :
PhysicalDiskRedundancy            : 1
PhysicalSectorSize                : 4096
ProvisioningType                  : Thin
RequestNoSinglePointOfFailure     : True
ResiliencySettingName             : Mirror
Size                              : 4398583382016
UniqueIdFormat                    : Vendor Specific
UniqueIdFormatDescription         :
Usage                             : Other
PSComputerName                    :

All done!

Why are AV Receivers so Dumb?

Pre-emptive Note: If you're a manufacturer, and you want to use this idea (or it inspires you to do something better) - you have full and free reign to use this idea. Go forth and improve things!

Yes, dumb, and in this case Dumb with the capital D and everything.

I just purchased myself a new AV receiver with the help of Eastwood Hi-Fi. Fantastic place - knowledgeable people and good pricing (no Australian Consumer Markup of 100% for example). The guys were great to deal with and I have no qualms recommending them. End of unpaid advertisement.

Now I'm not going to specify which brand of receiver; but I did buy one with lots of HDMI inputs well as several legacy inputs - mostly because I have a lot of HDMI-connected devices and some older devices too. The receiver has all the ports nicely labelled at the back; AV1 through AV7 for the HDMI, AV1 through AV4 for composite/S-Video, multiple optical and coax digital inputs. All very snazzy. But what you don't see mentioned in the manual is that half of the ports can't be used at the same time.

Case in point: AV1 refers to both the HDMI port and the legacy port. And you can't separate them - because the receiver only defines a maximum of 8 AV inputs (AV1-8). All of which are HDMI-capable. So no matter what you do, if you use legacy ports, you lose HDMI ports. Madness.

Add to that the user interface is pretty darn atrocious - the web UI is only for the most basic of changes (volume, choose input device) etc. Good if you had a tablet dedicated to a room, pretty useless for anything else.

So here's the thought. An AV receiver is, in effect, just a content switch. Sure, you have the ability to apply some changes to the data as it flows through the switch, but it's just a switch. And it can display pretty pictures over the HDMI port or using the Web (as an aside, putting it in the web UI makes sense because frankly, who has $1500 to spend on a receiver but has no computers in the house at all?) Right. So we have the concept of a web UI for configuring the receiver.

As the purchaser, you do three things:

  1. Define all your Sources. A Source is a named set of input ports (for example, "HDMI In 1", "S-Video In 2 and Coax In 3", "Component In 2 and Optical In 2"). If a port is assigned to a Source, it cannot be used for a second Source (due to the fact that these are input cables from a single device).
  2. Define all your Destinations. A Destination is a named set of outputs (for example, "HDMI Out 1 and Speaker Zone 1", "Component Out 3 and Speaker Zone 2"). Output ports can be assigned to multiple Destinations.  For example you might have two Destinations in the Bedroom with different sound outputs - "TV in BedRoom" vs "Surround TV in Bedroom".
  3. Define all your Activities. An Activity is a mapping of a Source to a Destination, optionally with some Enhancements (e.g. "Bass Boost", "Dialogue Boost", "Max Volume = -25dB" and so forth). When an Activity is started, if one of its outputs is already in use by another Activity, that second Activity is stopped. If there is no conflict, BOTH Activities run in parallel (this is your multi-zone output capability).

The user configures the remote to have your Activities (as an aside - ship a darn touchscreen with a configurable display - even with my big hands the new remote feels like I'm holding a fishing rod). This means your remote can actually SHOW the activity names to the user, a much more friendly experience than "Wait, was the PS3 on quick button A or 3?".

In case you can't visualize this, here's a quick example of how you might define a Source (took me about 10 minutes to knock up). Yes, the form works - try selecting video and audio sources, and hovering over the greyed-out sources:

New Source
Source Name
Video From HDMI In 1
HDMI In 2
HDMI In 3
HDMI In 4
HDMI In 5
HDMI In 6
Component In 1
Component In 2
Component In 3
   
Composite In 1
Composite In 2
Composite In 3
Audio From HDMI In 1
HDMI In 2
HDMI In 3
HDMI In 4
HDMI In 5
HDMI In 6
Optical In 1
Optical In 2
Coaxial In 1
Coaxial In 2
Stereo In 1
Stereo In 2
Stereo In 3
 

Now I realise this is a massive departure from the existing configuration, and you, as the manufacturer, will want to ship the device with many profiles pre-built. That's OK - here are your prebuilt profiles:

  • HDMI 1 to HDMI 1 (Inputs: HDMI In 1 for video, HDMI In 1 for audio; Outputs: HDMI Out 1 for video, Speakers for audio)
  • HDMI 2 to HDMI 1 (Inputs: HDMI In 2 for video, HDMI In 2 for audio; Outputs: HDMI Out 1 for video, Speakers for audio)
  • Component and Optical to HDMI 1 (Inputs: Component In 1 for video, Optical In 1 for audio; Outputs: HDMI Out 1 for video, Speakers for audio)
  • Component and Optical to Component (Inputs: Component In 1 for video, Optical In 1 for audio; Outputs: Component Out 1 for video, Speakers for audio)
  • Composite and Optical to HDMI 1 (Inputs: Composite In 1 for video, Optical In 1 for audio; Outputs: HDMI Out 1 for video, Speakers for audio)
  • Composite and Optical to Composite (Inputs: Composite In 1 for video, Optical In 1 for audio; Outputs: Composite Out 1 for video, Speakers for audio)

Six profiles. Let the user build the profiles they want for other ports. For safety, you probably want to allow the default profiles to remain and maybe even not be counted in the user profiles (so these predefined profiles are not evaluated for the rules about re-use of source ports above).

I also realise there are a number of ways to skin this cat - you might consider making this a wizard instead of a single HTML form, or you might auto-select HDMI 3 as the audio input when the user selects it as the video input. You may need to tie some inputs together - but why? You've built a highly-advanced content switch. Switch the inputs as desired by the user.

Complete freedom for the user. One standard UI for you as the manufacturer (so you can get cost savings and efficiencies). And a massive, massive competitive advantage because you can demonstrate that setting up the new receiver with a stack of sources, destinations and activities takes less than 2 minutes.

(Oh, all those images in the table above were created by me; as far as I'm concerned there is no creative element to them and you may do with them as you wish).

Windows 2012 - Unidentified Network at Boot

This is a quick and easy fix. If, like many admins, you configure your server with a redundant network connection (colloquially a "team"); and if you have configured even servers to have a firewall (even if only for the Public zone); and if you choose to use Windows 2012 inbuilt teaming (which is a great idea - no more quirky drivers, stupid apps, poor UI); and if you create the host team as LACP, you'll probably run into this one.

You do a nice controlled reboot, and ... your server never comes back. Well it does; you can use the iLO or DRAC or whatever IBM call their cards nowadays, and the console's just fine, but the network is showing as Unidentified network.

Which is pretty annoying considering the network is working just fine and you can ping the domain controller. By name. So what's wrong with the silly thing this time?

Service timing. Specifically, the network location and hence firewall zone is being detected prior to the team coming online. You can confirm that for yourself simply by restarting the Network Location Awareness service, which will also restart the Network List Service service:

And that should give you a hint about how to resolve it - change the startup type for the Network Location Awareness service to "Automatic (Delayed Start)":

Or for the command line junkies (or as part of your scripted build process):

sc config NlaSvc start= delayed-auto

This workaround shouldn't be needed forever, as it seems likely that this bug will be squashed in the first Service Pack (Edit: 13 December 2016: Here we are four years later, still there).

SCVMM - Add Update Server error 24057

I figured I should try to get the upgrade from SCVMM 2012 SP1 Beta to SP1 release completed over the holidays. Part of the update required a rebuild of the database (and thus reassociating all agents, recreating fabrics etc). When it came time to integrate the WSUS server, I got this:

PS C:\Windows\system32> Add-SCUpdateServer wsus.lab.lan -Credential $Cred
Add-SCUpdateServer : VMM no longer has full administrative permissions on update server wsus.lab.lan. (Error ID: 24057)

Please reassociate the VMM Agent on the update server and retry the operation.

To restart the job, run the following command:
PS> Restart-Job -Job (Get-VMMServer localhost | Get-Job | where { $_.ID -eq "{7d2ed5e3-3de5-43c5-820f-2e32241bf4e6}"})
At line:1 char:1
+ Add-SCUpdateServer wsus.lab.lan -Credential $Cred
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ReadError: (:) [Add-SCUpdateServer], CarmineException
    + FullyQualifiedErrorId : 24057,Microsoft.SystemCenter.VirtualMachineManager.Cmdlets.RemoveUpdateServerCmdlet

Manually installing the agent did not help. Reassociating did nothing, updating the server failed, so did attempting to remove it! Nor did retrying or rebooting (neither the VMM host nor WSUS) help. The error is right there at the top, where you'll miss it if you blink.

What did help was adding the SCVMM service account to the Administrators group on the WSUS server. So try that first!