Clear Zombies in JDE Automatically Using Command Line Utility Tool

CNC folks have been battling with zombies for years now and Oracle still has not come up with an option to remove/clear zombies periodically/automatically from enterprise servers. Zombies are those process which have gone defunct and are no longer useful. But at times the parent process (jdenet_n) does not release the resources used by these processes. Zombies may be created due to database issue, faulty code or process errors. When such zombie processes pile up, they consume your server’s valuable resources, leading to slowness of system. And slowness in production environment, is something that can affect your business to a large extent and may cost you time and money.

There are only two ways to clear these zombies:

  • Clear zombies for affected enterprise server from Server Manager
  • Kill zombie’s parent process – which would involve restarting JD Edwards services on enterprise servers (this is certainly out of the picture for production environment)

To solve this problem, I have created a command line utility “clearzombies”. This tool accepts several parameters as input and clears zombies from an enterprise server by making web calls to Server Manager. You can schedule this tool, as a command or a batch file script, using windows task scheduler.

To avoid the problem of passing password as a plaintext (as this is a cause of security concern for many organizations), I have also created another utility called “encryptSVMpass” to generate an encrypted password which can be passed to “clearzombies” utility. encryptSVMpass usage is as follows:

encryptSVMpass

Following is usage guide for clearzombies utility:

Usage:

clearzombies SVMHost SVMPort SVMUserID SVMPasswordEncrypted
 ESHostName ESInstanceName JDEAgentInstallPath [debugon]

Options:

	SVMHost					Hostname of the server on which server manager is installed
	SVMPort					Port number on which server manager is running, generally it is 8999
	SVMUserID				User ID to login to Server Manager
	SVMPasswordEncrypted	Use encryption tool 'encryptSVMpass' to generate encrypted password
	ESHostName				Hostname of Enterprise Server as registered in Server Manager
	ESInstanceName			Instance name of Enterprise Server as registered in Server Manager
	JDEAgentInstallPath		Full path to directory where agent is installed, can be obtained from Server Manager
	debugon					Optional parameter, will output debug messages while execution

Example Usage 1:

clearzombies JDEDEPSVR 8999 jde_admin 6pNmxcl6jImEn0aD81KYPNi4NyEG5FkKEV2lTbnUAPCC32QcfZvzNm3h4YGFHJFI9cGJIE9t+/KODu6XnIKYXzMOF+BhCSjfRx66uXZ4DURu/7hIu6Z4KHycqB61K/6s JDEENTSVR Ent_Prod /u01/apps/jdedwards/agent

Example Usage 2:

clearzombies JDEDEPSVR.company.com 8999 jde_admin 6pNmxcl6jImEn0aD81KYPNi4NyEG5FkKEV2lTbnUAPCC32QcfZvzNm3h4YGFHJFI9cGJIE9t+/KODu6XnIKYXzMOF+BhCSjfRx66uXZ4DURu/7hIu6Z4KHycqB61K/6s JDEUBESVR.company.com Ent_Prod /u01/apps/jdedwards/e900/jde_home/agent

Parameter details

Description:
clearzombies is a command line utility which takes necessary inputs and performs web calls to login to Server Manager, access process details page for provided enterprise server, determine if there are any zombie processes and if found, it sends a payload request to Server Manager’s ajax handler servlet, which clears the zombie process.

Note:
Ensure that ESHostname, ESInstanceName and JDEInstallPath are exactly as registered in Server Manager. These details can be obtained from Server Manager Dashboard page and you are advised to copy paste it from there instead of typing, to avoid human error.

Following is a screenshot of functioning of clearzombies utility:

clear-zombie-jde-utility

Use below link to download zip archive containing both necessary files. Rename encryptSVMpass.exe.abc to encryptSVMpass.exe after extracting.

DOWNLOAD

If you have multiple enterprise servers, save commands for each server, one server per line, in a batch file (copy the command with full path to a text file and save it with .bat extension) and schedule batch file to run, say for example, every 1 hour. Follow this link to know how to schedule a task in windows task scheduler, second half of the article describes scheduling a program/script.

Following is an example of batch script for 2 servers, it can be modified for any number of servers:

@echo off
REM Set the path in which clearzombies.exe has been placed
SET dirpath="C:\CNC_Tools\ClearZombies"
cd %dirpath%

REM Initialize variables
SET SVMHost="JDEDEPSVR"
SET SVMPort="8999"
SET SVMUserID="jde_admin"
SET SVMPasswordEncrypted="6pNmxcl6jImEn0aD81KYPNi4NyEG5FkKEV2lTbnUAPCC32QcfZvzNm3h4YGFHJFI9cGJIE9t+/KODu6XnIKYXzMOF+BhCSjfRx66uXZ4DURu/7hIu6Z4KHycqB61K/6s"

