With ArcGIS Pro, you can save a service definition for a map service to be published to a stand-alone ArcGIS Server site at a later time. A service definition file (.sd) contains information about the map service's properties and capabilities. See Introduction to saving service definitions to learn more about how service definitions can be used in your organization's sharing workflows.
Save a connected service definition for a map service
A connected service definition is configured for a specific server connection. The option to save a service definition is available in the Publish Map Service and Overwrite Map Service panes when you are connected to a stand-alone server running ArcGIS Server. In either pane, click the Publish drop-down arrow and click Save As SD to save a service definition file.
The workflow to save a service definition for a map service is similar to publishing or overwriting a map service and is not discussed in detail here. To learn about saving a service definition for a map service, see Publish a map service and Overwrite a map service.
Save an offline service definition for a map service
An offline service definition is connection neutral; it is not configured for a specific server connection. You can save an offline service definition if you are offline or not connected to the server. This workflow explains how to save an offline service definition for a map service with default settings to be later published to a stand-alone server. To change the default configuration, see Configure a map service. You can also use ArcPy to save an offline service definition. To learn more, see Introduction to arcpy.sharing.
To save a service definition for a map service in a disconnected environment, complete the following steps:
- Right-click the name of the map in the Contents pane, point to Save As Offline Service Definition, and click Map Service on Standalone Server .
The Save As Offline Service Definition pane appears.
- Provide a name for the map service.
- Optionally, complete the Summary and Tags fields.
You can enter a maximum of 128 tags.
- Under Version, select the ArcGIS Server version to which the service definition will be published. Specifying a version ensures the service definition contains content compatible with your server.
To verify the server version, sign in to ArcGIS Server Manager, browse to Site, and click Software Authorization. You can also access the Server Info at the following URL: https://<host>/<instance>/rest/info.
Alternatively, contact your administrator for assistance.
You can create multiple service definition files if you need to publish to servers with different versions.
- Choose a Data option.
- To avoid having a copy of the data placed on the server, register your data to the server using ArcGIS Server Manager and choose the Reference registered data option.
- To maintain a separate copy of the data for web use, choose the Copy all data option.
For more information on data registration, see Register your data with ArcGIS Server using ArcGIS Desktop or ArcGIS Pro.
- Optionally, under Location, for Folder, provide a name of an existing server folder or a new folder.
By default, the service is stored in the root folder of the server.
- Optionally, click the Content tab to view the folder, new service, and sublayers with assigned IDs if available.
If you enabled the Allow assignment of unique numeric IDs for sharing web layers option in the Map Properties dialog box, assigned IDs appear for each sublayer. To change an ID, click the number next to the layer or table. On the Layer Properties or Standalone Table Properties dialog box, on the General tab, type a custom integer ID in the Layer ID or Table ID text box. For more information, see Assign layer IDs.
- Under Finish Staging, click Analyze to review for problems.
Errors and warnings are listed on the Messages tab. Right-click a message to open its help topic or take corrective action in the software. Errors must be resolved before you can save the service definition. Resolving warnings is recommended but not required.
- After you have resolved errors, and optionally resolved warnings, click Save.
The Save As Service Definition File dialog box appears.
- On the dialog box, specify the location and name of the service definition file, and click Save.
- Optionally, click Jobs to monitor the job status.
- Once the service definition has been successfully staged, click the Manage the service definition link at the bottom of the pane to open the location of the service definition file.
Save an offline service definition that overwrites a map service
To create an offline service definition that overwrites an existing map service, complete the following steps:
- At the top of the Save As Offline Service Definition pane, click the Configuration tab and click the Configure Parameters tab below it.
- Under Settings, check the Overwrite existing map service check box.
Checking this box sets the service definition to overwrite a map service. If the service name exists on the server, publishing the service definition will overwrite the existing map service. If the service name doesn't exist, a new map service will be published.
Publishing a service definition staged to overwrite will automatically replace the existing map service if found on the server. To avoid unintentionally overwriting existing map services and their associated data, store these service definitions in a way that makes them distinguishable from other service definitions.
If you are ready to publish your map service to a stand-alone server running ArcGIS Server, see Publish a service definition.