Installing MediaWiki Guide: Difference between revisions

From Elvanör's Technical Wiki
Jump to navigation Jump to search
No edit summary
 
Line 24: Line 24:
* Using memcached
* Using memcached


* Obtaining nice URLs
* Obtaining nice URLs: A [http://meta.wikimedia.org/wiki/Eliminating_index.php_from_the_url guide to remove "index.php" from the URL ] is available online. However I don't find it very clear. The important steps are:
 
** Unpack the MediaWiki in a directory NOT name "wiki", for example "wikistuff" will do.
** In LocalSettings.php, set $wgScriptPath = "/wikistuff"; and $wgArticlePath = "/wiki/$1";
** Write an Alias rule for Apache: add the line
Alias /wiki /filesystem/path/to/wikistuff/index.php
in the Apache configuration file. Note: don't add the second line as mentionned in the guide!


== Usage ==
== Usage ==


* [http://meta.wikimedia.org/wiki/Help:Advanced_editing Editing Guide, very helpful ]
* [http://meta.wikimedia.org/wiki/Help:Advanced_editing Editing Guide, very helpful ]

Revision as of 15:25, 16 October 2006

MediaWiki, the Wiki engine powering this site, is fully open-source and free. It seems to be robust, and reasonably fast. Configuring and installing it, however, is not so easy. This guide is a tutorial for MediaWiki administrators.


Prerequisites

  • Apache
  • PHP
  • MySQL


Optional Software

  • APC. This is a PHP accelerator.
  • memcached. This a daemon caching SQL requests in memory. If you run two Wikis on the same machine, beware that it can cause serious problems. If there is a single memcached daemon running, and both Wikis use it, they will interfere and one Wiki will end up serving the contents of the other. A solution can be to run memcached on several machines, or maybe on the same machine but with different ports. However, this last option on Mac OS X this seems to be tricky.


Installation

Installation is easy, just download MediaWiki from Sourceforge and uncompress the tarball in a directory that Apache can serve. Then follow the instructions on the README to perform the initial configuration. It involves running a PHP script that will configure the Wiki for you.


Configuration

  • Using memcached
  • Obtaining nice URLs: A guide to remove "index.php" from the URL is available online. However I don't find it very clear. The important steps are:
    • Unpack the MediaWiki in a directory NOT name "wiki", for example "wikistuff" will do.
    • In LocalSettings.php, set $wgScriptPath = "/wikistuff"; and $wgArticlePath = "/wiki/$1";
    • Write an Alias rule for Apache: add the line
Alias /wiki /filesystem/path/to/wikistuff/index.php

in the Apache configuration file. Note: don't add the second line as mentionned in the guide!

Usage