SET ESHostName="JDEDEVSVR"
SET ESInstanceName="ent_dev"
SET JDEAgentInstallPath="/u01/apps/jdedwards/agent"

clearzombies %SVMHost% %SVMPort% %SVMUserID% %SVMPasswordEncrypted% %ESHostName% %ESInstanceName% %JDEAgentInstallPath%

SET ESHostName="JDEPRDSVR"
SET ESInstanceName="ent_prd"
SET JDEAgentInstallPath="/u01/apps/jdedwards/agent"

clearzombies %SVMHost% %SVMPort% %SVMUserID% %SVMPasswordEncrypted% %ESHostName% %ESInstanceName% %JDEAgentInstallPath%

Save this code in a file with .bat extension and schedule it in task scheduler to automate clearing of zombies in your JD Edwards setup.

I have tested this tool with latest server manager releases and it works fine. Please add comments in case you face any issues or to report bugs with the tool. If you would like to have something customized for your project in a similar manner, please use contact form to reach me and I will get back to you.

Edit: Support for Server Manager 8.98 has been added as well.

13 thoughts on “Clear Zombies in JDE Automatically Using Command Line Utility Tool”

  1. Soumen Aich says:

    Hi Nimish,

    I was trying this on my system and getting an error while executing the command. With debug on it says ..

    Generating session ID cookie by accessing URL: http://ent1depsrv90:8999/manage/home
    Could not access server manager URL, please make sure server manager is up and details provided are correct!

    My SM is up and running. .. any ideas.

    Thanks,
    Soumen

    1. NIMISH says:

      Hi Soumen

      This might be due to version of Server Manager. I have added compatibility for older server manager versions as well now. Please delete the existing file and download new file from the link in the post.

      Let me know if you are still facing issue with the new file.

      BR,
      Nimish

  2. Sunil says:

    Hello,. Can you please provide me the batch script in txt format so that I can create the same by changing ES,hostname,portname, etc as given below.

    Thank you,
    Sunil Tayde

    1. NIMISH says:

      Hi Sunil,

      Batch script example has been added to the post.

      Please check and let me know in case of any issues.

      Best Regards,

      Nimish Prabhu

  3. This is a very interesting utility. Unfortunately, I have been unable to get it to work. What are the prerequisites (SVM version, any windows apps used, etc.)?

    1. NIMISH says:

      Hi Stewart,

      As per our email communications, this has been resolved.

      Thanks for sharing debug info and pointing out the issue. It has been fixed now and download link has been updated with latest version of clear zombies utility.

  4. Art says:

    I would like to change the default password, please advise. Thanks

  5. krishna says:

    Hi Nimish, can you please explain step by step process of automatic clearing zombies. What commands have to execute in command prompt.

  6. Hans van Laar says:

    Hi Nimish,

    I came across you interesting tool. I have downloaded the zip file, however it does not contain the utility to excrypt the password. Can you please provide it.
    Thank you,

    Hans

  7. AnilKumar says:

    Hi Nimish,

    How to get the dump file .dmp for the zombie process ?

  8. Himanshu says:

    Hi Nimish,

    I am trying to utilize your zombie tool on my setup but unfortunately it did not worked. Also i got only one file in download link for clear zombies.

    Currently i am on tools 9.2.2.6 server manager tools release not sure if it is supported.

    Regards,
    Himanshu

  9. Jon Steel says:

    Hi Nimish !

    We’ve been using this wonderful utility for some time in an environment to clear up occasional zombies quickly, and it definitely has helped us a lot – thankyou ! However, we recently started rolling out our print forms with BI Publisher (replacing another 3rd party print tool) – and we’ve been having an increased number of zombie processes with RunUBE Kernels. However, because the RunUBE Kernel has no Process Name appearing in the SMC under Process Detail (its blank) – it seems that the utility isn’t identifying them, and doesn’t clear them. They are clearable manually through the SMC though. We are on Tools Release 8.98.3.3 (will be updating to 9.1.5.10 by EOY) on our JDE 9.0 instance. We don’t necessarily see the same issue with our JDE 9.1 instance (running 9.1.3.3) – so it MIGHT be related to the Tools Release version. Any thoughts ? We have to run this older TR for at least 3-4 months currently, so its going to cause some issues with us. By the way, the processes themselves are all completing successfully and printing fine – its just that they don’t seem to be clearing up at the end of the process….

    1. NIMISH says:

      Dear Jon,

      I might need to have a remote screen sharing session to better understand and debug the issue. If it is possible, please use contact form on this website to drop me a message and we can schedule a call.

      Thanks,
      Nimish

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.