SQL cluster node installation via PS

Hi all,

I have been trying different approaches to install SQL Server clusters with PS using various methods like invoke-command, creating a scheduled task, running a batch file, etc. without success. I can install the primary node, but am running into problems when I am trying to do the other nodes. Regardless of whether I’ve copied all installation files locally or accessed them via UNC, the issue remains that when I log on interactively with the machine, I can use what I have to do a successful node installation. When I try to do it without interaction, it fails. The SQL installation method is via command line using a config. file and the Addnode installation parameter.

Rather than describe all the failed attempts, I’m hoping I can describe the need & some of the issues I’ve encountered and someone can suggest a solution.


  1. script must run as elevated
  2. installation files exist on a UNC path (relative to the remote cluster node where the install occurs)
  3. script should not require user input or interaction
  4. script must be able to access the Windows Installer cache
  5. it is acceptable to use/pass the credentials of the person doing the installation on the primary node to the others

Issues encountered so far:

batch file runs (invoke-command), returns process, but fails immediately (no log info)
powershell script runs a remote PS script (invoke-command), but hangs due to IE Zone setting, preventing exec. PS script exec set to -Bypass or -RemoteSigned script runs as System via schtasks, but cannot access Windows Installer cache
script cannot cache credentials of installer (schtasks)

Let me know if you need more information.

Have you looked into doing this with DSC? It provides specific resources for HA clusters.