Restoring sample databases using Ant

You can delete the existing sample server databases and restore them to their initial state.

Before you begin

To run the following commands, you must define the ANT_HOME variable. For more information, see Setting up your environment to use Ant.

Important:

If you want to keep the modifications that you have done to the existing databases, create a backup of the existing databases located in <InstallDir>/shared/data/derby.

Procedure

To restore the databases:

  1. Stop the sample server if it is running.
  2. Open a command prompt, and go to <InstallDir>/shared/bin/.
  3. Type ant restoredb and press Enter.
  4. Start the sample server.