AEM Forms 6.5.18: JBoss Windows Service Fails to Stop Gracefully

This article provides steps to resolve an issue where the JBoss Windows service does not stop as expected in Adobe Experience Manager Forms 6.5.18.

Description description

Environment

Adobe Experience Manager Forms 6.5.18 (JEE, Standalone) on Windows

Issue/Symptoms

The Windows service for JBoss used in the AEM Forms 6.5.18 turnkey installation does not stop when you attempt to stop the service from the Windows Services console. The process remains running and requires manual termination of the  process to fully stop JBoss.

  • Affected component: JBoss Windows service
  • Affected version: AEM Forms 6.5.18 (JEE)
  • Platform: Windows (development environment)
  • No specific error message appears, but the service does not stop as expected.

Cause

The issue is caused by incorrect or malformed parameters in the JBoss Windows service script, which prevent the service from executing a proper shutdown command. Updating the script and registry parameters ensures that the shutdown command executes correctly.

Resolution resolution

  1. Take a full backup or snapshot of the instance and database before making any changes.

  2. Navigate to the a bin directory of the JBoss installation.

  3. Open Service.bat in a text editor and locate the following block:

    code language-none
    else (
      if "%BASE%"=="" set "BASE=%JBOSS_HOME%\standalone"
      if "%CONFIG%"=="" set CONFIG=lc_turnkey.xml
      if "%START_SCRIPT%"=="" set START_SCRIPT=standalone.bat
      set STARTPARAM="/c#set#NOPAUSE=Y#&&#!START_SCRIPT!#-Djboss.server.base.dir=!BASE!#--server-config=!CONFIG!"
      set STOPPARAM="/c !STOP_SCRIPT! --controller=%CONTROLLER% --connect %CREDENTIALS% --command=:shutdown"
    )
    
  4. Replace the STOPPARAM line with:set STOPPARAM="/c#set#NOPAUSE=Y#&&#!STOP_SCRIPT!#--controller=%CONTROLLER%#--connect#%CREDENTIALS%#--command=:shutdown"

  5. Open the Registry Editor and navigate to:

    HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Apache Software Foundation\Procrun

  6. Ensure there are no spaces in the STOP PARAMS value. It should resemble:

    /c set NOPAUSE=Y && jboss-cli.bat --controller=localhost:9990 --connect --command=:shutdown

  7. Confirm that the Java JDK path is included in the PATH system environment variable, and run java -version in Command Prompt to verify the Java installation.

  8. Start the JBoss Windows service, wait until it starts completely, and then stop the Windows service to verify that it shuts down gracefully without requiring manual process termination.

recommendation-more-help
experience-cloud-kcs-help-kbarticles