Import Bare Metal Devices into SCCM using PowerShell

Import Bare Metal Devices into SCCM using PowerShell

Many of you will have been in situations where you need to pre-stage bare metal devices in SCCM by importing them into a collection. Maybe this is because the OS task sequence you are deploying is not advertised to Unknown computers or your environment may not be setup for unknown computer support. What you would normally do is in the SCCM console right click devices and import a device by either choosing single computer or using a csv file containing multiple machines. In this guide i will show you how to do exactly this but through PowerShell for efficiency.

Firstly from within the SCCM Admin console click the dark blue ribbon at the top and choose “Connect via Powershell”.


Once the powershell window has launched you are now connected directly to your SCCM site.

If you just want to import one single device into SCCM you can do this using the script below and replacing the collection name, computer name and mac address to suit your environment.

Import-CMComputerInformation -CollectionName “All Systems” -ComputerName “Computer01” -MacAddress “00:12:34:56:78”

If you would like to import multiple devices using powershell you need to have a pre-created CSV file containing the Computer Name and Mac Addresses in the first two columns and then run the script below. NOTE: the EnableColumnHeadings should only be set to $true if you have headings in your csv. If not you need to set this to $false

Import-CMComputerInformation -CollectionName “All Systems” -FileName “C:\computers.csv” -EnableColumnHeadings $True

You have now quickly imported your bare metal devices into a specific collection and they can now network boot to receive the task sequence you have assigned the collection.

Leave a Reply

Your email address will not be published.