PROBLEM

Python script fails to run when using port 6443

Last Published: September 17, 2021

Description

Attempts to run a Python script to perform ArcGIS Server processes (for instance the process described in Example: Write properties of all services to a CSV file) fail after changing port 6080 to port 6443 in the script. The following error message may be returned as well:

Error:   
Error while fetching tokens from admin URL. Please check the URL and try again.

Cause

The ArcGIS Server protocol is set to 'HTTP Only'. ArcGIS Server uses certain ports to communicate with machines, for example, HTTP port 6080 and HTTPS port 6443. Refer to ArcGIS Enterprise: Ports used by ArcGIS Server for more information.

Solution or Workaround

Change the ArcGIS Server REST endpoint protocol to 'HTTP and HTTPS'

  1. Navigate to the ArcGIS Server Administrator Directory login page, and log in using a primary site administrator account, for example:
http://machine.domain.com:6080/arcgis/admin
  1. Click security > config > update.
The ArcGIS Server Administrator Directory Update page to change the security protocol.
  1. Change the protocol setting from HTTP Only to HTTP and HTTPS.
  2. Click Update, and wait until the page reloads.
The Security Configuration section to change the security protocol from to HTTP and HTTPS.

Article ID: 000026418

Software:
  • ArcGIS Server

Receive notifications and find solutions for new or common issues

Get summarized answers and video solutions from our new AI chatbot.

Download the Esri Support App

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options