Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

Handling CIM Exceptions

$
0
0

Hello There,

I am working with Windows Deployment Services and ultimately I was to disable a hosts capability to pxe boot after it has finished installing.  Currently I have a task sequence setup to run a powershell script that takes in domain credentials and then runs the Set-Wdsclient cmdlet to disable the pxe boot.  However I am constantly running into a Cim Exception.  I am not sure how to handle these errors.  I am running this command on the freshly installed host after importing the WDS module through a PSSession with the install server.

Invoke-Command -Credential $(Get-Credential) -ComputerName $(our install server) -ScriptBlock { Set-WDSClient -Verbose -DeviceID $(mac address) -DeviceName $(device name) -Domain -DomainName $(domain name) -User $(domain account with creds) -JoinRights Full -ReferralServer $(our install server) -pxePromptPolicy Abort }
The operation being requested was not performed because the user has not been authenticated.+ CategoryInfo          : NotSpecified: (MSFT_WdsClient:root/cimv2/MSFT_WdsClient) [Set-WdsClient], CimException+ FullyQualifiedErrorId : 0x4DC,Set-WdsClient+ PSComputerName        : $(our install server)
 NotSpecified: (MSFT_WdsClient:root/cimv2/MSFT_WdsClient) [Set-WdsClient], CimException
Has anyone every gotten a cim exception like this before? Any help would be greatly appreciated

Thank You!

~Adam



Viewing all articles
Browse latest Browse all 21975

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>