Export-WindowsDriver and Blue Screnn

~OSD~ 2,126 Reputation points
2024-01-13T19:19:45.0966667+00:00

Hi, I am exporting the device drivers using the following command. And everything is fine.

Export-WindowsDriver -Online -Destination "full path of folder"

Background: Due to some reasons, the operating system contains device drivers for multiple computer models. The motivation to include many drivers was to use the same image for multiple hardware types with Sysprep with generalize option which will uninstall the devices that are not present... so the approach was good in this context. Problem Description: When I exported the drivers, obviously it was a set of all available drivers that were injected into the operating system.
When I use the pnputil /add-driver with /subdirs /install option on a particular machine, I receive a blue screen, as it tries to install all drivers (a mix of a few models).

Question: Is it possible to somehow export only the drivers that are specific to a machine where I execute Export-WindowsDriver command?
Or, when installing it, can we specify drivers which a machine needs and ignore anything else using when using pnputil /add-driver ?

Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
10,646 questions
Operations Manager
Operations Manager
A family of System Center products that provide infrastructure monitoring, help ensure the predictable performance and availability of vital applications, and offer comprehensive monitoring for datacenters and cloud, both private and public.
1,417 questions
Microsoft Deployment Toolkit
Microsoft Deployment Toolkit
A collection of Microsoft tools and documentation for automating desktop and server deployment. Previously known as Microsoft Solution Accelerator for Business Desktop Deployment (BDD).
831 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,201 questions
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.
905 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. AllenLiu-MSFT 40,401 Reputation points Microsoft Vendor
    2024-01-15T02:20:18.6233333+00:00

    Hi, @~OSD~

    Thank you for posting in Microsoft Q&A forum.

    I think it is not possible to export only the drivers that are specific to a machine using the Export-WindowsDriver command. This command exports all the drivers that are currently installed on the system.

    However, when using the pnputil /add-driver command, we can specify the exact driver package that we want to install, you may check if you use the command correctly.

    For example, if we have a driver package located at C:\Drivers\MyDriver.inf, we can install only that driver package by running the following command:

    pnputil /add-driver C:\Drivers\MyDriver.inf /install
    

    This should install only the driver package specified and ignore any other drivers that may be present in the same folder.


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Add comment".