{"id":2495,"date":"2017-04-09T22:34:22","date_gmt":"2017-04-09T20:34:22","guid":{"rendered":"http:\/\/blog.hosebei.ch\/?p=2495"},"modified":"2017-04-09T22:34:22","modified_gmt":"2017-04-09T20:34:22","slug":"configmgr-windows-10-servicing-step-by-step","status":"publish","type":"post","link":"https:\/\/blog.hosebei.ch\/?p=2495","title":{"rendered":"ConfigMgr &#8211; Windows 10 Servicing &#8211; Step by Step"},"content":{"rendered":"<p>Today I would like to show you, how you can implement an Upgrade of a Windows 10 Installation through the Servicing Option.<br \/>\nI always think of two things, when I have to decide to use an Upgrade Task Sequence or the Servicing Model, and those are:<\/p>\n<li>Do I want to use the Option that the clients will download the Windows 10 Sources from the Microsoft Update Servers?<\/li>\n<li>When I use an Upgrade Task Sequence, I can copy most of the steps from the regular OSD Task Sequence<\/li>\n<p>But for this blog post, I would like to show my setup for the servicing model.<\/p>\n<p>First of all, I have already written a post about the Update process in a slightly overview manner, you will find this post here: <a href=\"https:\/\/blog.hosebei.ch\/2017\/01\/18\/configmgr-windows-10-feature-update-without-a-task-sequence\/\">My old post<\/a><\/p>\n<p>The first step would be to determine which packages you would like to implement for the upgrade. Based on the fact, that I use English as base language, I will add the Feature on Demand (FoD) packages, and I will also add the feature package NetFx3. My Setup does also contain the German Langauge, which requires me to add the corresponding Language Pack and FoD Packages. The following picture shows the folder of my Packages which I want to include within the Windows 10 Installation:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade01.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade01.png?w=300\" alt=\"\" width=\"300\" height=\"88\" class=\"aligncenter size-medium wp-image-2497\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade01.png 871w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade01-300x88.png 300w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade01-768x225.png 768w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\n<!--more--><\/p>\n<p>When this is done, you will have to decide, where you would like to store the packages and also some script files on the System Disk of the current Client. I have decided to create a folder named C:\\LP, which is hidden, and two subfolders called LP and Scripts, I would also recommend to modify the default User Permissions, if you don&#8217;t want that standard users can change the scripts.<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade02.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade02.png\" alt=\"\" width=\"298\" height=\"140\" class=\"aligncenter size-full wp-image-2499\" \/><\/a><br \/>\nTo achieve the copy jobs which are required, I will come back to those scripts later, I have decided to use Configuration Items, rather than an Application or an Old-School Package within the Software Library. But this will require that my clients are able to access those files, because they will not download it from a Distribution Point. I am using Distributed File Services (DFS) to have a single UNC Path, where the clients can download the packages (with BITS of course).<br \/>\nI have decided where my package location resides and have copied all the required packages and scripts to this location:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade03.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade03.png?w=300\" alt=\"\" width=\"300\" height=\"194\" class=\"aligncenter size-medium wp-image-2500\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade03.png 607w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade03-300x194.png 300w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>Then I went on and created a Configuration item named &#8220;Windows 10 Servicing CI&#8221;:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade04.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade04.png?w=300\" alt=\"\" width=\"300\" height=\"274\" class=\"aligncenter size-medium wp-image-2501\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade04.png 785w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade04-300x274.png 300w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade04-768x702.png 768w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nI only selected Windows 10 (x64):<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade05.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade05.png?w=300\" alt=\"\" width=\"300\" height=\"274\" class=\"aligncenter size-medium wp-image-2502\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade05.png 782w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade05-300x274.png 300w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade05-768x702.png 768w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nWithin the next step of the Wizard, click on &#8220;New&#8230;&#8221; to add a setting, and the following Windows appears:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade06.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade06.png?w=300\" alt=\"\" width=\"300\" height=\"284\" class=\"aligncenter size-medium wp-image-2503\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade06.png 667w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade06-300x284.png 300w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nMake sure to have selected the &#8220;Setting Type&#8221; Script, and as &#8220;Data Type&#8221; &#8220;String&#8221;, as shown in the picture above. Afterwards click on &#8220;Add Script&#8230;&#8221; within the Discovery Script Section, and the following script block windows will appear:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade07.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade07.png?w=298\" alt=\"\" width=\"298\" height=\"300\" class=\"aligncenter size-medium wp-image-2505\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade07.png 609w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade07-298x300.png 298w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade07-150x150.png 150w\" sizes=\"auto, (max-width: 298px) 100vw, 298px\" \/><\/a><br \/>\nMake sure that &#8220;Windows Powershell&#8221; is selected as script language. The script will simply check both file locations, and if the size is not the same, the CI will be reported as non-compliant. You may want to extend the detection script to your needs, as example if you have multiple languages and want to copy only some languages to the client. I have used the following script for this purpose (you will find a zip Download at the end of the blog as well):<br \/>\n<code>#Variables<br \/>\n$LocalFolderLP = \"C:\\LP\\LP\"<br \/>\n$PathToLanguagePacks = \"\\\\deheim.hosebei.ch\\hosebeiDFSroot\\Deployment\\OS\\Windows 10\\LanguagePacks\\1703\"<\/p>\n<p>$Compliance = \"Non-Compliant\"<\/p>\n<p>#Receive transferred jobs, but not yet finished<br \/>\n$bitstransfers = Get-BitsTransfer -AllUsers<br \/>\nforeach($bitsjob in $bitstransfers) {<br \/>\n    if($bitsjob.Jobstate -eq \"Transferred\") {<br \/>\n        #End old Transfers due script execution errors<br \/>\n        Complete-BitsTransfer -BitsJob $bitsjob<br \/>\n    }<br \/>\n}<\/p>\n<p>#Start Main Script<br \/>\nIf((Test-Path $LocalFolderLP) -eq $false) {<br \/>\n    $Compliance = \"Non-Compliant\"<br \/>\n}<br \/>\nelse {<br \/>\n    #Measure both Locations<br \/>\n    $SizeOfLPsSource = Get-ChildItem -Path $PathToLanguagePacks -Filter *.cab | Measure-Object -property length -sum<br \/>\n    $SizeOfLPsDestination = Get-ChildItem -Path $LocalFolderLP -Filter *.cab | Measure-Object -property length -sum<br \/>\n    If($SizeOfLPsSource.sum -ne $SizeOfLPsDestination.Sum) {<br \/>\n        $Compliance = \"Non-Compliant\"<br \/>\n    }<br \/>\n    else {<br \/>\n        $Compliance = \"Compliant\"<br \/>\n    }<br \/>\n}<br \/>\n#Return the result<br \/>\n$Compliance<\/code><\/p>\n<p>Close this Windows by a click on &#8220;OK&#8221;. Then go ahead and click on &#8220;Add Script&#8230;&#8221; witin he Remedation Script section, and add the following script to the script block:<\/p>\n<p><code>#Copy the Language Pack Files<br \/>\nFunction Start-LPBitsJob([System.IO.FileInfo]$CABFileToCopy, [string]$LocalLPFolder) {<br \/>\n    $BitsJob = $null<br \/>\n    $BitsJob = Start-BitsTransfer -Source $CABFileToCopy.FullName -Destination $LocalLPFolder -TransferType Download -Asynchronous -DisplayName &quot;CAB Downloads&quot;<br \/>\n}<\/p>\n<p>#Variables<br \/>\n$LocalFolderLP = &quot;C:\\LP\\LP&quot;<br \/>\n$PathToLanguagePacks = &quot;\\\\deheim.hosebei.ch\\hosebeiDFSroot\\Deployment\\OS\\Windows 10\\LanguagePacks\\1703&quot;<\/p>\n<p>#Start Main Script<br \/>\nif((Test-Path $LocalFolderLP) -eq $false) {<br \/>\n    New-Item $LocalFolderLP -ItemType Directory<br \/>\n}<br \/>\n$MakeHidden = Get-Item &quot;C:\\LP&quot; -Force<br \/>\n$MakeHidden.Attributes=&quot;Hidden&quot;<br \/>\nif((Test-Path $LocalFolderScripts) -eq $false) {<br \/>\n    New-Item $LocalFolderScripts -ItemType Directory<br \/>\n}<\/p>\n<p>$CABFilesToCopy = Get-ChildItem -Path $PathToLanguagePacks\\* -Include *.cab<br \/>\nforeach($cabFile in $CABFilesToCopy) {<\/p>\n<p>    if($cabFile.length -ne (Get-Item ($LocalFolderLP + &quot;\\&quot; + $cabFile.Name)).Length) {<br \/>\n        #Write-Host &quot;not same&quot;<br \/>\n        Start-LPBitsJob $cabFile $LocalFolderLP<br \/>\n    }<br \/>\n    else {#Write-Host &quot;same&quot;<br \/>\n    }<br \/>\n}<\/p>\n<p>$AllBitsDownloads = Get-BitsTransfer -Name &quot;CAB Downloads&quot;<br \/>\n$DLFinishedLoop = $false<br \/>\nwhile ($DLFinishedLoop -eq $false) {<br \/>\n    $DLFinished =$true<br \/>\n    foreach($BITSDownload in $AllBitsDownloads) {<br \/>\n        if($BITSDownload.JobState -ne &quot;Transferred&quot;) {<br \/>\n            $DLFinished = $false<br \/>\n        }<br \/>\n    }<br \/>\n    if($DLFinished -ne $false) {<br \/>\n        $DLFinishedLoop = $true<br \/>\n    }<\/p>\n<p>    sleep 1<br \/>\n    #write-host &quot;loop&quot;<br \/>\n}<\/p>\n<p>#Now finish all Transfers<br \/>\n$AllBitsDownloads | Complete-BitsTransfer<\/code><\/p>\n<p>As you can see, I&#8217;m using a BITS Transfer to download the packages and all packages are checked (based on the size), and a specific package is only downloaded if required. For more information about starting a BITS download through Powershell consult this Microsoft document: <a href=\"https:\/\/msdn.microsoft.com\/en-us\/library\/windows\/desktop\/ee663885(v=vs.85).aspx\" target=\"_blank\">Using Windows PowerShell to Create BITS Transfer Jobs<\/a><br \/>\nYour remediation script block should look like this:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade08.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade08.png?w=298\" alt=\"\" width=\"298\" height=\"300\" class=\"aligncenter size-medium wp-image-2507\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade08.png 607w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade08-298x300.png 298w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade08-150x150.png 150w\" sizes=\"auto, (max-width: 298px) 100vw, 298px\" \/><\/a><br \/>\nWhen this is done, we can switch to the &#8220;Compliance Rule&#8221; Tab and click on &#8220;New&#8230;&#8221;:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade09.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade09.png?w=300\" alt=\"\" width=\"300\" height=\"282\" class=\"aligncenter size-medium wp-image-2508\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade09.png 669w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade09-300x282.png 300w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nFill the opened window with the required information, make sure to check the Box at <strong>&#8220;Run the specified remediation script when the setting is noncompliant&#8221;<\/strong>:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade10.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade10.png?w=291\" alt=\"\" width=\"291\" height=\"300\" class=\"aligncenter size-medium wp-image-2510\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade10.png 620w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade10-291x300.png 291w\" sizes=\"auto, (max-width: 291px) 100vw, 291px\" \/><\/a><br \/>\nBy clicking on OK twice, the first setting within the configuration item is finished. Now it is time to add the setting to copy the setupconfig.ini file, which is required to instruct the Windows Upgrade to use the downloaded packages and to execute a script after the installation. For more information about the setupconfig.ini refer to this Microsoft Document: <a href=\"https:\/\/msdn.microsoft.com\/en-us\/windows\/hardware\/commercialize\/manufacture\/desktop\/windows-setup-automation-overview\" target=\"_blank\">Use Setupconfig.ini to install Windows<\/a><br \/>\nMy SetupConfig.ini is quite simple, I&#8217;m still using the same as outlined in the <a href=\"https:\/\/blog.hosebei.ch\/2017\/01\/18\/configmgr-windows-10-feature-update-without-a-task-sequence\/\">old post<\/a>.<br \/>\nNow a click on &#8220;New&#8230;&#8221; will open again a new setting:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade11.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade11.png?w=300\" alt=\"\" width=\"300\" height=\"274\" class=\"aligncenter size-medium wp-image-2513\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade11.png 784w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade11-300x274.png 300w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade11-768x701.png 768w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nIn the opened window, fill out the settings as shown below:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade12.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade12.png?w=300\" alt=\"\" width=\"300\" height=\"283\" class=\"aligncenter size-medium wp-image-2514\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade12.png 666w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade12-300x283.png 300w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nAdd the following script to the Discovery section:<\/p>\n<p><code>#Path to setupconfig File<br \/>\n$SourceFileLocation = \"\\\\deheim.hosebei.ch\\hosebeiDFSroot\\Deployment\\OS\\Windows 10\\LanguagePacks\\1703\\SetupConfig.ini\"<\/p>\n<p>$Compliance = \"Not-Compliant\"<br \/>\nif((Test-Path -Path \"$env:SystemDrive\\Users\\Default\\AppData\\Local\\Microsoft\\Windows\\WSUS\\setupconfig.ini\") -eq $false) {<br \/>\n    $Compliance = \"Not-Compliant\"<br \/>\n}<br \/>\nelseif((Get-Item \"\\\\deheim.hosebei.ch\\hosebeiDFSroot\\Deployment\\OS\\Windows 10\\LanguagePacks\\1703\\SetupConfig.ini\").Length -ne (Get-Item \"$env:SystemDrive\\Users\\Default\\AppData\\Local\\Microsoft\\Windows\\WSUS\\setupconfig.ini\").Length) {<br \/>\n    $Compliance = \"Not-Compliant\"<br \/>\n}<br \/>\nelse {<br \/>\n    $Compliance = \"Compliant\"<br \/>\n}<br \/>\n$Compliance<\/code><\/p>\n<p>My remediation script, which will copy the setupconfig.ini to the correct place does not change the folder permissions of the WSUS folder. I would recommend for your environment to change the folder, or at least the file permission, that a regular user can&#8217;t modify the setupconfig.ini File. This is my remediation script for the ini file:<\/p>\n<p><code>if((Test-Path \"C:\\Users\\Default\\AppData\\Local\\Microsoft\\Windows\\WSUS\") -eq $false) {<br \/>\n    New-Item -Path \"C:\\Users\\Default\\AppData\\Local\\Microsoft\\Windows\\WSUS\" -ItemType Directory<br \/>\n}<br \/>\nCopy-Item -Path \"\\\\deheim.hosebei.ch\\hosebeiDFSroot\\Deployment\\OS\\Windows 10\\LanguagePacks\\1703\\SetupConfig.ini\" -Destination \"$env:SystemDrive\\Users\\Default\\AppData\\Local\\Microsoft\\Windows\\WSUS\\SetupConfig.ini\" -Force<\/code><\/p>\n<p>When you have added both scripts, switch to the Compliance Rules Tab, and add a new rule by a click on &#8220;New&#8230;&#8221;, fill out the opened rule window as in the following picture:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade13.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade13.png?w=292\" alt=\"\" width=\"292\" height=\"300\" class=\"aligncenter size-medium wp-image-2515\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade13.png 622w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade13-292x300.png 292w\" sizes=\"auto, (max-width: 292px) 100vw, 292px\" \/><\/a><br \/>\nMake sure again to have ticked the box to run the remediation script.<br \/>\nAnd the last CI setting will copy the scripts that are required to be executed after the Windows Upgrade is done, but before a user can logon. The process is the same like for the two settings we already have created. Here is the Discovery Script which I&#8217;m using:<\/p>\n<p><code>$LocalFolderScripts = \"C:\\LP\\Scripts\"<br \/>\n$SourceFileLocation = \"\\\\deheim.hosebei.ch\\hosebeiDFSroot\\Deployment\\OS\\Windows 10\\LanguagePacks\\1703\"<\/p>\n<p>$Compliance = \"Not-Compliant\"<\/p>\n<p>$AllLocalScripts = Get-ChildItem -Path $LocalFolderScripts\\* -Include *.bat,*.vbs,*.ps1<br \/>\n$AllSourceScript = Get-ChildItem -Path $SourceFileLocation\\* -Include *.bat,*.vbs,*.ps1<br \/>\nif($AllLocalScripts.Count -ne $AllSourceScript.Count) {<br \/>\n    $Compliance = \"Not-Compliant\"<br \/>\n}<br \/>\n$SizeOfScriptsSource = Get-ChildItem -Path $SourceFileLocation\\* -Include *.bat,*.vbs,*.ps1 | Measure-Object -property length -sum<br \/>\n$SizeOfScriptsDestination = Get-ChildItem -Path $LocalFolderScripts\\* -Include *.bat,*.vbs,*.ps1 | Measure-Object -property length -sum<br \/>\nif($SizeOfScriptsSource.sum -ne $SizeOfScriptsDestination.sum) {<br \/>\n    $Compliance = \"Not-Compliant\"<\/p>\n<p>}<br \/>\nelse {<br \/>\n    $Compliance = \"Compliant\"<br \/>\n}<br \/>\n$Compliance<\/code><\/p>\n<p>And this is the remediation script:<\/p>\n<p><code>Function Start-BitsJob([System.IO.FileInfo]$FileToCopy, [string]$LocalFolder) {<br \/>\n    $BitsJob = $null<br \/>\n    $BitsJob = Start-BitsTransfer -Source $FileToCopy.FullName -Destination $LocalFolder -TransferType Download -Asynchronous<\/p>\n<p>    while (($BitsJob.JobState -eq \"Transferring\") -or ($BitsJob.JobState -eq \"Connecting\")) { sleep 5;} # Poll for status, sleep for 5 seconds, or perform an action.<\/p>\n<p>    Switch($BitsJob.JobState)<br \/>\n    {<br \/>\n        \"Transferred\" {Complete-BitsTransfer -BitsJob $BitsJob}<br \/>\n        \"Error\" {$BitsJob | Format-List } # List the errors.<br \/>\n        default {\"Other action\"} #  Perform corrective action.<br \/>\n    }<br \/>\n}<\/p>\n<p>$LocalFolderScripts = \"C:\\LP\\Scripts\"<br \/>\n$PathToLanguagePacks = \"\\\\deheim.hosebei.ch\\hosebeiDFSroot\\Deployment\\OS\\Windows 10\\LanguagePacks\\1703\"<\/p>\n<p>if((Test-Path \"C:\\LP\\Scripts\") -eq $false) {<br \/>\n    New-Item -Path \"C:\\LP\\Scripts\" -ItemType Directory<br \/>\n}<\/p>\n<p>$ScriptFilesToCopy = Get-ChildItem -Path $PathToLanguagePacks\\* -Include *.ps1,*.vbs,*.bat<br \/>\nforeach($ScriptFile in $ScriptFilesToCopy) {<br \/>\n    if($ScriptFile.length -ne (Get-Item ($LocalFolderScripts + \"\\\" + $ScriptFile.Name)).Length) {<br \/>\n        #Write-Host \"not same\"<br \/>\n        Start-BitsJob $ScriptFile $LocalFolderScripts<br \/>\n    }<br \/>\n    else {#Write-Host \"same\"}<br \/>\n}<br \/>\n<\/code><\/p>\n<p>When you have finished adding the third setting, your Configuration Item should look like this:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade14.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade14.png?w=300\" alt=\"\" width=\"300\" height=\"274\" class=\"aligncenter size-medium wp-image-2517\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade14.png 783w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade14-300x274.png 300w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade14-768x702.png 768w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nIf you click on Next, the wizard will show you the created Compliances Rules according to the settings, make sure that &#8220;Remediate&#8221; is on Yes:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade15.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade15.png?w=300\" alt=\"\" width=\"300\" height=\"275\" class=\"aligncenter size-medium wp-image-2518\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade15.png 781w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade15-300x275.png 300w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade15-768x704.png 768w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nFinish the wizard by clicking on Next twice and close it afterwards. Now we need to create a Baseline and just add our Compliance Item to it:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade16.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade16.png?w=300\" alt=\"\" width=\"300\" height=\"272\" class=\"aligncenter size-medium wp-image-2519\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade16.png 639w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade16-300x272.png 300w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><br \/>\nAfter a click on OK, the baseline is created and ready to be deployed on a collection. Within the deployment wizard of the baseline, make sure to tick the check box at &#8220;Remediate noncompliant rules when supported&#8221;:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade17.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade17.png?w=298\" alt=\"\" width=\"298\" height=\"300\" class=\"aligncenter size-medium wp-image-2521\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade17.png 657w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade17-298x300.png 298w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade17-150x150.png 150w\" sizes=\"auto, (max-width: 298px) 100vw, 298px\" \/><\/a><br \/>\nNow everything is quite good and you can create a collection based on the baseline:<br \/>\n<a href=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade18.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade18.png?w=300\" alt=\"\" width=\"300\" height=\"253\" class=\"aligncenter size-medium wp-image-2522\" srcset=\"https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade18.png 685w, https:\/\/blog.hosebei.ch\/wp-content\/uploads\/2017\/04\/windows10upgrade18-300x253.png 300w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>And here is my batch file which I run after the Windows 10 Upgrade:<br \/>\n<code>mkdir C:\\LP\\1703_OK<br \/>\npowershell.exe -NoProfile -ExecutionPolicy Bypass -File \"C:\\LP\\Scripts\\Remove-Apps.ps1\"<\/code><\/p>\n<p>The PowerShell Script &#8220;Remove-Apps.ps1&#8221; removes Universal apps which I don&#8217;t want on the clients. This is the content of Remove-Apps.ps1:<\/p>\n<p><code>#Initalize Array<br \/>\n$AppstoRemove = New-Object System.Collections.ArrayList<\/p>\n<p>#Add Apps to Array<br \/>\n$AppstoRemove.Add(\"Microsoft.NetworkSpeedTest_1.0.0.23_x64__8wekyb3d8bbwe\") #NetworkSpeedTest<br \/>\n$AppstoRemove.Add(\"46928bounde.EclipseManager_2.2.1.31_neutral__a5h4egax66k6y\") #Eclipse Manager<br \/>\n$AppstoRemove.Add(\"6Wunderkinder.Wunderlist_3.6.25.0_x64__b4cwydgxqx59r\") #Wunderlist<br \/>\n$AppstoRemove.Add(\"Microsoft.MicrosoftOfficeHub_17.8017.5925.0_x64__8wekyb3d8bbwe\") #Get Office Sneak App<br \/>\n$AppstoRemove.Add(\"Microsoft.BingTranslator_4.7.0.0_x64__8wekyb3d8bbwe\") #Bing Translator<br \/>\n$AppstoRemove.Add(\"D5EA27B7.Duolingo-LearnLanguagesforFree_2017.112.1.0_x64__yx6k7tf7xvsea\") #Language Learning App<br \/>\n#$AppstoRemove.Add(\"Microsoft.SkypeApp_11.12.112.0_x64__kzf8qxf38zg5c\") #Skype for Business App<br \/>\n#$AppstoRemove.Add(\"Microsoft.Office.OneNote_17.7967.57741.0_x64__8wekyb3d8bbwe\") #OneNote App<\/p>\n<p>$AppstoRemove | Remove-AppxPackage<\/code><\/p>\n<p>You might want also to configure the Language settings as they were before. Then you can use the solution from Roger Zander, to apply Language Settings with an XML: <a href=\"http:\/\/rzander.azurewebsites.net\/how-to-change-the-welcome-screen-language-in-win10\/\" target=\"_blank\">Windows 10 MUI challenge<\/a><br \/>\nHere you will find a Zip-File with all my scripts used within this blog: <a href=\"https:\/\/1drv.ms\/u\/s!Aq0GcVCqC0RlofplTpMUUsES_oRQmA\" target=\"_blank\">Windows 10 Upgrade Scripts<\/a><\/p>\n<p>Now you can deploy the upcoming release to your clients, just like a regular update.<\/p>\n<p>If you think this post was useful, please leave a comment, and if you see issues or you can recommend better techniques, leave a comment as well, or get in touch with me on <a href=\"https:\/\/twitter.com\/hosebei\" target=\"_blank\">twitter<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today I would like to show you, how you can implement an Upgrade of a Windows 10 Installation through the Servicing Option. I always think of two things, when I have to decide to use an Upgrade Task Sequence or the Servicing Model, and those are: Do I want to use the Option that the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[15,27,33,41,43],"tags":[],"class_list":["post-2495","post","type-post","status-publish","format-standard","hentry","category-configmgr","category-operating-system-deployment","category-sccm","category-updates-management","category-windows-10"],"_links":{"self":[{"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=\/wp\/v2\/posts\/2495","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2495"}],"version-history":[{"count":0,"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=\/wp\/v2\/posts\/2495\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2495"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2495"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.hosebei.ch\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2495"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}