VMware Cloud Community
TheVMinator
Expert
Expert
Jump to solution

Connect-omserver fails

Can't connect to vROps using powercli - get this error:

Connect-OMServer : 12/16/2016 7:20:14 PM Connect-OMServer The provided username/password

or token is not valid. Please try again. 

At line:1 char:1

+ Connect-OMServer vropsnyc001 -User john.anders -Password P@ssw0rd

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

  + CategoryInfo : NotSpecified: (:) [Connect-OMServer], OMException

  + FullyQualifiedErrorId : OM_ConnectivityServiceImpl_ConnectOMServer_ByUserNameAndPassword_Serve

  rError,VMware.VimAutomation.vROps.Commands.Cmdlets.ConnectOMServer

However, this username and password is the same one I use to authenticate to vROps through the web UI.  When I connect through the webUI, I'm specifiying the AD domain under "Authentication Source", and it works.  Is it possible that my account has permissions to log in through the web UI but not via the command line? 

Reply
0 Kudos
1 Solution

Accepted Solutions
dtaliafe
Hot Shot
Hot Shot
Jump to solution

Use the name of your authentication source in vROps shown here:

authsource.jpg

You can also use the "-AuthSource" parameter to specify this:

Connect-OMServer -Server vrops.mydomain.com -User username -Password password -AuthSource "Source Display Name"

Using username@authsource without the "-AuthSource" parameter will also work, but I didn't see any reference of this in the cmdlet's help.

View solution in original post

Reply
0 Kudos
6 Replies
grhohertz
Enthusiast
Enthusiast
Jump to solution

Use a fully qualified user / domain / import source name:

user@domain@importsource

Where import source is the label you gave your AD Auth source in vROps.

TheVMinator
Expert
Expert
Jump to solution

Ok thanks.  Where exactly do I find my AD auth source that was configured in vROps?

Reply
0 Kudos
grhohertz
Enthusiast
Enthusiast
Jump to solution

Administration -> Authentication Sources (in 6.2)  It would be the "Source Display Name"

Capture.PNG

TheVMinator
Expert
Expert
Jump to solution

OK many thanks - one more question - for "domain" is that my active directory domain?  My dns domain?  Do I include the .com / .net in it?  Where exactly could I look in the UI to make sure the "domain" I specify is the one vROps is expecting?

Reply
0 Kudos
dtaliafe
Hot Shot
Hot Shot
Jump to solution

Use the name of your authentication source in vROps shown here:

authsource.jpg

You can also use the "-AuthSource" parameter to specify this:

Connect-OMServer -Server vrops.mydomain.com -User username -Password password -AuthSource "Source Display Name"

Using username@authsource without the "-AuthSource" parameter will also work, but I didn't see any reference of this in the cmdlet's help.

Reply
0 Kudos
SergOO
Enthusiast
Enthusiast
Jump to solution

Connect-OMServer -Server myserverOPMan -User Admin -Password mypassword -Force

Reply
0 Kudos