After moving your SQL Server instance to a new server, this guide will show you how to update your ArcGIS Server services. Additionally, it will demonstrate how to update file-based services that use data from a file geodatabase, such as map and image services, after the network share has changed.
Scenario
It might be necessary for you to move your SQL Server geodatabase to a different server. The 2022 instance, for instance, might be on a different server when you upgrade from SQL Server 2019 to SQL Server 2022. With a database backup and restore, moving the geodatabase is simple. However, what about updating your ArcGIS Server services? The services will use the SQL instance name if they are referencing information from your enterprise geodatabase. This can be fixed by re-mapping the data sources in your Pro Projects/MXDs, and then re-publishing your services. But what if you have dozens, or hundreds, of services? This can be extremely time consuming. The below video will show how you can update all of your services with a couple of python scripts.
Before executing the scripts, be sure you have made a copy of the \arcgisserver\config-store\services and \arcgisserver\directories\arcgissystem\arcgisinput directories.
Script is running fine and was able to see the new sql server in the datastore . When I try to access the server, it is giving an errror as shown above
@vijaybadugu not sure what you're referring to when you say access the server. Can you send a screenshot?
Error: Error handling service request :0x80004005 - No Layer or Table was initialized. in '"esriCarto.GraphicFeatureServer"'
Code: 500..
I am getting this error now
We have recently migrated the content from on premise environment to cloud( Azure ) ArcGIs Enterprise 11.5 using webgis dr , which includes all sql reference data. I followed your instructions to modify old instance to a new instance using python scripts. After that , I tried to open rest service , it took me almost 3 to 5 min and it throws an error
Error handling service request :0x80004005 - No Layer or Table was initialized. in '"esriCarto.GraphicFeatureServer"'
Code: 500..
I tried to check all files including .msd compressed file , everything got updated with new instance and tried to load mapx file in to arcgis pro , it loads without any issues.
could you please advice on this? Does it work if we move enterprise to different environment?
I actually checked publishing a layer from same new instance , it worked great.
what needs to be changed to work as expected ?
@vijaybadugu did you update the Data Store connections to the new SQL instance after the migration?
If the connections were registered via ArcGIS Server Manager, they will need to be updated there:
If the connections were registered via Pro, they will need to be updated in Portal:
Once the Data Store connections are updated, the services should work without executing these scripts. These scripts will only update the services metadata:
I will forward to you script and more details to understand
I could see all the data after updating data stores. So, Do not have to update any metadata then ?