GlassFish logo Ubuntu logo
Installing GlassFish 4.0 on Ubuntu 14.04  (last updated 2014-09-05)

This HOWTO explains one way of setting up GlassFish 4.0 under Ubuntu 14.04. Questions or suggestions for improvement can be addressed to shadowm at lyonlabs dot org.

Installing GlassFish
Fronting GlassFish with Apache 2.4
Setting up Database Connection Pools

Installing GlassFish

back to top

Fronting GlassFish with Apache 2.4

Many people use Apache to handle redirects, SSL, &c., while leaving the heavy lifting to GlassFish. It also avoids the issue of running GlassFish on port 80 (which is privileged under Linux), since Apache is set up that way to begin with. Here is one way to do it, using the Apache AJP connector (here are links to the reference guides for the jk.conf and workers.properties files given below).

back to top

Setting up Database Connection Pools

Here are the steps to set up a connection pool for a PostgreSQL database: For those using MySQL, the datasource class name is com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource. The necessary properties are user, password, and URL; the format for URL is:
jdbc:mysql://<hostname>:3306/<databasename>

back to top