Manual:Running MediaWiki on Debian GNU/Linux

MediaWiki installation for Debian Sarge GNU/Linux

This is the easiest way of installing MediaWiki on Debian Sarge. Remember that this installation may not be secure and ready for production purpose. It is meant to be "MediaWiki on Debian ASAP"

Core Packages
Make sure apt's package index files are synchronized:

apt-get update

Make sure you have the following packages installed apt-get install apache mysql-server php4 php4-gd2 php4-imagick php4-mysql
 * apache
 * mysql-server
 * php4
 * php4-gd2
 * php4-imagick
 * php4-mysql

Configure MySQL
Most of all you need to apply mysql root password. Remember not to use same password for system root and mysql root

mysql -u root

SET PASSWORD FOR 'root'@'localhost' = PASSWORD('xxx');

Now check if the password works:

mysql -u root

If you see:

ERROR 1045: Access denied for user: 'root@localhost' (Using password: NO)

Than mysql root account is now on password protected.

Configure PHP
Make sure your php configuration file (/etc/php4/apache/php.ini) has this line:

memory_limit = 20M

restart apache

apachectl restart

Get latest MediaWiki
Get the latest MediaWiki form MediaWiki SourceForge page example: wget http://voxel.dl.sourceforge.net/sourceforge/wikipedia/mediawiki-1.3.1.tar.gz

Copy it and extract in apache root directory:

cp mediawiki-1.3.1.tar.gz /var/www cd /var/www tar vxfz mediawiki-1.3.1.tar.gz

rename the extracted directory name to wiki mv mediawiki-1.3.1 wiki

In order to configure the wiki you have to make the config subdirectory writable by the web server.

To make the directory writable on a Unix/Linux system:

cd /var/www/wiki chmod a+w config

Navigate your browser to http://localhost/wiki and continue with installation.

Pay good attention for "Checking environment..." in MediaWiki installation script. This can solve a lot of problems for your MediaWiki successful installation. Fill out the configuration form and continue.

Once configuration is done you'll need to move the created LocalSettings.php to the parent directory, and for added safety you can then remove the config subdirectory entirely.

cd /var/www/wiki/config/ cp LocalSettings.php ..

And navigate your browser to http://localhost/wiki to see your new wiki. Done!

TeX Support
You need these packages installed: apt-get install ocaml imagemagick gs cjk-latex php4-imagick After installtion, enable inline LaTeX equations by uncommenting: $wgUseTeX          = true; in LocalSettings.php file.
 * ocaml
 * imagemagick
 * gs
 * cjk-latex
 * php4-imagick

Next compile texvc in your math directory:

cd /var/www/wiki/math make

read math/README for further detailed instructions.