| Previous: Replication | Next: Using a SQL Database for Storage | Table of Contents |
This chapter describes how to split a single handle server into multiple handle servers. This does not describe how to split sites consisting of multiple servers-- that is a much more complicated process.
The goal with this procedure is to minimize the down time for the primary site. For this reason, the database splitting process can be performed on a checkpoint/backup of the source database and then completed using the transaction log of the source database.
Here are the steps to splitting a single server site:
net.handle.server.SimpleSetup
program to create a new directory, config file, and `siteinfo.bin'
for each new server.
Save the new site info value to a new `siteinfo.bin' file. Copy this
new file in the directory of each of the new servers. Also make sure
to add the this_server_id setting to the server_config section of
each of the new handle servers.
net.handle.apps.tools.SplitServer program to split the
`handles.bak' file into the new server directories. Make sure to
specify the new server directories in the correct order on the command line.
For example, this phase of the DOI split was run like so:
java -cp handle.jar net.handle.apps.tools.SplitServer /usr/local/doi_hs \
/usr/local/doi_hs1 /usr/local/doi_hs2 \
/usr/local/doi_hs2 /usr/local/doi_hs4
|
This phase can take a long time when splitting large databases. The DOI database took several days to perform this step.
The old server should still be running at this point.
net.handle.apps.tools.SplitRecoveryLog program to
process the `dbtxns.log' file. This will scan all of the handle
modifications, creations, and deletions that have taken place since the
backup/checkpoint operation. When this is finished, the date of the last
transaction processed will be printed. Record this for future use.
net.handle.apps.tools.SplitRecoveryLog program again,
this time providing the date of the last transaction processed in step 6 on the
command line. Run the net.handle.apps.tools.SplitRecoveryLog program
with no arguments to see the syntax of the command.
This step will quickly bring the new databases into sync with the single primary by processing the transactions that have occurred on the primary since step 6.
Performing this step should cause any secondary servers to notice the site-info version number change and retrieve the new site-info record from the old primary.
| Previous: Replication | Next: Using a SQL Database for Storage | Table of Contents |