General Approach

From the main Tigase directory execute following commands (Linux and Windows accordingly)

java -Dij.protocol=jdbc:derby: -Dij.database="DerbyDB;create=true" -cp libs/derby.jar:libs/derbytools.jar:jars/tigase-server.jar org.apache.derby.tools.ij database/derby-schema-5.1.sql
java -Dij.protocol=jdbc:derby: -Dij.database="DerbyDB;create=true" -cp libs\derby.jar;libs\derbytools.jar;jars\tigase-server.jar org.apache.derby.tools.ij "database\derby-schema-5-1.sql"

This will create Derby database named DerbyDB in the main Tigase directory and load Tigase schema for the version 5.1.

If there is a need to create schema for any other Tigase version then please use schema relevant to the version that you intend to use:

If you run the Tigase server all versions below 4.0:

derby-schema-3.sql

For the Tigase server version 4.x and later:

derby-schema-4.sql

For the Tigase server version 5.0 and later:

derby-schema-5.sql

For the Tigase server version 5.1 and later:

derby-schema-5-1.sql