Next Previous Contents

4. Getting MMBase and setting up some things

4.1 Getting MMBase

Now that you have all supporting packages up and running (you did follow the instructions in the previous section, didn't you?) get yourself a copy of MMBase. As said before, this document describes the works for MMbase version 1.4.

Download MMBase from http://www.mmbase.org/releases/MMBase-1.4.zip with a browser, or even easier:


  wget http://www.mmbase.org/releases/MMBase-1.4.zip  

In this document I will assume that MMbase will be unpacked in /usr/local/mmbase/ so do something like this


  mkdir /usr/local/mmbase
  unzip MMBase-1.4.zip -d /usr/local/mmbase  

4.2 Getting mm.mysql

You will also need mysql.jar (JDBC driver for MySQL) which can be downloaded from http://mmmysql.sourceforge.net/.
Put the file in your /usr/local/mmbase/lib/ directory and create a symbolic link to mysql.jar.


  cd /usr/local/mmbase/lib
  wget http://mmmysql.sourceforge.net/dist/mm.mysql-2.0.2-bin.jar
  ln -s mm.mysql-2.0.2-bin.jar mysql.jar

4.3 Creating a database for MMBase

MMbase needs a database and a user that has full rights on that database. The user seems to needs rights via localhost and the real hostname. This was not entirely clear to me.

Issue the following commands on the MySQL prompt. I chose a database called MMBase, a user named mmbaseuser and the password secret.


CREATE DATABASE MMBase
USE MMBase
GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP ON MMBase.* TO mmbaseuser@'%' IDENTIFIED BY 'secret';
GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP ON MMBase.* TO mmbaseuser@localhost IDENTIFIED BY 'secret'
GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP ON MMBase.* TO mmbaseuser@realhostname IDENTIFIED BY 'secret'
flush privileges;

4.4 Setting MMBase as tomcat ROOT

This probably isn't the cleanest way to do it, but we need to let tomcat know about MMBase, which I did by making a symbolic link from /var/lib/tomcat/webapps/ROOT to /usr/local/mmbase/html.


  localhost# ls -la /var/lib/tomcat/webapps/ROOT
  lrwxrwxrwx    1 root     root           22 Sep 24 12:01 /var/lib/tomcat/webapps/ROOT -> /usr/local/mmbase/html


Next Previous Contents