You must set the JBOSS_CLASSPATH variable for the JBoss Application Server 4.x/5.x configuration and locale directories.
To set the JBOSS_CLASSPATH variable, modify the JBoss startup script, depending on your platform:
Solaris and Linux systems: JBOSS_HOME/bin/run.sh
Windows: JBOSS_HOME\bin\run.bat
In the JBOSS_HOME/bin/run.sh script, find the following lines:
if [ "x$JBOSS_CLASSPATH" = "x" ]; then JBOSS_CLASSPATH="$JBOSS_BOOT_CLASSPATH:$JAVAC_JAR" else JBOSS_CLASSPATH="$JBOSS_CLASSPATH:$JBOSS_BOOT_CLASSPATH:$JAVAC_JAR" fi
After the lines you found in Step 1, add the following new lines:
CONFIG=$2
if [ "x$1"="x" ] && [ "x$CONFIG" = "x" ]; then CONFIG=default; fi
if [ -r "setAgentClasspath$CONFIG.sh" ]; then
. /opt/jboss-4.2.3.GA/bin/setAgentClasspath$CONFIG.sh
fi
Note: The previous command is for JBoss Application Server 4.2.3.GA. If you are using a different version, specify the appropriate JBoss Application Server directory.
Save the change.
In the JBOSS_HOME\bin\run.bat script, find the following lines:
if "%JBOSS_CLASSPATH%" == "" (
set JBOSS_CLASSPATH=%JAVAC_JAR%;%RUNJAR%
) ELSE (
set JBOSS_CLASSPATH=%JBOSS_CLASSPATH%;%JAVAC_JAR%;%RUNJAR%
)
After the lines you found in Step 1, add the following new lines:
set CONFIG=%2%
if "x%CONFIG%" == "x" (
set CONFIG=default
)
if exist setAgentClasspath%CONFIG%.bat (
call c:\jboss-4.2.3.GA\bin\setAgentClasspath%CONFIG%.bat
)
Note: The previous command is for JBoss Application Server 4.2.3.GA. If you are using a different version, specify the appropriate JBoss Application Server directory.
Save the change.