Printers and their associated ports and drivers can be imported and exported using the Windows native tool printbrm.exe. It’s not included in the PATH environment variable and therefore must be run with explicit reference to its path. While it’s typically used for print servers, it can also be used on workstations.
Important
Printbrm.exe does not work with paths that include spaces or some other special characters. It also does not support use of quotes to include spaces in paths it processes. Including these characters will return “file not found” or (in the case of a path which includes a hyphen) “unrecognized argument” errors.
Also note that a user’s personal OneDrive as managed by an organization will include a hyphen in the folder name in the form of “OneDrive – [org name]”. This path is also used when folders are redirected, such as when using KFM (Known Folder Move).
When importing & exporting printers, keep in mind the user context the import or export is being run within. A user can only import or export printers to and from their own user profile. This also means if an export run from User A is imported in the context of User B, the printers User A had will restore to User B’s user profile.
To export the printers:
%windir%\System32\spool\tools\printbrm.exe -b -f c:\printers.printerExport -o force -p all
To import the printers:
%windir%\System32\spool\tools\printbrm.exe -r -f C:\printers.printerExport -o force -p all
Events from printbrm.exe (or the GUI migration utility) can be found in the Event Viewer here:
Applications and Services Logs/Microsoft/Windows/PrintBRM/Admin
Printbrm event IDs:
See also:
- https://techcommunity.microsoft.com/t5/ask-the-performance-team/migrating-print-queues-quickly-using-printbrm-configuration/ba-p/375052
- https://ss64.com/nt/printbrm.html
- https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-R2-and-2012/jj134237(v=ws.11)
- https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-r2-and-2012/jj519448(v=ws.11)
- https://social.technet.microsoft.com/Forums/lync/en-US/cdcf1f9a-9703-463e-ab89-31f6904c3013/printbrmexe-fails-to-import-all-print-queues-event-id-81-error-0x800706ba?forum=winserverprint
- https://www.papercut.com/kb/Main/DriverIsolation#change-the-driver-isolation-mode-for-an-individual-driver
- https://learn.microsoft.com/en-us/windows-hardware/drivers/print/printer-driver-isolation