Dieser Inhalt ist in der von Ihnen ausgewählten Sprache nicht verfügbar.

1.4. Setting up Java


Sun and OpenJDK Java are supported.

Note

The server requires the JDK, while the agent only requires the JRE.

1.4.1. Setting up the JDK for the JBoss ON Server

After downloading and installing the latest Java, configure the system to use that version of Java. For example, to configure the JDK for the server on Red Hat Enterprise Linux:
  1. Set the JAVA_HOME environment variable to the installation directory.
    1. Open the .bashrc for the system user that will run JBoss ON. For example:
      vim /home/jon/.bashrc
      Copy to Clipboard Toggle word wrap
    2. Add a line to set the JAVA_HOME environment variable to the specific JDK directory. For example:
      export JAVA_HOME=/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0/
      Copy to Clipboard Toggle word wrap
  2. Set the system to use the correct version of the JDK using the system alternatives command. The selected version has the *+ symbols by it.
    /usr/sbin/alternatives --config javac
    
    There are 2 programs which provide 'javac'.
    
      Selection    Command
    -----------------------------------------------
       1           /usr/lib/jvm/java-1.6.0-bea/bin/javac
    *+ 2           /usr/lib/jvm/java-1.6.0-openjdk/bin/javac
    
    Enter to keep the current selection[+], or type selection number:
    Copy to Clipboard Toggle word wrap

1.4.2. Setting up the JRE for the JBoss ON Agent

  1. Set the JAVA_HOME environment variable to the installation directory.
    1. Open the .bashrc for the system user that will run JBoss ON. For example:
      vim /home/jon/.bashrc
      Copy to Clipboard Toggle word wrap
    2. Add a line to set the JAVA_HOME environment variable to the specific JRE directory. For example:
      export JAVA_HOME=/usr/lib/jvm/jre-1.6.0-openjdk/bin/java/
      Copy to Clipboard Toggle word wrap
  2. Set the system to use the correct version of the JRE using the system alternatives command. The selected version has the *+ symbols by it.
    /usr/sbin/alternatives --config java 
    
    There are 5 programs which provide 'java'.
    
      Selection    Command
    -----------------------------------------------
       1           /usr/lib/jvm/jre-1.5.0-sun/bin/java
       2           /usr/lib/jvm/jre-1.4.2-gcj/bin/java
       3           /usr/lib/jvm/jre-1.6.0-sun/bin/java
    *+ 4           /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
       5           /usr/lib/jvm/jre-1.6.0-bea/bin/java
    
    Enter to keep the current selection[+], or type selection number:
    Copy to Clipboard Toggle word wrap
Nach oben
Red Hat logoGithubredditYoutubeTwitter

Lernen

Testen, kaufen und verkaufen

Communitys

Über Red Hat Dokumentation

Wir helfen Red Hat Benutzern, mit unseren Produkten und Diensten innovativ zu sein und ihre Ziele zu erreichen – mit Inhalten, denen sie vertrauen können. Entdecken Sie unsere neuesten Updates.

Mehr Inklusion in Open Source

Red Hat hat sich verpflichtet, problematische Sprache in unserem Code, unserer Dokumentation und unseren Web-Eigenschaften zu ersetzen. Weitere Einzelheiten finden Sie in Red Hat Blog.

Über Red Hat

Wir liefern gehärtete Lösungen, die es Unternehmen leichter machen, plattform- und umgebungsübergreifend zu arbeiten, vom zentralen Rechenzentrum bis zum Netzwerkrand.

Theme

© 2025 Red Hat