I am trying to perform some analysis on some ArcGIS training data consisting of about 10 points. If I perform any analysis at all, it runs for about 30 seconds and I get a blank error popup. I have enabled verbose logging and after looking at the log files, I see it created a hosted service, but then it immediately deletes it for whatever reason, here is the log:
To me, it looks like the error happens because Portal is deleting the hosted service, question is why? This happens on all analysis tools. Portal running is 10.7.1
deleteAgsService start: Hot_Spots_Lincoln_Police_Stations
Deleting service: https://gisvm.myportal.com:6443/arcgis/rest/services/Hosted/Hot_Spots_Lincoln_Police_Stations/FeatureServer.
Deleting item 'https://gisvm.myportal.com:6443/arcgis/rest/services/Hosted/Hot_Spots_Lincoln_Police_Stations/FeatureServer' (id:8ea1888dbbd84687821acc84ca07caf7).
canDeleteHostedServiceItem: user deleting has the correct privileges
canDeleteHostedServiceItem: user deleting is not anonymous
canDeleteHostedServiceItem: hosted service has no dependent services (ogc,views,etc.)
canDeleteHostedServiceItem: starting for hosted service 8ea1888dbbd84687821acc84ca07caf7
canDeleteItemInternal: item is hosted service
canDeleteItemInternal: item has no items down composite-delete relationships that are protected
canDeleteItemInternal: item is not protected
canDeleteItemInternal: starting for 8ea1888dbbd84687821acc84ca07caf7
Item '8ea1888dbbd84687821acc84ca07caf7' updated.
Item 'https://gisvm.myportal.com:6443/arcgis/rest/services/Hosted/Hot_Spots_Lincoln_Police_Stations/FeatureServer' (id:8ea1888dbbd84687821acc84ca07caf7) added to folder 'email@example.com/Home'.
Added item 'Hot_Spots_Lincoln_Police_Stations' of type 'Feature Service' to the portal.
What does the client side traffic look like? Run the analysis tools again with either the dev tools or Fiddler running so you can watch the traffic. Perhaps the tool is failing, Portal detects that, and then cleans up everything that was created.
I will try this, but I have tested the operations in the GeometryServer on my ArcGIS Enterprise instance that I have set Portal to reference, and they worked fine.
For example, I tried Buffer analysis and it didn't work so I tested the Buffer operation on Enterprise and it worked. I assume Portal uses the tools in ArcGIS Enterprise for all Analysis?
I did a network trace and I see a call to this URL with 200 status code:
The Portal is on-prem, but I grabbed this layer from AGOL and that is why it's trying to reference services2.arcgis.com in the call.
I tried this again with a layer that is hosted in my organization, and I saw a call to the same URL above (but referencing my internal portal instead of services2) and the tool completed successfully.
I went back to Portal and added services2.arcgis.com to the CORS section and tried the tool again, but it didn't work. Is there some other setting I should look at? Or maybe you can't run spatial tools against AGOL content if your on-prem Portal isn't visible to the web since it's sending a reference to my on-prem link in the call to services2?
Can your hosting server, (ex. gisvm.company.com), make outbound requests to ArcGIS Online? If not, then that's likely why the analysis tool is failing. The Server machine will make an outbound request to any service that you're running the analysis tools against. If the Server can't make outbound requests due to a firewall, then you'll see problems. If you were to add the layer to a map and print it using the servers print task, do you see the layer show up? If not, that's another indication that the Server can't reach those URLs.