What is use of $JBOSS_HOME/domain/data directory in JBoss EAP 6 ?

Solution Unverified - Updated -

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 6.x

Issue

  • What is use of $JBOSS_HOME/domain/data directory in JBoss EAP 6 ?
  • What happens on deleting this directory?
  • JBoss EAP 6 fails with JBAS014613: Operation ("add") failed as follows:
ERROR [org.jboss.as.controller.management-operation] (Controller
Boot Thread) JBAS014613: Operation ("add") failed - address: ([("deployment" =>
"abc.war")]) - failure description: "JBAS010876: No
deployment content with hash 8d2c5dth1s1sth3ha5hth1s1sth3ha5hth1s1sth3ha5hth1s1sth3ha5hcf8 is
available in the deployment content repository for deployment
'abc.war'. This is a fatal boot error.
  • Is it possible to remove some of the directories contains previous deployments of the same applications?

Resolution

  • When deploying an application from the Admin console or from a CLI command then it creates the content directory in the $JBOSS_HOME/domain/data directory where the application is stored. It also creates a <deployments> tag in configuration files(domain.xml/standalone.xml) like following
<deployment name="WebApp.war" runtime-name="WebApp.war">
  <content sha1="b156cf7a5d426774255c6ae725fcbab4a8da0bbe"/>      
</deployment>
  • If the content directory is removed from the $JBOSS_HOME/domain/data directory, then remove above <deployment> tag from configuration files, otherwise JBoss server start-up fails with following exception.
[Host Controller]   ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS014613: Operation ("add") failed - address: ([("deployment" => "WebApp.war")]) - failure description: "JBAS010876: No deployment content with hash cb16a87d23644fb166000b4b739ef12257b77326 is available in the deployment content repository for deployment 'WebApp.war'. This is a fatal boot error. To correct the problem, either restart with the --admin-only switch set and use the CLI to install the missing content or remove it from the configuration, or remove the deployment from the xml configuraiton file and restart."
  • In domain mode remove the following <deployments> tag from tag from domain.xml file.
<server-group name="main-server-group" profile="full">
   . .
     <deployments>
       <deployment name="WebApp.war" runtime-name="WebApp.war"/>
     </deployments>   
</server-group>
  • In EAP 6.0.1 $JBOSS_HOME/domain/data directory contains previous deployments of the same applications this issue has been reported. Remove manullay from the $JBOSS_HOME/domain/data/content directory if the application is not used in the server.
NOTE:

Here JBOSS_HOME in the above path(i.e. $JBOSS_HOME/domain/data) can be set as an environment variable which will represent the JBoss home directory.
For example : If the jboss-eap-6.x is located in /home/user directory than the JBOSS_HOME environment variable should be set as /home/user/jboss-eap-6.x.

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.

Comments