VMware Performance Community
ODB2001
Enthusiast
Enthusiast
Jump to solution

PowerCLI Service failed to start

Afternoon

Getting the above error while trying to run VMMark2.

Logs attached.

Already added the following to vmmark2config:

RMQ_MinInitDelay=60

RMQ_WorkerDelay=5

RMQ_PowerCLI_Delay=60

Installed PowerCLI v5.8 and Cygwin 32bit

Thanks

Oliver

Reply
0 Kudos
1 Solution

Accepted Solutions
jamesz08
VMware Employee
VMware Employee
Jump to solution

Open vmmark2\tools in File Explorer, right click VMmark2PSfe.ps1 and select properties.  If there is an Unblock button, click it, then rerun the previous command.

What version of powershell do you have installed? Run get-host in powershell it will list the PSVersion. Only 2.0 is supported so if you updated please remove the update.

If none of this is the problem it seems there might be a some sort of corruption of the ps1 file.  Try extracting the kit again.

Possibly the encoding of the file is being changed, run this command in powershell to get the encoding:

Get-Content -Encoding byte -ReadCount 4 -TotalCount 4 .\VMmark2PSfe.ps1

Should be

35

32

32

32

Make sure everything is set to English, United States in Control Panel > Language and Regional and Language Options

View solution in original post

Reply
0 Kudos
6 Replies
jamesz08
VMware Employee
VMware Employee
Jump to solution

Please follow the steps listed here to speed up powercli load times:

http://www.virtu-al.net/2010/07/05/speed-up-powercli/

Please set DEBUGFLAG=1 in your VMMARK3.CONFIG and rerun. 

Reply
0 Kudos
ODB2001
Enthusiast
Enthusiast
Jump to solution

IE setting changed and debug flag enabled. No change.

Logs attached.

Thanks

Reply
0 Kudos
jamesz08
VMware Employee
VMware Employee
Jump to solution

Try manually running the powercli initialization to see if there are more errors messages:

1. Launch powershell (start, type powershell)

2. run the command:

C:\vmmark2\tools\VMmark2PSfe.ps1 -workers 3 -rabbit localhost -vc DXGBSSC1VMC001 -u administrator@vsphere.local -p P@ssword01 -outfile debug

If it starts just use Ctrl-C to quit.

You should get 3 files out, please post them (some might not get created if it fails):

debug.txtVMmark2PSfe.txt

debugVMmarrk2PSfe.txt

VMmark2PSbe.txt

Reply
0 Kudos
ODB2001
Enthusiast
Enthusiast
Jump to solution

Hi, there's only one file generated:

debugVMmark2PSfe.txt

Which contains:

VMmark2 PSfe 1.2

  Starting Up VMmark2PS Workers : Started 3

  Loadtime  = 00:00:00.81

  Polling Workers State ::

   2 : Error!

   4 : Error!

   6 : Error!

   8 : Error!

   10 : Error!

   12 : Error!

Error Initializing Workers

  Errors Found : 6

  Workers Ready : 0

Error Initializing Workers (6) : Halting Workers : Purging Qs : Done

But the output of the Powershell window shows a lot of errors:

Method invocation failed because [System.Management.Automation.PSRemotingJob] doesn't contain a method named

'op_Addition'.

At C:\vmmark2\tools\VMmark2PSfe.ps1:241 char:9

+         $RunningJobs += $j

+         ~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (op_Addition:String) [], RuntimeException

    + FullyQualifiedErrorId : MethodNotFound

Method invocation failed because [System.Management.Automation.PSRemotingJob] doesn't contain a method named

'op_Addition'.

At C:\vmmark2\tools\VMmark2PSfe.ps1:241 char:9

+         $RunningJobs += $j

+         ~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (op_Addition:String) [], RuntimeException

    + FullyQualifiedErrorId : MethodNotFound

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:33

    + CategoryInfo          : NotSpecified: (At C:\VMmark2\t...s1:1414 char:33:String) [], RemoteException

    + FullyQualifiedErrorId : NativeCommandError

    + PSComputerName        : localhost

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                 ~~~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:42

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                          ~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

    + CategoryInfo          : ParserError: (:) [], ParseException

    + FullyQualifiedErrorId : InvalidVariableReferenceWithDrive

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:33

    + CategoryInfo          : NotSpecified: (At C:\VMmark2\t...s1:1414 char:33:String) [], RemoteException

    + FullyQualifiedErrorId : NativeCommandError

    + PSComputerName        : localhost

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                 ~~~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:42

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                          ~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

    + CategoryInfo          : ParserError: (:) [], ParseException

    + FullyQualifiedErrorId : InvalidVariableReferenceWithDrive

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:33

    + CategoryInfo          : NotSpecified: (At C:\VMmark2\t...s1:1414 char:33:String) [], RemoteException

    + FullyQualifiedErrorId : NativeCommandError

    + PSComputerName        : localhost

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                 ~~~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:42

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                          ~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

    + CategoryInfo          : ParserError: (:) [], ParseException

    + FullyQualifiedErrorId : InvalidVariableReferenceWithDrive

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:33

    + CategoryInfo          : NotSpecified: (At C:\VMmark2\t...s1:1414 char:33:String) [], RemoteException

    + FullyQualifiedErrorId : NativeCommandError

    + PSComputerName        : localhost

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                 ~~~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:42

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                          ~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

    + CategoryInfo          : ParserError: (:) [], ParseException

    + FullyQualifiedErrorId : InvalidVariableReferenceWithDrive

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:33

    + CategoryInfo          : NotSpecified: (At C:\VMmark2\t...s1:1414 char:33:String) [], RemoteException

    + FullyQualifiedErrorId : NativeCommandError

    + PSComputerName        : localhost

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                 ~~~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:42

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                          ~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

    + CategoryInfo          : ParserError: (:) [], ParseException

    + FullyQualifiedErrorId : InvalidVariableReferenceWithDrive

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:33

    + CategoryInfo          : NotSpecified: (At C:\VMmark2\t...s1:1414 char:33:String) [], RemoteException

    + FullyQualifiedErrorId : NativeCommandError

    + PSComputerName        : localhost

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                 ~~~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

