3store
~~~~~~
3store is a highly scalable RDF triplestore, made available under the GNU
General Public Licence and funded by the AKT Consortium http://www.aktors.org/

For more information contact Steve Harris at <swh@ecs.soton.ac.uk>

Build and install
~~~~~~~~~~~~~~~~~
In order to compile the code you will need the folowing libraries or packages
installed:

  flex / lex   (should come with your ditribution)
  yacc / byson (should come with your ditribution)
  pkgconfig    (should come with your ditribution)
  glib         (part of GTK)
  libraptor    (http://www.redland.opensource.ac.uk/raptor/)
  mysql-devel  (either install apache from source or install the -devel
                packages for your distribution)
  apache-devel (ditto, but you only need this if you want apache module support
                for remove HTTP querying)

To build do the usual
   ./configure
   make
   su -c "make install"

To build the Apache module use "./configure --enable-http", the default MySQL
connection parameters (used by the commandline tools) can be set with:
  --enable-db-user=<username>
  --enable-db-password=<password>
  --enable-db-database=<database>

If you have installed a non-standard version of apache, you may need
to set the APXS environment variable to tell it where the apxs command
is before running configure. For example,

# APXS=/usr/local/apache2/bin/apxs ./configure

If you are happy to let the 3store software create the database setup for you
then just run tstore_setup at this point (you can add other users and KBs but
specifying options - see tstore_setup -h), if you with to create the database
table yourself, please see the section: "To create the backend database
manually".

To setup the HTTP server (if needed)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you installed the apache module you will need to tell the server what
directory to map to RDQL and/or OKBC requests, eg add:

  <Location /rdql>
    SetHandler rdql-handler
  </Location>
  <Location /okbc>
    SetHandler okbc-handler
  </Location>

to your http.conf file, eg. /etc/http/conf/httpd.conf.

Once you have done this you can load RDF files into the database with
"tstore_import file.rdf" and query them via http://machine.host.com/rdql/ if
you installed the apache module or via tstore_rdql if you didn't.

You can test the installation by running tstore_test, which will assert some
data and run some test over it. The output is not particularly easy to interpret
at this time, but if it produces more than a few lines of errors then its
working.

To create the backend database manually
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Login to mysql as the admin user, eg. "mysql --user=root mysql".

Then type (or paste in):

CREATE DATABASE rdf;
GRANT ALL PRIVILEGES ON rdf.* TO rdf@localhost IDENTIFIED BY 'rdf';

Then quit and run "mysql -urdf -prdf rdf < util/tables.sql"
