Get-WmiObject : Retrieving the COM class factory for component with CLSID {xxx} failed due to the following error: 80070005.

Get-WmiObject : Retrieving the COM class factory for component with CLSID {xxx} failed due to the following error: 80070005.

I have been writing about this before:

http://larslohmann.blogspot.dk/2013/05/cscript-error-can-find-script-engine.html

Apparently not only vbscript is affected by this but also PowerShell.

Get-WmiObject : Retrieving the COM class factory for component with CLSID {xxx} failed due to the following error: 80070005.

The script works outside the task sequence also with alternate credentials and task sequence is not in WinPE phase.

image

When trying to connect to the SCCM server (WMI) from a task sequence step with alternate credentials the problem shows up again.

Since last time I have also seen the problem with dotNet 1.1 is installed.

The workaround is the same as in the original post, and with the workaround implemented  the script works as expected, Powershell code shown here with workaround marked.

image

 

image

Table of Contents

Share this post
Search blog posts
Search
Authors
Modern Workplace consultant and a Microsoft MVP in Enterprise Mobility.
Modern Workplace consultant and a Microsoft MVP in Windows and Devices for IT.

Infrastructure architect with focus on Modern Workplace and Microsoft 365 security.

Cloud & security specialist with focus on Microsoft backend products and cloud technologies.

Cloud & Security Specialist, with a passion for all things Cybersecurity

Cloud and infrastructure security specialist with background in networking.

Infrastructure architect with focus on design, implementation, migration and consolidation.

Infrastructure consultant with focus on cloud solutions in Office365 and Azure.

follow us in feedly
Categories

Follow on SoMe