Hi Team
I am Unable to run power shell script through python in HPC 2016 the same script works fine in HPC 2012.
Script i am using from python
def cerate_xml():
p = subprocess.Popen(
["powershell.exe", "-ExecutionPolicy", "ByPass", "-File",
"D:\\HPC_Automation_Scripts\\Compare xml\\first_script.ps1"],
stdout=sys.stdout)
p.communicate()
Error message is as below
et-HpcNode : The type initializer for 'Microsoft.Hpc.Trace.HpcTraceListener' threw an exception.
At D:\HPC_Automation_Scripts\Compare xml\first_script.ps1:2 char:1
+ Get-HpcNode -State Online -scheduler OZAS012A
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (Microsoft.ComputeCluster.CCPPSH.GetNode:GetNode) [Get-HpcNode], TypeIniti
alizationException
+ FullyQualifiedErrorId : Microsoft.ComputeCluster.CCPPSH.GetNode