This article is primarily targeted at Czech state institutions and is based on recommendations of the Czech authority. However,...
Installing drivers from command lineLukas Beran
If you want (for some reason) to install drivers from command line, for example on Windows Server Core edition or Hyper-V Server, you can use pnputil.
usage is very simple. It’s commonly used with parameter -a, which specifies INF file of the driver you want to install, and with parameter -i, which installs the driver. For example pnputil -i -a C:\Drivers\driver.inf adds and installs driver located at C:\Drivers\driver.inf.
- -a Specifies to add the identified INF file.
- -d Specifies to delete the identified INF file.
- -e Specifies to enumerate all third-party INF files.
- -f Specifies to force the deletion of the identified INF file. Cannot be used in conjunction with the –i parameter.
- -i Specifies to install the identified INF file. Cannot be used in conjunction with the -f parameter.
pnputil.exe -a a:\usbcam\USBCAM.INF
- Adds INF file USBCAM.INF
pnputil.exe -a c:\drivers\*.inf
- Adds all INF files from c:\drivers\
pnputil.exe -i -a a:\usbcam\USBCAM.INF
- Adds and installs specified INF file.
- Enumerates all third-party drivers.
pnputil.exe -d oem0.inf
- Deletes the specified files.
pnputil.exe -f -d oem0.inf
- Forces the deletion of the specified INF file.