Access Denied on Start-DscConfig

Welcome Forums DSC (Desired State Configuration) Access Denied on Start-DscConfig

This topic contains 2 replies, has 2 voices, and was last updated by

Joe
 
Participant
3 years, 9 months ago.

  • Author
    Posts
  • #23918
    Joe

    Participant
    Points: 0
    Rank: Member

    Hi all,

    I'm a dev and I've been jazzed by the DSC and I'm trying to getting a simple DSC push working, but running into an error.

    I spun up 2 Windows Server 2012 R2 VMs in the cloud and on the target I changed the firewall restriction on the WRM rule to all IPs (its just for testing). Then on the other VM I was able to validate this by running (Test-WSMan -ComputerName 52.4.84.1) and getting a valid response. I then generated the mof files and executed "Start-DscConfiguration -wait -verbose -path .\WebSiteConfig". That failed with the error below:

    VERBOSE: Perform operation 'Invoke CimMethod' with following parameters, "methodName' =
    SendConfigurationApply,'className' = MSFT_DSCLocalConfigurationManager,'namespaceName' =
    root/Microsoft/Windows/DesiredStateConfiguration'.
    Access is denied.
    + CategoryInfo : PermissionDenied: [root/Microsoft/...gurationManager:String] [], CimException
    + FullyQualifiedErrorId : HRESULT 0x80070005
    + PSComputerName : 52.4.84.1

    VERBOSE: Operation 'Invoke CimMethod' complete.
    VERBOSE: Time taken for configuration job to complete is 0.032 seconds

    I made sure that I was running the shell as Administrator as still no go. After reading up some more, I ran a cim command (Get-CimClass -ComputerName 52.4.84.1 -ClassName Win32_Process) to see if that works and that too failed

    Get-CimClass : Access is denied.
    At line:1 char:1
    + Get-CimClass -ComputerName 52.4.84.1 -ClassName Win32_Process
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : PermissionDenied: (root\cimv2:Win32_Process:String) [Get-CimClass], CimException
    + FullyQualifiedErrorId : HRESULT 0x80070005,Microsoft.Management.Infrastructure.CimCmdlets.GetCimClassCommand
    + PSComputerName : 52.4.84.1

    But, if I execute the same command on the target VM I get back a valid response. So I don't know if it's a firewall issue or some other configuration I need to apply on the target. I would really appreciate any pointers!!!

    Thanks

  • #23926

    Moderator
    Points: 24
    Team Member
    Rank: Member

    Hi Joe,

    I assume you are using the local Administrator account on both machines. Is the Administrator user password on the 2nd machine the same as on the 1st machine?

    Regards
    Daniel

  • #23929
    Joe

    Participant
    Points: 0
    Rank: Member

    Thanks Daniel. What a rookie mistake!!! 🙂

The topic ‘Access Denied on Start-DscConfig’ is closed to new replies.