Trying to get a GP service to run in 10.8 that was running in 10.6... spawning new thread from this in order to chase this in a different direction and for better visibility.
Originally I had only this to go by:
"Instance of Service Crashed.... Containing Process has Crashed"
Now I am also seeing the following in the Windows event log:
Faulting application name: ArcSOC.exe, version: 12.6.0.24234, time stamp: 0x5ee81bca
Faulting module name: MappingCore.dll, version: 12.6.0.24241, time stamp: 0x5f8883dd
I noticed that my original 10.6 GP service was using arcpy.mp which is Pro/3.x. The 10.8 service, however, would run 2.7 although published from Pro. Did 10.6 do more behind the scenes here when publishing? I don't remember changing any ArcGIS Server settings to make this run, yet sys.path had all the correct environmental info in it. That was missing in 10.8.
So I used the steps here to make this run in 3.x conda environment. But the service still crashes... it starts but never finishes.
What could cause an error like this? Is it related to the arcpy.mp/arcpy.mapping compatibility?
Solved! Go to Solution.
So I spent the better part of three weeks trying to dissect this issue with all kinds of help from and reporting back to ESRI. Nothing worked.
The code works in 10.6.1 and fails in 10.8.1.
Finally, I threw n the towel and upgraded to 10.9 on my GP Server only. I call the GP service on that machine after the upgrade and without any additional configurations, environmental changes or code tweaks it works out of the box. To me that means there is a bug in 10.8.1.
Will upgrade to 10.9 and not look back. I used to consider waiting for the Dot-1 a safe practice but these days it feels like that as much stuff breaks in service packs and patches as gets fixed. So why wait!?
@TanuHoque - pinging you directly because you helped the other day by directing my attention to the patch for custom printing in ArcGIS Server 10.8.1. That fixed my problem with custom print services created using Pro's Server Tools for Printing >> Export Web Map/Get Layout Templates.
Now, I'm running into issues (see post above) with migrating a more complex custom GP/printing service that uses arcpy.mp, specifically
arcpy.mp.ConvertWebMapToArcGISProject( ... )
Do you know of any issues in 10.8.1 or needed changes to get what was running in 10.6.1 to work here? I haven't found any changes to arcpy.
It all sounds very similar to what's described in the patch for BUG-000133729:
This patch resolves an issue affecting geoprocessing services and print services in ArcGIS Server 10.8.1 that prevents working with or exporting layout templates or reports that contain text elements.
I'm using a pro custom layout that's used by arcpy,mp along with the JSON from JSAPI to create an in-memory APRX that is then converted to PDF. Works like a charm in my production 10.6.1 environment. In 10.8.1 I'm seeing those DLL errors. Was the patch also to address this kind of thing? I'm trying this on the same ArcGIS Server box that was patched.
@TanuHoque - Ok, I have stepped through my code line by line. Looks like things bomb when we get to:
layout.exportToPDF(....)
This worked fine in 10.6.1 -- Has anyone run into similar issues or found a solution? Is this another bug or related or some completely separate issue? There was a question asked about layout.exportTo..() in this thread but I don't see an answer other than the patch that didn't fix this for me.
I saw your post yesterday and talked to few developers. This one appears different than what we fixed in the patch. Some kind of dll version conflicts could be a reason. I'm glad you narrowed it down to ExportToPDF() call.
Would you mind try on a fresh 10.8 (or 10.8.1) install?
if that does not fix it, then I'd strongly recommend you to reach out to Esri support and have an analyst take a close look.
I'm afraid I couldn't be much of help this time.
Thanks for the feedback. Also started working with our TAM on this. Before I do a clean install of the server, I'll try upgrading my ArcGIS Pro to 2.7.x. I see the release notes for 2.7.0 and 2.7.1 are shock full with fixes related to PDF and layout printing. So maybe I get lucky. Stay tuned.
So I spent the better part of three weeks trying to dissect this issue with all kinds of help from and reporting back to ESRI. Nothing worked.
The code works in 10.6.1 and fails in 10.8.1.
Finally, I threw n the towel and upgraded to 10.9 on my GP Server only. I call the GP service on that machine after the upgrade and without any additional configurations, environmental changes or code tweaks it works out of the box. To me that means there is a bug in 10.8.1.
Will upgrade to 10.9 and not look back. I used to consider waiting for the Dot-1 a safe practice but these days it feels like that as much stuff breaks in service packs and patches as gets fixed. So why wait!?