none
connect-sposervice connect-msolservice

    Question

  • Connect-MsolService
    Connect-SPOService
    stupid varied behavior for these commands,
    No Clear instructions, what are the minimum requirements (what version of which component) is must for these to work
    Another things which is adding to the confusion in Microsoft Online Services Sign-in Assistant is it required or not

    Connect-MsolService
    What is suppose to happen - should one get a login prompt or not
    When no prompt no connection at all
    When prompt from Microsoft Online Service Sign-in Assistant, it works.
    I am unable to get it working on from a Windows 7 Sp1 based machine
    I have lastest .net and windows management frameworks 4.6.2 and 5.1 respectively..
    Tried capturing a network trace using wireshark no http packets

    COnnect-SPOService
    has never worked... worked once, again there was a login prompt,
    However whenever I try to run it again now it fails with errors and also no prompt is presented
    Took a wireshark trace it show http 405 method not allowed


    An Extremist

    Tuesday, March 07, 2017 1:03 PM

All replies

  • Hi,

    The Connect-MsolService cmdlet initiates a connection to Azure Active Directory. The following software are required on your computer for the connection.

    • The 64-bit version of the Microsoft Online Services Sign-in Assistant.
    • The 64-bit version of the Windows Azure Active Directory Module for Windows PowerShell.

    The Windows Azure Active Directory Module for Windows PowerShell requires that the Microsoft .NET Framework 3.5.x feature is enabled on your computer. Please ensure .NET Framework 3.5 is enabled.

    Information about how to connect to Office 365 using PowerShell:

    https://technet.microsoft.com/en-us/library/dn975125.aspx

    For the Connect-SPOService cmdlet issue, please provide the error message displayed in the console.

    Here is an article about connecting to SharePoint Online using PowerShell:

    http://www.c-sharpcorner.com/UploadFile/ece509/getting-started-with-powershell-for-sharepoint-online/

    Read Connect-SPOService and Connect-MsolService to learn more about cmdlets.

    Best regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Wednesday, March 08, 2017 6:16 AM
  • cmdlet Get-Credential at command pipeline position 1
    Supply values for the following parameters:
    Credential
    PS C:\> connect-sposervice -url "https:/tenant-admin.sharepoint.com" -Credential $cred
    Connect-SPOService : Cannot bind parameter 'Url'. Cannot convert value
    "https:/tenant-admin.sharepoint.com" to type
    "Microsoft.Online.SharePoint.PowerShell.UrlCmdletPipeBind". Error: "Invalid
    URI: The Authority/Host could not be parsed."
    At line:1 char:25
    + ... service -url "https:/tenant-admin.sharepoint.com"-Credent ...
    +                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : InvalidArgument: (:) [Connect-SPOService], Param
       eterBindingException
        + FullyQualifiedErrorId : CannotConvertArgumentNoMessage,Microsoft.Online.
       SharePoint.PowerShell.ConnectSPOService

    AND FOR Connect-MSOLService

    PS C:\> $cred=Get-Credential

    cmdlet Get-Credential at command pipeline position 1
    Supply values for the following parameters:
    Credential
    PS C:\> Connect-MsolService -Credential $cred
    Connect-MsolService : There was no endpoint listening at
    https://provisioningapi.microsoftonline.com/provisioningwebservice.svc that
    could accept the message. This is often caused by an incorrect address or SOAP
    action. See InnerException, if present, for more details.
    At line:1 char:1
    + Connect-MsolService -Credential $cred
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : OperationStopped: (:) [Connect-MsolService], End
       pointNotFoundException
        + FullyQualifiedErrorId : System.ServiceModel.EndpointNotFoundException,Mi
       crosoft.Online.Administration.Automation.ConnectMsolService

    Connect-MsolService : Exception of type
    'Microsoft.Online.Administration.Automation.MicrosoftOnlineException' was
    thrown.
    At line:1 char:1
    + Connect-MsolService -Credential $cred
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : OperationStopped: (:) [Connect-MsolService], Mic
       rosoftOnlineException
        + FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.Micro
       softOnlineException,Microsoft.Online.Administration.Automation.ConnectMsol
      Service

    PS C:\> Connect-MsolService -Credential $cred
    Connect-MsolService : Unable to authenticate your credentials. Make sure that
    your user name is in the format: <username>@<domain>. If this issue persists,
    contact Support.
    At line:1 char:1
    + Connect-MsolService -Credential $cred
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : OperationStopped: (:) [Connect-MsolService], Mic
       rosoftOnlineException
        + FullyQualifiedErrorId : 0x80048862,Microsoft.Online.Administration.Autom
       ation.ConnectMsolService

    PS C:\>

    Monday, March 20, 2017 5:52 AM