Quantcast
Viewing all articles
Browse latest Browse all 21975

Properly handle DSC Reboot

I'm trying to install sql server with

xSqlServerInstall

When I Start-DscConfiguration it runs perfectly and it ends with a message like this

ERBOSE: [WEBTEST2]:                            [] A reboot is required to progress further. Please reboot the system.

I've tried to make DSC automatically reboot the machine with this configuration

$ConfigurationData = @{
    AllNodes = @(
        @{
            NodeName="WebTest2"
            PSDscAllowPlainTextPassword=$true
            RebootNodeIfNeeded = $true
         }
   )
}

But it seems not working, machine does not get rebooted and the Start-DscConfiguration stops telling me to reboot.

Now I have a couple of questions, the first is "how I can force DSC to reboot the machine if some resource asks to reboot?".

The second is: suppose I do a manual reboot, when I launch Start-DscConfiguration again I got

An old configuration is still pending. Please wait for the pending configuration to finish. If the problem persists,

execute Start-DSCConfiguration command with -Force parameter.

I waited for 30 minutes and nothing happens on target machine, CPU 0% no process installing MsSql is running.

How can I verify what DSC is actually doing on the target machine?

Probably I did something wrong with xSqlServerInstall, because after reboot, if I Start-DscConfiguration again with -Force it will always ask me for a reboot.

Gian Maria.


Ricci Gian Maria. (http://www.codewrecks.com)



Viewing all articles
Browse latest Browse all 21975

Trending Articles



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