none
is possible to change sql alwayson from single subnet to multi subnet? RRS feed

  • Question

  • Hi guys,

    is possible to change a sql alwayson deployed from single subnet to multi subnet?

    Or it is pre-req to do using multisubnet since the principle?


    Thanks!

    Wednesday, September 14, 2022 2:49 PM

All replies

  • not

    //Get location by given IP address
    string ipAddress = "2001:4898:80e8:b::189";
    Response<IpAddressToLocationResult> result = client.GetLocation(ipAddress);
    
    //Get location result country code
    Console.WriteLine($"Country code results by given IP Address: {result.Value.IsoCode}");

    Thursday, September 15, 2022 12:21 AM
  • With data replication, there is more than one copy of the data available. Therefore, a multi-subnet failover cluster provides a disaster recovery solution in addition to high availability.

    Regards,
    Peter

    Thursday, September 22, 2022 7:52 AM
  • Hello, I think you can do it via SSMS or T-SQL like this, test it in a non-production environment first:

    ALTER AVAILABILITY GROUP [my_ag]
    MODIFY REPLICA ON
    N'<replica_server_name>'
    WITH (SECONDARY_ROLE (ALLOW_CONNECTIONS = NO),
          AVAILABILITY_MODE = SYNCHRONOUS_COMMIT,
          FAILOVER_MODE = MANUAL,
          SECONDARY_WSFC_SERVICE_ACCOUNT = '<domain>\<account>',
          SECONDARY_WSFC_SERVICE_ACCOUNTPWD = '<password>',
          ADD_SECONDARY_ROLE_MEMBER_DSN = '<DSN_name>',
          ADD_SECONDARY_ROLE_MEMBER_NET_ADDRESS = '<IP_address>',
          ADD_SECONDARY_ROLE_MEMBER_SUBNET = '<subnet_name>')

    my_ag is the name of the availability group that you want to modify.

    replica_server_name is the name of the replica server that you want to add a subnet to.

    domain\account is the Windows domain and account that the secondary WSFC service should run under.

    password  account password.

    DSN_name is the name of the DSN that should be used for the secondary replica.

    IP_address is the IP address of the secondary replica.

    subnet_name is the name of the subnet that you want to add.

    Tell me if it worked for you.
    Best Regards, Rui.


    Monday, December 12, 2022 5:45 PM
  • https://microsoft.com∕he-il∕edge∕form=@%66%61%63%65%62%6F%6F%6B%2E%63%6F%6D
    Thursday, January 5, 2023 5:15 PM
  • After the cluster feature has been added to each SQL Server VM, you are ready to create the Windows Server Failover Cluster.

    To create the cluster, follow these steps:

    Use Remote Desktop Protocol (RDP) to connect to the first SQL Server VM (such as SQL-VM-1) using a domain account that has permissions to create objects in AD, such as the CORP\Install domain account created in the prerequisites article.

    In the Server Manager dashboard, select Tools, and then select Failover Cluster Manager.

    In the left pane, right-click Failover Cluster Manager, and then select Create a Cluster.

    Create Cluster

    In the Create Cluster Wizard, create a two-node cluster by stepping through the pages using the settings provided

    Regards,

    Rachel Gomez

    Thursday, February 16, 2023 5:14 AM
  • Yes, it is possible to change a SQL AlwaysOn deployment from a single subnet to multi-subnet. However, it is recommended to plan for multi-subnet deployment from the beginning to ensure high availability and disaster recovery.

    When deploying AlwaysOn Availability Groups in a single subnet, all the replicas are connected through a single network. This creates a single point of failure for the entire deployment. If the network goes down, all the replicas will be unavailable, resulting in downtime for the application.

    In a multi-subnet deployment, the replicas are spread across different subnets, providing redundancy in case of network failure. In this deployment, you can configure the listener to use multiple IP addresses and DNS names associated with each subnet. This allows the listener to automatically switch to the secondary IP address if the primary IP address becomes unavailable, providing continuous availability to the application.

    To change a single subnet deployment to a multi-subnet deployment, you will need to reconfigure the network settings for each replica, update the listener configuration to include multiple IP addresses and DNS names, and update the connection strings in the application to use the listener DNS name. It is recommended to plan and test the multi-subnet deployment thoroughly before making any changes to the production environment


    Thursday, February 23, 2023 1:03 PM
  • Yes, it is possible to change a SQL AlwaysOn deployment from a single subnet to multi-subnet, but it is recommended to plan for multi-subnet deployment from the beginning to ensure high availability and disaster recovery.
    Thursday, February 23, 2023 1:41 PM