Appyling 8.0.2+ patch to the older JBoss EAP versions (8.0.0, 8.0.1, and 8.0.2) fails on Windows with FileSystemException

Solution Verified - Updated

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 8.0.2 (Update 2)
  • Appyling 8.0.2+ patch to the older JBoss EAP versions (8.0.0, 8.0.1, and 8.0.2)

Issue

When I execute the shutdown --perform-installation on JBoss-CLI to apply JBoss EAP 8.0 Update 2 running on Windows machine, I get the following errors in the console log of the running server:

ERROR: java.nio.file.FileSystemException: c:\jboss-eap-8.0\jboss-modules.jar: The process cannot access the file because it is being used by another process
ERROR: The operation was unsuccessful. The candidate server was not installed correctly.

Resolution

  • This is a bug reported as This content is not included.JBEAP-27261 and this will be fixed in installation manager included in JBoss EAP 8.0.3. So, this problem does not happen after updating to JBoss EAP 8.0.3+.

  • Until the bug is fixed, you can workaround this issue by using the installation-manger, which can be installed in the separated directory from JBoss EAP instalation directory. Here are steps:

  1. Download installation-manager from This content is not included.customer portal and extract it.

  2. Stop running EAP 8 server.

  3. Launch Installation Manager with --dir option to specify the location of JBoss EAP 8 install directory which you want to update

    1. Check for available updates:

      $ ./bin/jboss-eap-installation-manager.sh update list --dir /path/to/your/jboss-eap-8
      
    2. Apply update to JBoss EAP:

      $ ./jboss-eap-installation-manager.sh update perform --dir /path/to/your/jboss-eap-8
      

      Unlike JBoss-CLI, you do not need to execute shutdown --perform-installation after this command because the server is already stopped before applying update.

Note: Installation Manager also exists inside the JBoss EAP installation directory, which can be launched from $JBOSS_HOME/bin/jboss-eap-installation-manager.sh, but using it does not workaround this issue. Because it is launched in a modular environment using the same server $JBOSS_HOME/jboss-modules.jar, so the same file lock issue happens. Hence, you need to setup the Installation Manager in the different directory from the JBoss EAP installation directory.

Root Cause

  • JBoss EAP 8.0.2 (Update 2) patch includes a new version of jboss-modules.jar, but copying $JBOSS_HOME/jboss-modules.jar fails due to the file lock held by the running server on Windows.
Components
Category

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.