what is the meaning of the parameter -mailboxcredential?

5,541

I don't know why you think your first command was succesful. It clearly states that the result was a failure:

enter image description here

If you run:

Test-WebServicesConnectivity -ClientAccessServer EXhub1 -MailboxCredential (Get-Credential blablabla)|Format-List *

You'll get more information about exactly what's going on.

With the second request, as explained by Mathias in a comment below, it's trying to create an account called extest_91ef41d34eef4 to test the mailbox, which you cannot do unless you have the rights to create user accounts.

Share:
5,541

Related videos on Youtube

Eltac Shikhsaidov
Author by

Eltac Shikhsaidov

Updated on September 18, 2022

Comments

  • Eltac Shikhsaidov
    Eltac Shikhsaidov over 1 year

    I am writing regarding the Exchange powershell commands.

    When I want to use following cmdlets, I have to insert parameter -mailboxcredential

    • Test-OwaConnectivity
    • Test-OutlookWebServices
    • Test-ImapConnectivity
    • Test-PopConnectivity

    In the Microsoft official site is written:

    The MailboxCredential parameter specifies the mailbox credential for a single URL test.

    I am not sure why this parameter is needed. I inserted incorrect credentials, however the command was finished successfully. Could you tell me reason why this parameter is needed?

    Example (Wrong/incorrect credential)

    [PS] C:\>Test-WebServicesConnectivity -ClientAccessServer EXhub1 -MailboxCredential (Get-Credential blablabla)
    
    CasServer  LocalSite     Scenario        Result  Latency(MS) Error
    ---------  ---------     --------        ------  ----------- -----
    EXhub1     Default-Fi... GetFolder       Failure             [System.Net.WebExcept...
    

    Without parameter:

    [PS] C:\>Test-WebServicesConnectivity -ClientAccessServer EXhub1
    WARNING: Test user 'extest_91ef41d34eef4' isn't accessible, so this cmdlet won't be able to test Client Access server
    connectivity.
    Could not find or sign in with user ********\extest_91ef41d34eef4. If this task is being run without credentials,
    sign in as a Domain Administrator, and then run Scripts\new-TestCasConnectivityUser.ps1 to verify that the user exists
    on Mailbox server EXHUB1.******
    + CategoryInfo          : ObjectNotFound: (:) [Test-WebServicesConnectivity], CasHealthCouldN...edInfoException
    + FullyQualifiedErrorId : FB9A14B6,Microsoft.Exchange.Monitoring.TestWebServicesConnectivity
    WARNING: No Client Access servers were tested.
    
  • Mathias R. Jessen
    Mathias R. Jessen about 12 years
    He's not logged in as extest_91ef41d34eef4, that's a system-created user mailbox for the Test-* cmdlets. In order for it to work he just needs to log in as a Domain Admin
  • MrGigu
    MrGigu about 12 years
    Right, and it needs domain admin rights to create that user. I was mistaking it with that testexchangeconnectivity site.
  • Eltac Shikhsaidov
    Eltac Shikhsaidov about 12 years
    Yes, you are right...Thank you very much. When I inserted correct credential, I can see good result with all information. Thanks
  • Eltac Shikhsaidov
    Eltac Shikhsaidov about 12 years
    One more thing... (-mailboxcredential) this parameter is used only for authentication, or is there some side effect ? Thanks in advance