HomeDocumentation > Administration > Administrative tasks > Configuring services > Configuring database pools > Removing database pools

There are two alternatives for removing database pools, you can use the command line Deployer tool or the Installed J2EE Connectors portlet available from the Geronimo Administration Console.

If you choose to use the graphical option click on J2EE Connectors from the Administration Console to access the Installed J2EE Connectors portlet.

This portlet list all the available connectors and allows you to stop, start and uninstall any of those J2EE connectors. Just click Uninstall next to the connector you want to remove.

You can also remove the database pools using the Deployer tool. Among other things, this tool allows you to list the available modules, connection pools are listed by moduleID. In the console, the moduleID is listed in the Component Name column.

To list all the available modules type the following command from the <geronimo_home>\bin directory:

deploy --user system --password manager list-modules

You should see a list similar to the following example.

D:\geronimo-jetty-j2ee-1.2\bin>deploy --user system --password manager list-modules
Using GERONIMO_BASE:   D:\geronimo-jetty-j2ee-1.2
Using GERONIMO_HOME:   D:\geronimo-jetty-j2ee-1.2
Using GERONIMO_TMPDIR: D:\geronimo-jetty-j2ee-1.2\var\temp
Using JRE_HOME:        C:\Java\jdk1.5.0_06\\jre
Found 47 modules
  + console.dbpool/Derby_Test/1.0/rar
  + org.apache.geronimo.configs/activemq/1.2/car
  + org.apache.geronimo.configs/activemq-broker/1.2/car
  + org.apache.geronimo.configs/axis/1.2/car
  + org.apache.geronimo.configs/axis-deployer/1.2/car
  + org.apache.geronimo.configs/client-deployer/1.2/car
  + org.apache.geronimo.configs/clustering/1.2/car
  + org.apache.geronimo.configs/connector-deployer/1.2/car
  + org.apache.geronimo.configs/directory/1.2/car
  + org.apache.geronimo.configs/dojo-jetty/1.2/car @ http://hcunico:8080/dojo
  + org.apache.geronimo.configs/geronimo-gbean-deployer/1.2/car
  + org.apache.geronimo.configs/hot-deployer/1.2/car
  + org.apache.geronimo.configs/j2ee-deployer/1.2/car
  + org.apache.geronimo.configs/j2ee-security/1.2/car
  + org.apache.geronimo.configs/j2ee-server/1.2/car
  + org.apache.geronimo.configs/j2ee-system/1.2/car
  + org.apache.geronimo.configs/jetty/1.2/car
  + org.apache.geronimo.configs/jetty-deployer/1.2/car
  + org.apache.geronimo.configs/ldap-realm/1.2/car
  + org.apache.geronimo.configs/openejb/1.2/car
  + org.apache.geronimo.configs/openejb-deployer/1.2/car
  + org.apache.geronimo.configs/persistence-jpa10-deployer/1.2/car
  + org.apache.geronimo.configs/remote-deploy-jetty/1.2/car @ http://hcunico:8080/remote-deploy
  + org.apache.geronimo.configs/rmi-naming/1.2/car
  + org.apache.geronimo.configs/sharedlib/1.2/car
  + org.apache.geronimo.configs/system-database/1.2/car
  + org.apache.geronimo.configs/transaction/1.2/car
  + org.apache.geronimo.configs/webconsole-jetty/1.2/car
      `-> standard.war @ http://hcunico:8080/console-standard
      `-> framework.war @ http://hcunico:8080/console
  + org.apache.geronimo.configs/welcome-jetty/1.2/car @ http://hcunico:8080/
  + samples/ldap-realm-1/1.2/car
    org.apache.geronimo.configs/ca-helper-jetty/1.2/car
    org.apache.geronimo.configs/client/1.2/car
    org.apache.geronimo.configs/client-corba-yoko/1.2/car
    org.apache.geronimo.configs/client-security/1.2/car
    org.apache.geronimo.configs/client-system/1.2/car
    org.apache.geronimo.configs/client-transaction/1.2/car
    org.apache.geronimo.configs/j2ee-corba-yoko/1.2/car
    org.apache.geronimo.configs/javamail/1.2/car
    org.apache.geronimo.configs/jetty-clustering-builder-wadi/1.2/car
    org.apache.geronimo.configs/jetty-clustering-wadi/1.2/car
    org.apache.geronimo.configs/online-deployer/1.2/car
    org.apache.geronimo.configs/openejb-corba-deployer/1.2/car
    org.apache.geronimo.configs/openjpa/1.2/car
    org.apache.geronimo.configs/shutdown/1.2/car
    org.apache.geronimo.configs/transformer-agent/1.2/car
    org.apache.geronimo.configs/uddi-jetty/1.2/car
    org.apache.geronimo.configs/wadi-clustering/1.2/car

For this example we have the database pool that was created in the Create new database pools section so we will be looking for the Derby_Test database pool. From the modules displayed in the previous example, we can see that console.dbpool/Derby_Test/1.0/rar is at the top of the list, this is the moduleID we will need to remove this data source.

With the database pool moduleID identified ( in this example console.dbpool/Derby_Test/1.0/rar ) you can now remove it by typing the following command from the <geronimo_home>\bin directory:

deploy --user system --password manager undeploy console.dbpool/Derby_Test/1.0/rar

You should see a confirmation message similar to the following example.

D:\geronimo-jetty-j2ee-1.2\bin>deploy --user system --password manager undeploy console.dbpool/Derby_Test/1.0/rar
Using GERONIMO_BASE:   D:\geronimo-jetty-j2ee-1.2
Using GERONIMO_HOME:   D:\geronimo-jetty-j2ee-1.2
Using GERONIMO_TMPDIR: D:\geronimo-jetty-j2ee-1.2\var\temp
Using JRE_HOME:        C:\Java\jdk1.5.0_06\\jre
    Module console.dbpool/Derby_Test/1.0/rar unloaded.
    Module console.dbpool/Derby_Test/1.0/rar uninstalled.

    Undeployed console.dbpool/Derby_Test/1.0/rar

As an additional step for verification the removal of the database pool you can run the following command, there should be no entries listed.

deploy --user system --password manager list-modules | grep Derby_Test

If you are using MS Windows, grep is not a standard command. You may need to install additional software.