Sun Java System Application Server Enterprise Edition 8.1 2005Q2 High Availability Administration Guide

Clearing a database

Clear a database when:

The hadbm clear command stops the database nodes, clears the database devices, then starts the nodes. This command erases the Application Server schema data store in HADB, including tables, user names, and passwords. After running hadbm clear, use asadmin configure-ha-cluster to recreate the data schema, reconfigure the JDBC connection pool, and reload the session persistence store.

The command syntax is:

hadbm clear  [--fast]  [--spares=number]  
[--dbpassword=password | --dbpasswordfile= file]  
[--adminpassword=password | --adminpasswordfile= file]  

The dbname operand specifies the database name. The default is hadb.

The following table describes the special hadbm clear command options. See General Options for a description of other options.

For more information, see hadbm-clear(1).

Table 3–12 hadbm clear Options






Skips device initialization while initializing the database. Do not use if the disk storage device is corrupted. 

Not applicable 

--spares= number


Number of spare nodes the reinitialized database will have. Must be even and less than the number of nodes in the database. 

Previous number of spares 

For example:

hadbm clear --fast --spares=2 --dbpassword secret123