/ PS脚本
$connection = "localhost:19000"
$timeToRun = 60
$maxStabilizationTimeSecs = 180
$waitTimeBetweenFaultsSec = 10
$serviceName = "fabric:/****.OnServiceFabric.Policy.Deploy"
Connect-ServiceFabricCluster $connection
Invoke-ServiceFabricFailoverTestScenario -TimeToRunMinute $timeToRun -MaxServiceStabilizationTimeoutSec $maxStabilizationTimeSecs -WaitTimeBetweenFaultsSec $waitTimeBetweenFaultsSec -ServiceName $serviceName -PartitionKindSingleton
Pause
//我尝试运行服务时的错误
PS C:\Temp> C:\Temp\failovertest.ps1
True
Invoke-ServiceFabricFailoverTestScenario : GetServiceDescription for service fabric:/****.OnServiceFabric.Policy.Deploy with timeout 00:01:00 failed with 2147949517. The error code is not in success &
retry error codes.
At C:\Temp\failovertest.ps1:9 char:1
+ Invoke-ServiceFabricFailoverTestScenario -TimeToRunMinute $timeToRun -MaxService ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (Microsoft.Servi...usterConnection:TestabilityClusterConnection) [Invoke-ServiceFabricFailoverTestScenario], FabricServiceNotFoundException
+ FullyQualifiedErrorId : InvokeFailoverTestErrorId,Microsoft.ServiceFabric.Testability.Powershell.InvokeFailoverTestScenario
Press Enter to continue...:
我在VM上运行它,所以在进程监视器中它显示****。CloudServices.OnServiceFabric.Host。我也使用过它,但它不起作用