Import boot image drivers from existing boot image

Boopathi Subramaniam 3,301 Reputation points
2021-10-08T19:37:28.963+00:00

Hello,

I performed "Reload this boot image with the current Windows PE version from the Windows ADK" due to few taps were missing. But already imported drivers are not found. Used "Copy-FBBootImageDrivers.ps1" script from https://github.com/fredbainbridge/ConfigMgrScripts and tried to copy the drivers using the below command

Copy-FBBootImageDrivers -SiteServer "ABC.Domain.Local" -SiteCode "XXX" -SourceBootImageID "XXX00011" -DestinationBootImages "XXX00012" -Verbose

Reference URL : https://fredbainbridge.com/2016/08/09/import-boot-image-drivers-from-existing-boot-image/

Command execution finished very quickly and no change found the boot image.
Powershell windows is opened from SCCM Console [Connect via Windows Powershll ISE]

Please help what is the correct method to import boot image drivers from existing boot image

Microsoft Configuration Manager Deployment
Microsoft Configuration Manager Deployment
Microsoft Configuration Manager: An integrated solution for for managing large groups of personal computers and servers.Deployment: The process of delivering, assembling, and maintaining a particular version of a software system at a site.
942 questions
0 comments No comments
{count} votes

Accepted answer
  1. AllenLiu-MSFT 43,061 Reputation points Microsoft Vendor
    2021-10-11T07:53:32.48+00:00

    Hi, @Boopathi Subramaniam
    Thank you for posting in Microsoft Q&A forum.

    Please try the simple script, note to change the "Set-Location -Path" to your site code, "$bimg_src" to your existing boot image name, "$bimg_dst" to your new boot image name.

    Import-Module ($Env:SMS_ADMIN_UI_PATH.Substring(0,$Env:SMS_ADMIN_UI_PATH.Length-5) + '\ConfigurationManager.psd1') -Verbose:$false  
    Set-Location -Path "PRI:"  
      
    $bimg_src = "Boot image (x64)"  
    $bimg_dst = "winpe"  
      
    $BIdrivers = Get-CMBootImage -Name $bimg_src  
      
    $BIdriverIDs = (Get-CMBootImage -Name $bimg_src).ReferencedDrivers.ID  
    foreach ($ID in $BIdriverIDs)  
    {  
     $BIdrivers = Get-CMDriver -Id $ID  
      
      
      
     foreach ($BIdriver in $BIdrivers)  
     {  
      
     #Set-CMDriverBootImage -SetDriveBootImageAction AddDriverToBootImage -DriverName "Adaptec Embedded SCSI HostRAID Controller" -BootImageName "Boot image (x64)"  
     Set-CMDriverBootImage -SetDriveBootImageAction AddDriverToBootImage -DriverName $BIdriver.LocalizedDisplayName -BootImageName $bimg_dst  
      
     }  
      
    }  
    

    Here is my test result.
    139336-1.jpg


    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


0 additional answers

Sort by: Most helpful