Sun Java System Portal Server 7 2005Q4 Release Note Supplement

Chapter 14 Starting and Stopping the Apache Derby Open-Source Database

This supplement describes how to start and stop the Apache Derby open source database used by the collaboration feature. For more information on this feature, see Sun Java System Portal Server 7 2005Q4 Release Notes.

Starting and Stopping the Apache Derby Open-Source Database

ProcedureTo Start and Stop the Apache Derby Open-Source Database

Portal Server software uses a Apache Derby open-source database to store configuration and membership for the collaboration feature. The Portal Server software installer installs and starts the database. The portal creation process configures the database for the portal. This includes the default portal (myPortal) that is created at install time. The Derby database runs as a standalone Java application.

Step

    The database can be stopped and started using the Derby NetworkServerControl class. For example, type java org.apache.derby.drda.NetworkServerControl start -h your—host -Dderby.system.home=/var/opt/SUNWportal/derby where -h argument is required, and must match the Portal Server host name chosen at install time. To run this command:

    • The derby.jar, derbytools.jar, and derbynet.jar files must be in your classpath. By default, these JAR files are installed into /usr/share/lib/Derby directory.

    • The system property derby.system.home must be set to:

      • /var/opt/SUNWportal/derby for Solaris.

      • /var/opt/sun/portal/derby for Linux.

    Portal accesses the database using a JDBC datasource configured in the web container. The datasource configuration can be modified using the web container console, or command line interface. The database URL for the Derby community database is of the form jdbc:derby://<host>[:<port>]/communitymc_<portalID>. When connecting to the Derby database using third-party tools, use the driver org.apache.derby.jdbc.ClientDriver. This driver is in the JAR file /usr/share/lib/Derby/derbyclient.jar.