Child pages
  • Production Server Settings

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin


The installers will install a standard LAMS setup and will run fine for testing or for a small number of users. If you are setting up a LAMS server for a large number of users you will need to the following information to plan your server. It's a collection of what can be configured and where to configure it, rather than a full guide.

Most of the instructions are written for *nix (Unix/Linux/Macintosh), so if you are running Windows you will need to do what we have described in words, rather than following the exact code given on the page.

Application Server Parameters

  • Increase the default Java VM memory settings: -Xms, -Xmx, -XX:MaxPermSize. Set -Xms to at least 256m, MaxPermSize to 128m or 256m. These should be set in $JBOSS_HOME/bin/run.conf or $JBOSS_HOME/bin/run.bat (depending on your operating system).
  • Increase the number of database connections. This needs to be set in $JBOSS_HOME/server/default/deploy/mysql-ds.xml and in your database configuation. For MySQL, the max_pool_size in mysql-ds.xml should be less than or equal to the max_connections in mysql-Xms.
  • Increase the number of request-processing threads and other web connection related settings in the tomcat connector, under $JBOSS_HOME/server/default/deploy/jbossweb-tomcat55.sar/server.xml. The main parameter to change will be maxThreads depending on the maximum number of simultaneous users you anticipate for your server. See for details on this and other tomcat connector parameters.
    • There are two connectors - the HTTP connector on port 8080, and the AJP connector on port 8009. If you're serving LAMS via Apache/mod_jk, configure the AJP connector, otherwise, do the HTTP one.
  • Configure the settings in the lams_configuration table. Once LAMS is running this can be done via the system administration screen. The data is read from the database on startup. If you update it via the system administration screen then the settings are applied immediately. If you change them in the database then you must restart LAMS to have any effect. See LAMS Configuration.

Apache and mod_jk

To use Apache w/mod_jk to serve static content, use JkMount and JkUnMount as below. Note this only includes the exploded content under the lams-central.war in the deploy directory, tool content inside each tool's .war will still be served by jboss.

Code Block
JkMount /lams/* ajp13_worker
JkUnMount /lams/css/* ajp13_worker
JkUnMount /lams/images/* ajp13_worker
JkUnMount /lams/includes/* ajp13_worker
JkUnMount /lams/fckeditor/*.* ajp13_worker
JkUnMount /lams/flashxml/* ajp13_worker
JkUnMount /lams/www/news.html ajp13_worker
JkUnMount /lams/www/images/* ajp13_worker

Note the *.* after 'fckeditor', this is important since there are two LAMS servlets that are mapped under /lams/fckeditor/* and they need to fall outside this JkUnMount directive.

If you are running *nix, you will need to link each of the JkUnmounted directories under your DocumentRoot in Apache. e.g. (assuming your DocumentRoot is /var/www - change the first line if your document root is elsewhere)

Code Block
cd /var/www
mkdir lams
cd lams
ln -s /usr/local/jboss-4.0.2/server/default/deploy/lams.ear/lams-central.war/css/ css
ln -s /usr/local/jboss-4.0.2/server/default/deploy/lams.ear/lams-central.war/images/ images
ln -s /usr/local/jboss-4.0.2/server/default/deploy/lams.ear/lams-central.war/includes/ includes
ln -s /usr/local/jboss-4.0.2/server/default/deploy/lams.ear/lams-central.war/fckeditor/ fckeditor
ln -s /usr/local/jboss-4.0.2/server/default/deploy/lams.ear/lams-central.war/flashxml/ flashxml
mkdir www
cd www
ln -s /usr/local/jboss-4.0.2/server/default/deploy/lams.ear/lams-www.war/news.html news.html
ln -s /usr/local/jboss-4.0.2/server/default/deploy/lams.ear/lams-www.war/images/ images

If you are running Windows, you cannot link the files. Instead you will need to make two directories "lams" and "www" in your DocumentRoot in Apache. Then copy the following directories (and their contents)

Copy Directory
















Files and Logs

  • The files uploaded by users go onto two different areas. These directories will continue to grow - as even if their designs are archived the files still remain on the system. So they should be put in any area (such as /var on *nix) that has a lot of disk space available and preferably an area that can have additional disk space added to it in the future.
    • The content repository directory (set in the lams_configuration table)
    • $JBOSS_HOME/server/default/deploy/lams.ear/lams-www.war/secure
  • Log files are written to $JBOSS_HOME/server/default/log and can be archived and removed periodically. The log files named audit.log.<date> are audit logs and should be archived and preserved for future reference. These logs contain entries for things like monitoring stuff editing a learner's answer or user configuration changes.
  • When authoring gets an error from the server, it may send a dump file to the server. These files are for reporting the problem back to MELCOE. The files are written the in the DumpDir configured in the lams_configuration table and may be removed periodically.
  • In LAMS 2.0, the temporary files are written to the temporary directory as set in the operating system. e.g. /tmp on a Linux server. They will be in the format lamstmp_<longnumber>_somedescription. These files may be removed once they are a couple of days old. They were supposed to be written to the TempDir set in the lams_configuration table, but that doesn't seem to be happening!



Depending on which operating system you use and how MySQL is configured, you may be able to backup LAMS using the backup utility (see Windows Backup and Restore) otherwise you will need to back it up manually (see Other Backup and Restore).

Moving MySQL To Another Server

If you find your server is heavily loaded and that MySQL is taking a lot of the load, you can try moving the MySQL database to another server. At present this must be done manually as the installers will only install if MySQL is running locally, although the upgraders will support the "split" configuration.