At C:\VMmark2\tools\VMmark2PSbe.ps1:1414 char:42

+         WriteOut "$Func : $VC : $Cluster:$tiles: $global:OutFile" "both"

+                                          ~~~~~~~

Variable reference is not valid. ':' was not followed by a valid variable name

character. Consider using ${} to delimit the name.

    + CategoryInfo          : ParserError: (:) [], ParseException

    + FullyQualifiedErrorId : InvalidVariableReferenceWithDrive

Exception calling "LoadFile" with "1" argument(s): "An attempt was made to load an assembly from a network location

which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the

.NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to

sandbox the assembly, please enable the loadFromRemoteSources switch. See

http://go.microsoft.com/fwlink/?LinkId=155569 for more information."

At C:\vmmark2\tools\VMmark2PSfe.ps1:215 char:8

+        $Rab = [Reflection.Assembly]::LoadFile("C:\VMmark2\tools\RabbitMQ.Client. ...

+        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException

    + FullyQualifiedErrorId : NotSupportedException

new-object : Cannot find type [RabbitMQ.Client.ConnectionFactory]: make sure the assembly containing this type is

loaded.

At C:\vmmark2\tools\VMmark2PSfe.ps1:216 char:19

+        $factory = new-object RabbitMQ.Client.ConnectionFactory

+                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidType: (:) [New-Object], PSArgumentException

    + FullyQualifiedErrorId : TypeNotFound,Microsoft.PowerShell.Commands.NewObjectCommand

Unable to find type [RabbitMQ.Client.ConnectionFactory]: make sure that the assembly containing this type is loaded.

At C:\vmmark2\tools\VMmark2PSfe.ps1:217 char:8

+        $hostNameProp = [RabbitMQ.Client.ConnectionFactory].GetField("HostName")

+        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (RabbitMQ.Client.ConnectionFactory:TypeName) [], RuntimeException

    + FullyQualifiedErrorId : TypeNotFound

You cannot call a method on a null-valued expression.

At C:\vmmark2\tools\VMmark2PSfe.ps1:218 char:8

+        $hostNameProp.setValue($factory,$global:RabbitServer)

+        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException

    + FullyQualifiedErrorId : InvokeMethodOnNull

Unable to find type [RabbitMQ.Client.ConnectionFactory]: make sure that the assembly containing this type is loaded.

At C:\vmmark2\tools\VMmark2PSfe.ps1:219 char:8

+        $createConnectionMethod = [RabbitMQ.Client.ConnectionFactory].GetMethod(" ...

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (RabbitMQ.Client.ConnectionFactory:TypeName) [], RuntimeException

    + FullyQualifiedErrorId : TypeNotFound

You cannot call a method on a null-valued expression.

At C:\vmmark2\tools\VMmark2PSfe.ps1:220 char:8

+        $connection = $createConnectionMethod.Invoke($factory, "instance,public", ...

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException

    + FullyQualifiedErrorId : InvokeMethodOnNull

You cannot call a method on a null-valued expression.

At C:\vmmark2\tools\VMmark2PSfe.ps1:221 char:8

+        $global:channel = $connection.CreateModel()

+        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException

    + FullyQualifiedErrorId : InvokeMethodOnNull

You cannot call a method on a null-valued expression.

At C:\vmmark2\tools\VMmark2PSfe.ps1:128 char:9

+         $QD = $global:channel.QueueDelete("vmmark")

+         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException

    + FullyQualifiedErrorId : InvokeMethodOnNull

Any more idea's? Thanks for looking into this so far by the way Smiley Happy

Reply
0 Kudos
jamesz08
VMware Employee
VMware Employee
Jump to solution

Open vmmark2\tools in File Explorer, right click VMmark2PSfe.ps1 and select properties.  If there is an Unblock button, click it, then rerun the previous command.

What version of powershell do you have installed? Run get-host in powershell it will list the PSVersion. Only 2.0 is supported so if you updated please remove the update.

If none of this is the problem it seems there might be a some sort of corruption of the ps1 file.  Try extracting the kit again.

Possibly the encoding of the file is being changed, run this command in powershell to get the encoding:

Get-Content -Encoding byte -ReadCount 4 -TotalCount 4 .\VMmark2PSfe.ps1

Should be

35

32

32

32

Make sure everything is set to English, United States in Control Panel > Language and Regional and Language Options

Reply
0 Kudos
ODB2001
Enthusiast
Enthusiast
Jump to solution

Hi James

I'd already done the "unblock" file thing a while ago, same results anyway.

I was running version 3 but have since uninstalled the version 3 framework and back down to version 2. This has appeared to have fixed it! Well, it's got past the PowerCLI service start stage anyway Smiley Happy Thank you for persevering with me!

I really wish VMware did a whole lab that could just be extracted and ran for this, the build guide is very long winded and convoluted.

I've got my figners crossed it makes it to the end this time Smiley Happy

Reply
0 Kudos