question

fab-1126 avatar image
0 Votes"
fab-1126 asked SeeyaXi-msft commented

UWF fail when hotplugging/removing additional disk drives

Hello community,
we have a problem with the UWF overlay in Win10 IoT Enterprise 2021H2. Maybe someone here in the community can provide some more information or help.

Our computer hardware consists of one disk drive where Win10 IoT is installed on.
Then there are two additional drives which can be hotplugged into SATA interfaces.

Depending on the image installation and the hardware configuration the UWF seems to not working but it also seems not to be aware of this fact.
For example this output on cmd should not be possible:


C:\>uwfmgr overlay get-availablespace
Unified Write Filter Configuration Utility version 10.0.19044
Copyright (C) Microsoft Corporation. All rights reserved.

The overlay has 0 MB available space.

C:\>uwfmgr overlay get-consumption
Unified Write Filter Configuration Utility version 10.0.19044
Copyright (C) Microsoft Corporation. All rights reserved.

The overlay consumption is 0 MB.



Both consumed and available space cannot be 0 MB. The filter is enabled and the volume is protected. Normally there are some numbers like for example 64 MB consumed / 1984 MB available.

Further investigations lead to the point that the protected disk drive changes its location depending if the two hotpluggable drives are inserted during boot or not.
With "wmic DiskDrive list" it is obvious that the Disk Drive name in the pattern "\.\PhysicalDriveX" changes.

Here is an output of the disk drives when the hotpluggable drives are not inserted during boot but hotplugged later on:
197441-image.png

acon is the UWF protected drive.

Here is the same output where the hotpluggable drives are already inserted when booting the computer:
197380-image.png



Now the acon Drive has the driver number 2. Previously it got the number 0.

Now the UWF overlay protection only works if the drive configuration when booting is the same as the config when the UWF overlay was created.
If the overlay was created without hotpluggable drives during boot then it is ok so long as those drives are not inserted when booting. Otherwise the output of consumed and available space is 0 MB.

Has anyone observed such behavior of the UWF. And has anyone a clue how the UWF protection can be made working with both drive configurations?

Thanks in advance
Falk B.

windows-10-setupwindows-iot-10corewindows-embedded
image.png (5.7 KiB)
image.png (5.5 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Sean-Liming avatar image
0 Votes"
Sean-Liming answered

I have not seen a case for hot plug drives, but I can guess that when the drives are plugged in and system booted, UWF gets messed up in the configuration since the physical drive numbering has changed.

What are the drive letters found on each drive? Does drive C get changed to a different drive letter?
What overlay type are is being used: RAM or Disk?



5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

fab-1126 avatar image
2 Votes"
fab-1126 answered SeeyaXi-msft commented

Hello Sean
thanks for your response. I have read some of your books and Pdfs :-)
yes, that UWF gets messed up because of changed physical driver numbering is my assumption too.
The drive C is the only drive which is protected by UWF. And it always got the letter C.
The overlay type is RAM.

But with a tip from one of my colleague we were able to solve this issue for us at last.
I think UWF provides an option for such cases when physical driver numbering changes, SetBindByDriveLetter.
This option is not available with uwfmgr.exe but with wmic only (so far as i know currently).
With this program, WMIExplorer, the option was tested. Setting the property to false has solved this issue. The physical drive numbering still changes as described before but the C: drive is protected in both boot configurations now (boot with and without drives).

It was somewhat difficult to set this option with scripting. As we have a workflow proposed by one of your documentations the creation of the "golden" image is heavily scripted for several reasons (you know which :-)).
Here is a snippet from our powershell script setting this option:


$COMPUTER = "localhost"
$NAMESPACE = "root\standardcimv2\embedded"

$uwfOverlayDriveC = Get-WmiObject -Namespace "root\standardcimv2\embedded" -Query "SELECT * FROM UWF_Volume WHERE CurrentSession=false AND DriveLetter='C:'"

$isTightBindingEnabled = $uwfOverlayDriveC.SetBindByDriveLetter($false)
$uwfOverlayDriveC | select-object -Property BindByDriveLetter



Using this script during the first OOBE sets the option to false. Then sysprep is made and in the next OOBE boot the filter is enabled. And UWF shows expected values for consumption and available space for booting with and without the other drives.

So this issue is solved i think. But thanks again for your answer, Sean.

Greetings from germany
Falk B.

· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

That option was added in LTSC 2019. I need to add it to my UWFGUI utility.

Please mark your post as the answer.

0 Votes 0 ·

Ok, this explains why the option was unknown by me. Last Win10 was LTSB2016 for me.
Sadly i cannot accept my own answer, seems there is an issue since january this year in Microsofts Q&A. The button "Accept answer" is not visible in my answer, only in your first answer.


0 Votes 0 ·

Here is a related document about Accepted answers: https://docs.microsoft.com/en-us/answers/support/accepted-answers
The question author cannot accept their own answer. I have voted for your answer.

1 Vote 1 ·