How To Install JBoss On Ubuntu 12.10 64Bit

What is JBoss?

JBoss is a powerful open source Java application server developed by RedHat. It has full support for the JavaEE 6 Webprofile, which means you have the following out of the box support:

  • Servlet 3.0
  • JSF
  • Java Server Faces
  • EJB
  • JPA
  • CDI
  • Bean Validation

Additionally there is also support for other JavaEE features like JMS, JAX-RS and JAX-WS.

More documentation can be found here.

Step One—Install Java

First you have to check if you have installed java on your VPS.

java -version

When you get the following error you have to install it.

-bash: java: command not found

Install Java.

apt-get update
apt-get install openjdk-7-jdk

Step Two—Install JBoss

The next step is to download the current JBoss version, which is at the moment 7.1.1.


Now unzip it and move it to /usr/local/share/jboss.

tar xfvz jboss-as-7.1.1.Final.tar.gz
mv jboss-as-7.1.1.Final /usr/local/share/jboss

Step Three—Create a New User

Because we don’t want to run it as root you should create a new user which is used to start the JBoss server.

adduser appserver

Also change the ownership of the newly created folder to the new user.

chown -R appserver /usr/local/share/jboss

The next step will be creating a new user for the JBoss management console.

su appserver
cd /usr/local/share/jboss/bin	

Now you should create a new Management User by typing “a” and enter later username and password

What type of user do you wish to add? 
 a) Management User ( 
 b) Application User (
(a): a

Enter the details of the new user to add.
Realm (ManagementRealm) :    
Username : app1
Password : 
Re-enter Password :

It is really important that the Realm has the value “ManagementRealm” because this is the realm for the management console.

Step Four—Start the JBoss Server

After this steps you can start the JBoss server using the following command.

./ -Djboss.bind.address=yourserverip

You have to set the bind address because otherwise JBoss is only accessable from localhost. You can also set as IP address if you have no static IP.

To verify if everything works you can navigate to the management console.


You have to enter username and password of the user you created using

You should see the following site now:

JBoss 1To enter the deployed root web page you have to navigate to the following url.


You should see the following site now:

JBoss 2To stop the server you have to run the following command.

./ --connect --controller=yourserverip:9999 command=:shutdown
echo "Hello World!";

By Adarsh Vengarathodi

Hey there! I'm the founder and the CEO of MistLayer, Inc. In this role, I oversee the company’s overall product direction and development and leads the engineering, product and infrastructure teams. I have more than 12 years of software, systems and product development experience, including hardware and software engineering, product management, quality assurance and support.