Hi there,
We have a number of referenced services that point to a shapefile or GDB on our network file storage. The storage hardware is being updated soon and IT has let us know that the filepath will need to change from '\\server1\arcgis' to '\\newserver\gis' and we'll need to point all referenced services to that new location.
Is there a way to reliably automate the filepath update for these referenced services without having to manually republish them? Thanks!
@BrendanSoulé
ArcGIS Pro 3.2 Update Data Source Tool can update the map documents and now can also update ArcGIS Server Services. Update data sources—ArcGIS Pro | Documentation
If you run into any issue using the tool, then please open a ticket with Esri Technical Support to investigate further.
I hope this helps.
If you can manage the cutover very carefully, i.e. allowing yourself time, then theoretically, you could retire server1 and create a DNS entry to alias new server as 'server1'. Things would just continue to work, assuming the sub-folders and permissions remain equal. If it's a phased migration, then you're going to need to follow Marcelo's advice below.
@Scott_Tansley - a DNS Alias is a good alternative, as you mentioned, if the path to the sub-folders remains the same.
Yeah - it's not my favourite option, but it's the one that involved least work. But only works if the data is migrated and ready. The old machine can be turned off (and will not be turned on again) and then the DNS applied.
My preference is to use DNS up front, and have a \\datapath\ UNC alias, that can be swapped from server1 to newserver, but when it's retrospective like this, there are limited options.
Thank you @MarceloMarques and @Scott_Tansley for the information! I'll definitely ask about the DNS option, it would be nice to avoid changing filepaths altogether.
For the arcpy method, does the update have to be done in the APRX used to publish the layer? Or can we change the connection path on the service itself, maybe using the ArcGIS API for Python?
@BrendanSoulé
ArcGIS API for Python API Reference - DataStoreManager
https://developers.arcgis.com/python/api-reference/arcgis.gis.server.html#datastoremanager
This resource provides information about the data holdings of the server, as well as the ability to manage (add new items, update primary data store, remove a data store item, etc) the data store. Data items are used by ArcGIS Pro, ArcGIS Desktop, and other clients to validate data paths referenced by GIS services.
There is a bug with the ArcGIS API for Python "DataStoreManager".
BUG-000131019 for ArcGIS GIS Server (esri.com)
Associated service workspace metadata does not update after updating the registered data store connection string for services with registered data sources.
Last Modified: January 11, 2024
Status: In Product Plan
Workaround: Republish services from MXDs with the updated database connection strings.
NOTES:
I hope this helps.
Thanks so much, we'll take a look at these options and see if they're viable for updating the services. If so, I'll be sure to mark this solved.
Appreciate your help!