locked
Cannot create session to IP less DAG (2013 SP1) through powershell RRS feed

  • Question

  • Hi,

    We are using PowerShell to remotely manage mailboxes of users. In case of IP based DAG, an exchange session is created to DAG to manage mailboxes. We are facing issues in case of IP less DAG environment. The session creation to DAG is failing.

    The IP less DAG is configured on Exchange 2013 SP1. The following command to create session through PowerShell fails where "DAG1" is the name of Database Availability Group. Also "ping DAG1" fails. The IP Address of DAG is set to 255.255.255.255.

    New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://DAG1/PowerShell/ -Authentication Kerberos -Credential $UserCredential

    Here is the error:
    New-PSSession : [dag1] Connecting to remote server dag1 failed with the following error message : WinRM cannot
    complete the operation. Verify that the specified computer name is valid, that the computer is accessible over the
    network, and that a firewall exception for the WinRM service is enabled and allows access from this computer. By
    default, the WinRM firewall exception for public profiles limits access to remote computers within the same local
    subnet. For more information, see the about_Remote_Troubleshooting Help topic.
    At line:1 char:12
    + $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri ht ...
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotingTransportException
    + FullyQualifiedErrorId : WinRMOperationTimeout,PSSessionOpenFailed


    When I update DAG and clear all the IP address entries then it works fine i.e. ping to DAG works fine and also the New-PSSession command succeeds. I am not sure if this is still called an IP less DAG as an IP address is getting assigned to DAG1. 

    Also, when I try to set the IP address for DAG to 255.255.255.255 I get the following warning message indicating that DAG is offline. Is this expected?

    warning
    No static address matched networks 'Cluster Network 1'. Specified static addresses: '255.255.255.255'

    Network name 'DAG1' is not online. Please check that the IP address configuration for the database availability group is correct.

    I need help in creating exchange session to an IP less DAG through remote PowerShell. Are there any specific configurations to make it work?


    Thanks.


    • Edited by ishwarande Wednesday, January 18, 2017 1:30 PM Provided more details in the question
    Wednesday, January 18, 2017 1:25 PM

All replies

  • Hi,

    We are using PowerShell to remotely manage mailboxes of users. In case of IP based DAG, an exchange session is created to DAG to manage mailboxes. We are facing issues in case of IP less DAG environment. The session creation to DAG is failing.

    The IP less DAG is configured on Exchange 2013 SP1. The following command to create session through PowerShell fails where "DAG1" is the name of Database Availability Group. Also "ping DAG1" fails. The IP Address of DAG is set to 255.255.255.255.

    New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://DAG1/PowerShell/ -Authentication Kerberos -Credential $UserCredential

    Here is the error:
    New-PSSession : [dag1] Connecting to remote server dag1 failed with the following error message : WinRM cannot
    complete the operation. Verify that the specified computer name is valid, that the computer is accessible over the
    network, and that a firewall exception for the WinRM service is enabled and allows access from this computer. By
    default, the WinRM firewall exception for public profiles limits access to remote computers within the same local
    subnet. For more information, see the about_Remote_Troubleshooting Help topic.
    At line:1 char:12
    + $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri ht ...
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotingTransportException
    + FullyQualifiedErrorId : WinRMOperationTimeout,PSSessionOpenFailed


    When I update DAG and clear all the IP address entries then it works fine i.e. ping to DAG works fine and also the New-PSSession command succeeds. I am not sure if this is still called an IP less DAG as an IP address is getting assigned to DAG1. 

    Also, when I try to set the IP address for DAG to 255.255.255.255 I get the following warning message indicating that DAG is offline. Is this expected?

    warning
    No static address matched networks 'Cluster Network 1'. Specified static addresses: '255.255.255.255'

    Network name 'DAG1' is not online. Please check that the IP address configuration for the database availability group is correct.

    I need help in creating exchange session to an IP less DAG through remote PowerShell. Are there any specific configurations to make it work?


    Thanks.



    Connect to a specific Exchange Server or load balanced namespace of mailbox servers, you don't connect to the DAG IP for anything.

    Blog:    Twitter:   

    Wednesday, January 18, 2017 1:34 PM
  • Connecting to specific exchange server works fine. I am looking for a way to connect with DAG name. This is supported in case of IP based DAG.
    Wednesday, January 18, 2017 2:02 PM
  • Connecting to specific exchange server works fine. I am looking for a way to connect with DAG name. This is supported in case of IP based DAG.
    Yea, but since this isn't an IP-based DAG, you should connect to a specific server or load balanced name space. It may have been possible to connect to DAG directly, but never really something that was recommended now.

    Blog:    Twitter:   


    Wednesday, January 18, 2017 3:04 PM
  • David,

    If I connect to one the exchange server directly, does the failover happen when it is down?

    Monday, January 23, 2017 7:04 AM
  • No, it's recommend to connect to load balanced name space instead of specific server name.

    Best Regards,


    Niko Cheng
    TechNet Community Support


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

    Monday, January 23, 2017 9:52 AM
    Moderator
  • Connecting via the Dag name wasn't so much as supported as it was an unintended consequence of naming the
    Dag's Windows Failover Cluster (which required a netname) to be the name of the Dag.
    Thursday, January 26, 2017 7:42 PM