Cmdlet or script to add IPs to Exchange 2016 anonumous relay connector

Sabir Mohamed 41 Reputation points
2021-09-19T08:32:45.843+00:00

Dear Team,

I need to have a cmdlet for setting automation tasks as per the IT user request to add IPs to the anonymous connector of exchange 2016 servers.

I believe this should work but where I need to add exchange server name as I have 3 exchange server under my DAG.

Set-ReceiveConnector -Identity "Anonymous connector" -RemoteIPRanges 192.168.1.14 -Confirm:$false

Exchange Server Management
Exchange Server Management
Exchange Server: A family of Microsoft client/server messaging and collaboration software.Management: The act or process of organizing, handling, directing or controlling something.
7,369 questions
Microsoft Exchange Hybrid Management
Microsoft Exchange Hybrid Management
Microsoft Exchange: Microsoft messaging and collaboration software.Hybrid Management: Organizing, handling, directing or controlling hybrid deployments.
1,901 questions
{count} votes

Accepted answer
  1. Kael Yao-MSFT 37,496 Reputation points Microsoft Vendor
    2021-09-20T04:03:03.263+00:00

    Hi @Sabir Mohamed

    Did you mean you created anonymous connectors for relay on the three exchange servers with the same name? For example, "Anonymous connector".

    If it is the case, the actual names of the connectors would be specified by server names.
    For example, if the server name is E16A, the connector's name would be "E16A\Anonymous connector".
    And the command to add ip addresses to this connector would be:

     Set-ReceiveConnector -Identity "E16A\Anonymous connector" -RemoteIPRanges 192.168.1.14 -Confirm:$false  
    

    If you run the following command, it would only modify the settings of the connector on the local server:

    Set-ReceiveConnector -Identity "Anonymous connector" -RemoteIPRanges 192.168.1.14 -Confirm:$false  
    

    The other two servers' connector settings would remain unchanged.


    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


0 additional answers

Sort by: Most helpful