Dumping and restoring the database

Initializing your Bedework database (in Postgresql, MySQL, Oracle, etc.)

  1. Create the schema
    1. Visit the JMX console at http://<server>/jmx-console/
    2. Select “org.bedework.bwengine.core” from the “Object Name Filter” menu to the left of the page.
    3. Select “service=DbConf”
    4. Initialize the schema:
      1. Set the attribute “Export” to True
      2. Set the attribute "HibernateDialect" to match your database.  Some possible values:  org.hibernate.dialect.PostgreSQLDialect, org.hibernate.dialect.MySQLDialect, org.hibernate.dialect.Oracle10gDialect
      3. Click “Apply Changes” to set the values.
      4. Click “Invoke” for the “schema” operation.
      5. Click "Invoke" for the "Save Configuration" operation.

  2. Add initial data to the tables
    1. Select “org.bedework.bwengine” from the “Object Name Filter” menu to the left of the page.
    2. Select “service=DumpRestore”
      You will be presented with a form allowing you to manage the dump/restore process.  The “DataIn” attribute should point at the xml datafile you wish to restore.  By default, this is the initbedework.xml file.  It contains sample data.   You can change that to initbedework-sparse.xml to get a virtually empty system, but it takes a fair amount of know-how to go from that state to something useful.  Most deployers chose to start with the sample data and clean out what they don't need. 
    3. Restore the data:
      1. Set the attribute “AllowRestore” to True
      2. Click “Apply Changes” to set the values.
      3. Click “Invoke” for the “restoreData” operation.  You will see lots of activity in the server.log.

 

Creating a Bedework database-independent (XML) Dump

  1. With Bedework running, go to the JMX console at http://localhost:8080/jmx-console/
  2. Select “org.bedework.bwengine” from the “Object Name Filter” menu to the left of the page.
  3. Select “service=DumpRestore”
  4. You will be presented with a form allowing you to manage the dump/restore process.
  5. The “DataOut” attribute tells Bedework where to put the file.  By default, this is in <jboss-dir>/server/default/data/bedework/dumprestore/
  6. If you've changed any attributes, click “Apply Changes”
  7. Click “Invoke” for the “dumpData” operation.
  8. You should find a file with a name similar to “bwdata20100205T130857.xml” in your DataOut directory.

Bedework Enterprise Calendar Server, version 3.10