[GIS] Error trying to publish Hosted layer to ArcGIS Enterprise from ArcMap

arcgis-enterprisearcmapshared-hosting

I get an error message when I try to publish a hosted layer to portal using ArcMap. Portal and server are federated, I have specified a hosting server and I am an administrator. I have signed in and out of portal and even deleted and re-instated the portal connection in Administrator but I still can't publish. There are no logs on server or error code provided – the error is:

The hosted server behind the portal could not be accessed. Please
check with your portal administrator or use another server for
publishing

I recently updated the admin URL in ArcGIS server /sharing/rest and I can publish service definition files from the server – I just can't do it from ArcMap. I found a local cache in AppData\Local\ESRI\Local Caches\MapCacheV1 which has the old server name so this could be the problem. Can I just delete this cache file or is there another way to refresh it?

enter image description here

The server and portal logs do not reveal anything related to the attempt to publish (on the verbose setting).

Best Answer

Edit: By using the tool "Manage Portal Connections" you can define a connection to your own ArcGIS Portal. Maybe try to redefine the connection to it from there? Thanks to @wunderkind for the link: ArcMap Documentation.

My experience with ArcMap taught me that you are able to publish Feature Services through it that are not "hosted". It accesses your ArcGIS Online account instead of your ArcGIS Enterprise deployment. All of my hosted feature layers were published through ArcGIS Pro to my deployment (on AWS). If it must be declared "hosted" than maybe you can do it from ArcGIS Pro? Otherwise, try to publish to your ArcGIS Server instead of "My Hosted Services"(My Hosted Services is on ArcGIS Online instead of your deployment). Even if not Hosted, it will still appear in your content folder and you'll be able to access it from the Portal, just like a hosted service.

Related Question