Reparar ADK 10 para Windows 10 1511
les comparto como podemos reparar nuestro ADK para Windows 10 v 1511, este bug lo ha publicado Microsoft en este link.
https://support.microsoft.com/en-us/kb/3143760
Keith’s Consulting Blog nos muestra el metodo para poder hacer la actualizacion, lo primero que haremos sera guardar el siguiente codigo en un bloc de notas y guardarlo en C: con el nombre de Repair-1511ADK.ps1
<# .SYNOPSIS Repair Windows 1511 ADK .DESCRIPTION Will install Microsoft KB3143760 fix against the Windows 10 1511 ADK (Build 10520) Required for .NOTES Copyright Keith Garner, All rights reserved. Permissive use license. .LINK https://support.microsoft.com/en-us/kb/3143760 .EXAMPLE .Repair-1511ADK.ps1 -verbose -ImagePath 'C:Program Files (x86)Windows Kits10Assessment and Deployment KitWindows Preinstallation Environmentx86en-uswinpe.wim' Patch a single file. .EXAMPLE get-childitem 'C:Program Files (x86)Windows Kits10Assessment and Deployment Kit*.wim' -recurse | % { .Repair-1511ADK.ps1 -verbose $_.FullName } Patch ALL WinPE files in the ADK #>
[CmdletBinding()]
param(
[parameter(Mandatory=$true,ValueFromPipeline=$true)]
[string] $ImagePath
)
######################################################
$ErrorActionPreference = 'Stop'
$uri = 'http://hotfixv4.microsoft.com/Configuration%20Manager/nosp/Win10ADK_Hotfix_KB3143760/6.0.10586.163/free/490343_ENU_x64_zip.exe'
$tempfiles = @(
"$env:temp490343_ENU_x64.zip",
"$env:tempWin10ADK-Hotfix-KB3143760.exe",
"$env:tempschema-x64.dat",
"$env:tempschema-x86.dat",
"$env:tempAclFile" )
remove-item -path $TempFiles -ErrorAction SilentlyContinue
######################################################
Write-verbose "Verify ImagePath"
######################################################
if ( -not ( test-path $ImagePath ) ) { throw [System.IO.FileNotFoundException] "$ImagePath not found." }
$ImageItem = Get-WindowsImage -imagepath $ImagePath -index 1
$ImageItem | out-string | write-verbose
if ( $ImageItem | Where-Object Version -ne '10.0.10586.0' ) { throw "$ImagePath wim not Build 1511" }
######################################################
write-verbose "Download Path File locally"
######################################################
Invoke-WebRequest -Uri $uri -OutFile "$env:temp490343_ENU_x64.zip"
write-verbose "extract Zip contents (Pass1)"
$Shell = new-object -com shell.application
$Shell.NameSpace("$env:temp490343_ENU_x64.zip").items() | foreach-object { $Shell.NameSpace( $env:temp ).CopyHere($_) }
if ( -not ( test-path "$env:tempWin10ADK-Hotfix-KB3143760.exe" ) ) { throw "Extract failure (Pass1)" }
write-verbose "extract Exe contents (Pass2)"
& $env:tempWin10ADK-Hotfix-KB3143760.exe /T:$env:temp /q | out-null
if ( -not ( test-path "$env:tempschema-x64.dat" ) ) { throw "Extract failure (Pass2)" }
######################################################
write-verbose "Mount WinPE"
######################################################
$PEMount = New-Item -ItemType Directory -Path "$env:temp$([System.Guid]::NewGuid())" |
Select-Object -ExpandProperty FullName
Mount-WindowsImage -ImagePath $ImagePath -index 1 -path $PEMount |Write-Verbose
######################################################
write-verbose "Save schema.dat state"
######################################################
& icacls $PEMountWindowsSystem32schema.dat /save "$env:tempAclFile" | write-verbose
######################################################
write-verbose "Update the Schema.dat file"
######################################################
& takeown /F $PEMountWindowsSystem32schema.dat /A | write-verbose
& icacls $PEMountWindowsSystem32schema.dat /grant "BUILTINAdministrators:(F)" | write-verbose
######################################################
write-verbose "Copy the DAT file"
######################################################
if ( $ImageItem | where-object Architecture -eq 9 )
{
copy-item -path "$env:tempschema-x64.dat" -Destination $PEMountWindowsSystem32schema.dat
}
elseif ( $ImageItem | where-object Architecture -eq 0 )
{
copy-item -path "$env:tempschema-x86.dat" -Destination $PEMountWindowsSystem32schema.dat
}
else
{
write-warning "Architecture type not found for $ImagePath"
}
######################################################
write-verbose "Reset permissions and ownership"
######################################################
icacls $PEMountWindowsSystem32schema.dat /setowner "NT SERVICETrustedInstaller" | write-verbose
icacls $PEMountWindowsSystem32 /restore "$env:tempAclFile" | write-verbose
######################################################
write-verbose "DisMount WinPE"
######################################################
Dismount-WindowsImage -Path $PEMount -Save | write-verbose
$PEMount = Remove-Item -Path $PEMount -ErrorAction SilentlyContinue
######################################################
write-verbose "Clean"
######################################################
remove-item -path $TempFiles -ErrorAction SilentlyContinue
ahora ejecutamos con cuenta de administrador Powershell.
get-childitem ‘C:Program Files (x86)Windows Kits10Assessment and Deployment Kit*.wim’ -recurse | c:.Repair-1511ADK.ps1 -verbose
sin mas por el momento un gran saludo a todos mis lectores, estamos con nuevos post.