Will installing a non-applicable driver using PNPUTIL cause problems?


  1. Posts : 14
    Windows 10 Pro 64-bit
       #1

    Will installing a non-applicable driver using PNPUTIL cause problems?


    Let's say that you issued this command at the command prompt:

    pnputil -i -a C:\drivers\example.inf

    The catch: example.inf is a driver for hardware that does not exist on the hardware.

    Will this cause problems? In other words, is Windows smart enough to check first if the applicable hardware exists, or does it blindly try to install the device, anyway?

    I ask because I vaguely remember trying this years ago and having problems, but I don't know/remember if it was caused by this or something else.
      My Computer


  2. Posts : 725
    Desk 1: Win 7 Pro x32; Desk 2: Windows 10 x64
       #2

    loosus456 said:
    Will this cause problems? In other words, is Windows smart enough to check first if the applicable hardware exists, or does it blindly try to install the device, anyway?
    No. Not a problem.

    Driver installation is "staged"
    Stage 1, a copy of the driver files are loaded into the Windows "DriverStore".
    Stage 2, the driver files remain in the Store until either a) h/w detected that needs the driver or b) Windows is specifically directed to install the driver for run-time


    pnputil only loads the files into the DriverStore. If no h/w needs that driver, the files just sit in the Store till needed
      My Computer


  3. Posts : 14
    Windows 10 Pro 64-bit
    Thread Starter
       #3

    Yeah, I use PNPUTIL extensively, but I have only used it for staging, not installation. What we've done until recently is staged all our drivers into a universal image for all our computers. When we had only about 4 computer models, we were golden. But we have almost 14 different models roaming around now.

    Recently, we started running into an issue because there were apparently conflicts between drivers. It seems that some SATA controllers and some chipsets were trying to use the wrong driver. It resulted in BSODs.

    So now, rather than injecting all drivers into an image pre-Sysprep, we have a script install the drivers after deployments, and the script attempts to install only the drivers (using PNPUTIL) that are applicable to the computer model.

    The problem we didn't foresee? There are variations even among computers of a specific computer model! Three computers of the exact same computer model may have slightly different NICs, for example.

    So, using that example, I would want to attempt to install all three NIC drivers and only want that one that is needed to actually install.

    To be clear (your post made it sound like you may not be 100% clear about this), I am using PNPUTIL to do more than just stage a driver. I am also using it to install the driver (i.e., notice the -i switch in my example command). Does that extra clarity change your answer at all, or do you still think I still be good using PNPUTIL to install drivers for hardware that doesn't exist?
      My Computer


  4. Posts : 725
    Desk 1: Win 7 Pro x32; Desk 2: Windows 10 x64
       #4

    ooops. Overlooked the /i.

    Let's call the machine you're building the image on the "reference machine".

    pnputil /a loads the driver into the Store on the reference machine. /i tells Windows to next check the h/w on the reference machine and install based on the reference machine.

    Why use /i on the reference machine? Why not let Windows search through the DriverStore on the target machine after the image is deployed as plug-and-play detects the new h/w on the target?

    /* EDIT */
    i.e. Let plug-and-play search for the best driver on the target when the specific NIC is detected

    /* EDIT2 */
    Re: SATA. I would GUESS that may be the only driver you may need pre-install

    p.s. I'm not a sys admin. Just a geek. So this is based on what i've tried and discovered on how Windows drivers work. But i'd try just preinstalling SATA. When PnP detects new h/w it will search all the drivers in the Store and select "best match" based on Windows selection criteria. On rare occasion, i've sometimes seen Windows select the wrong driver. But that's been the rare exception. i'd try letting PnP do its thing first and let IT select the driver from the Store to install
      My Computer


  5. Posts : 14
    Windows 10 Pro 64-bit
    Thread Starter
       #5

    I'm not using /i on the reference machine. The script runs after deployment, not on the reference machine. So /i is running on the deployed machines, not the image reference machine.

    And as I said in the post above, I can't add all the drivers I need in the reference image using /a because we have so many computer models now that it causes issues; Windows now sometimes incorrectly chooses the wrong driver, which results into BSODs. This happens because there are so many drivers to choose from. When we added all drivers to the reference image using /a, there were literally about 600 drivers added to the driver store.
      My Computer


  6. Posts : 725
    Desk 1: Win 7 Pro x32; Desk 2: Windows 10 x64
       #6

    Again, I'm not a sys admin so will just try to add what i can
    1. /i
    Windows documentation for pnputil states it's only installed for "matching devices" which i read as "hardware exists" but couldn't say for certain. You'd have to test to verify
    /i
    Installs the driver package on matching devices that are connected to the system. The driver package is installed after it is added to the driver store.
    2. Are you familiar with devcon utility? It's part of the WDK. The devcon drivernodes command
    Lists all driver packages that are compatible with the device, along with their version and ranking. Valid only on the local computer.
    The driver with the highest ranking (smallest number) is the one Windows will choose. It might be helpful to verify that Windows will choose the driver you want from the Store.. rather then trying to install one that Windows might supercede with something else should it search and rank all the drivers it has to choose from
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 06:38.
Find Us