This document describes how to set up a MySQL datastore as part of installing a W3C-Perllib Annotation server.
The RDF persistent database uses an SQL store. The code has been tested with MySQL. It is likely the code will work with other SQL databases. Please drop a line to the list if you set it up with another database.
MySQL is available via HTTP from MySQL.com. If you have a RedHat Linux system, install the RPM, Debian users can use apt-get install mysql-server. Other platforms may have to build the source from scratch.
The MySQL documentation describes the MySQL authentication scheme. In summary: MySQL grants access based on user/host and tables in the mysql database. For the purpose of keeping a consistent example, we will use the username: AnnotateUser, password: AnnotatePassword, and host: localhost . SQL commands are case-insensitive and examples will use SQL commands in UPPERCASE. The following commands will grant the RDF persistent database access:
mysql -u root mysql INSERT INTO user (Host,User,Password,Select_priv,Insert_priv,Update_priv,Delete_priv,Create_priv,Drop_priv,Reload_priv,Shutdown_priv,Process_priv,File_priv,Grant_priv,References_priv,Index_priv,Alter_priv) VALUES ('%','AnnotateUser',password('AnnotatePassword'),'Y','Y','Y','Y','N','N','N','N','N','N','N','N','N','N');
The Perllib Rdf bin directory (W3C/Rdf/bin) contains a shell script to tell MySQL how to create the Rdf database.
The RDF annotate
script agent needs a configuration file for the database related
properties. The file should be named as
rdf.prop and look
user: AnnotateUser password: AnnotatePassword database: rdf queryHost: localhost
The script agents find this and other configuration files under the
Conf directory which is located under the root WWW
directory class path. For instance, if the RDF libraries are checked out into
/usr/local/perl/modules/W3C/Rdf/..., the configuration
properties files should be located in
/usr/local/perl/modules/Conf/ . The configuration file is used
in the scripts e.g. in the following way
Copyright © 1999-2003 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C liability, trademark, document use and software licensing rules apply. Your interactions with this site are in accordance with our public and Member privacy statements.