The database JDBC drivers for Oracle or MySQL must be either set in the GlassFish JVM classpath (preferred) or placed in the /glassfish/lib directory before you create the connection pools. This is not necessary for the Derby (JavaDB) database. For example, if you are using Oracle and JDK 6, you would set your GlassFish JVM classpath to the ojdbc6.jar file.
Open the GlassFish Admin Console. To access the Admin Console, do the following:
To access the GlassFish JVM classpath settings, do the following:
In the Classpath Suffix field, type the full path for your database JDBC driver on your local directory.
For example, C:\GlassFishESB\drivers\oracle11gDriver\ojdbc6.jar.
Click Save, and then restart GlassFish.