We keep having orphaned ArcSOC.exe processes piling up on our server. They are all services from the Printing Utility service. We use the ArcGIS Server printing tool (not a custom one) and is set to recycle every 24 hours, but it does not appear to work because we find weeks old ArcSOC.exe processes still running. Pooling is set to 0 (minimum instances) and 2 (max instances). Only way to get rid of them is to kill them manually or reboot the server (which we do monthly). I just ended 49 orphaned ArcSOC processes and the memory on the server went from 90% to 65%. It is obviously not sustainable to keep monitoring this and addressing this manually. This has been going on for weeks but only finding the time to inquire about this now. Can someone please let me know how to fix this?
How are you identifying them as the Publishing Tools service? Did you scrub out the command line column for security reasons? The command line column will have a -Dservice parameter that associates the SOC process with the service name:
20190927000011.528837-420 ArcSOC.exe 16376 "C:\Program Files\ArcGIS\Server\bin\ArcSOC.exe" -XX:-CreateMinidumpOnCrash -Xmx64M -XX:+UseParallelGC -Dservice=System.PublishingTools.GPServerSync....
In your screenshot, I don't see the command line information.
I am not sure why but the commandline in Command Prompt does not get populated. However, when I look at processes in Task Manager using PID to cross-reference, I can see that all hung up processes are tied to the Printing Tools service.
You should also be able to display the Command line column in Task Manager as well as the PID. I believe PID is a column that is visible by default, but Command line is not. Here is a screenshot of Command line in the Details pane of Task Manager. Right click anywhere on the column names and click on Select columns to change the display of columns available for you to evaluate:
What version of ArcGIS Server are you using?
Where exactly do you use this printing service (e.g. AGOL web apps, custom apps, both, other)?
Have you tried creating your own vanilla printing service and see if that helps with the orphan processes?
We are currently on ArcGIS Server 10.6.1. We are planning an upgrade to 10.7.1 in late October.
This printing service is used in we apps hosted in our Production Portal. We observed the same behavior in our Staging/Test Portal. We have had issues in the past with our custom printing service so we reverted back to the default Server printing utility tools. What I am puzzled with is the fact that the printing services don't get "recycled", that they keep piling up, which quickly take a toll on the server. Only way to get rid of them is to kill them manually or reboot the server.
Do you have the ability to test this print service outside of your portal to see if it's the portal that is causing the issue? I ask because I don't have these orphan print services, but my org has not yet set up portal.