How to use SQL server multi-subnet failover as Orchestrator database?
UiPath supports SQL Server multi-subnet failure and in order to enable it, parameter "MultiSubnetFailover=True" should be added to the connection string.
Below are the steps to modify the connection string based on Orchestrator Version.
For Orchestrator version 2020.4 & earlier :
The Orchestrator should be pointed to the SQL AOAG Listener. Updating Web.config file
- Open Web.config file using notepad or notepad++ from the Orchestrator installation director. Default location will be "C:\Program Files (x86)\UiPath\Orchestrator\Web.config"
- Add "MultiSubnetFailover=True" parameter under the connection string as shown below
-
<connectionStrings> <add name="Default" providerName="System.Data.SqlClient" connectionString="Server=sql;Database=UiPath;User ID=uipath;Password=password;MultiSubnetFailover=True;" /> </connectionStrings> </pre>
-
- Save the changes and perform an 'IISRESET' from the command prompt.
For Orchestrator version 2020.10 & higher:
The Orchestrator should be pointed to the SQL AOAG Listener. Updating Orchestrator.dll.config file
- Open Orchestrator.dll.config file using notepad or notepad++ from the Orchestrator installation director. Default location will be "C:\Program Files (x86)\UiPath\Orchestrator\UiPath.Orchestrator.dll.config"
- Add "MultiSubnetFailover=True" parameter under the connection string as shown below
-
<connectionStrings> <add name="Default" providerName="System.Data.SqlClient" connectionString="Server=sql;Database=UiPath;User ID=uipath;Password=password;MultiSubnetFailover=True;" /> </connectionStrings>
-
Updating appsettings.Production.json file for Identity
- Open appsettings.Production.json file using notepad or notepad++ from the Orchestrator installation director. Default location will be "C:\Program Files (x86)\UiPath\Orchestrator\Identity\appsettings.Production.json"
- Add "MultiSubnetFailover=True" parameter under the connection string as shown below
-
<connectionStrings> <add name="Default" providerName="System.Data.SqlClient" connectionString="Server=sql;Database=UiPath;User ID=uipath;Password=password;MultiSubnetFailover=True;" /> </connectionStrings>
-
- Open appsettings.Production.json file using notepad or notepad++ from the Orchestrator installation director. Default location will be "C:\Program Files (x86)\UiPath\Orchestrator\Webhooks\appsettings.Production.json"
- Add "MultiSubnetFailover=True" parameter under the connection string as shown below
-
<connectionStrings> <add name="Default" providerName="System.Data.SqlClient" connectionString="Server=sql;Database=UiPath;User ID=uipath;Password=password;MultiSubnetFailover=True;" /> </connectionStrings>
-
- Save the changes and perform an 'IISRESET' from the command prompt.