How to Recover/Export Windows Drivers

How to Recover/Export Windows Drivers

recipe command cmdlet drivers powershell windows export

This recipe is about the Export-WindowsDriver cmdlet in Windows and how to use it to export the drivers present in a running windows installation to a directory.

PowerShell is a command-line shell and scripting language used in Windows to automate or interact with the system in a CLI fashion. Hated by some and adored by others as many tools; but with some secrets that you can use to simplify your life.

Export-WindowsDriver cmdlet exports all third-party drivers from a Windows image to a destination folder.

The syntax is:

Export-WindowsDriver
      [-Destination <String>]
      -Path <String> | [-Online]
      [-WindowsDirectory <String>]
      [-SystemDrive <String>]
      [-LogPath <String>]
      [-ScratchDirectory <String>]
      [-LogLevel <LogLevel>]
      [<CommonParameters>]

Some examples:

Export drivers from the running operating system

Export-WindowsDriver -Online -Destination d:\drivers

Export drivers from an offline image

Export-WindowsDriver -Path c:\offline-image\path -Destination d:\drivers

To get all drivers from a new machine and save them to the "EM_Drivers" folder

Export-WindowsDriver -Online -Destination C:\EM_Drivers -LogLevel 1

Hope it helps you
Have a great day

-G

Hope you find this useful, if you have any question please visit my twitter @bigg_blog and if you have a couple of pounds make a donation .

Add a comment

Previous Post Next Post