I was considerating changing the WikiSoftware which runs this site from MoinMoin to PhpWiki around October 2001. As you can see it never happened but I recorded my experiences experimenting with PhpWiki. -- AdamShand

Requirements

PhpWiki has a few requirements. I am running it on DebianLinux so my setup is specific to that, though it should be very similar for any other Linux install (or even any other Unix install). To install and run PhpWiki you must have these things setup and configured (and probably some experience with them):

  1. Install apache package
  2. Install php4 package
  3. Install libdb2 package
  4. Update your /etc/apache/httpd.conf make sure that these lines exist and are uncommented (the Addtype line might be in srm.conf depending on your version of Apache):

    LoadModule php4_module /usr/lib/apache/1.3/libphp4.so
    ForceType application/x-httpd-php
    DirectoryIndex index.html index.php
    AddType application/x-httpd-php .php

Basic Installation

PhpWiki is very easy to install ...

Installation

This entire process is very straight forward, I'm not a big believer in SQL (yeah I know, I'm a heathen) so I chose to use the DBA backend. The only problem I had was due something about Debian's installation of GDBM (PhpWiki's default DB backend) and PhpWiki not getting along. Simply changing from GDBM to DB2 solved the problem.

  1. Download the source from CVS on Sourceforge and clean out the CVS cruft (be carefull with the find, you don't want to delete something you didn't mean to).

    # cd /tmp
    # cvs -d:pserver:anonymous@cvs.phpwiki.sourceforge.net:/cvsroot/phpwiki login
    # cvs -d:pserver:anonymous@cvs.phpwiki.sourceforge.net:/cvsroot/phpwiki checkout phpwiki
    # find /tmp/phpwiki -name CVS -exec rm -r {} \;

  2. Install the relevant pieces to the correct places and make sure the ownership of everything is secure. You will need to know what user your web server runs as (the default in Debian is "www-data") and I'm assuming your have root access on the server, if not you'll need to do this all with in your home directory (or where ever you have access to).

    # mv /tmp/phpwiki /usr/local/lib/phpwiki-1.3
    # chown -R root:root /usr/local/lib/phpwiki-1.3

    # mkdir /var/cache/phpwiki-test
    # chown -R www-data:www-data /var/cache/phpwiki-test
    # chmod 700 /var/cache/phpwiki-test

    # mkdir /var/www/phpwiki-test
    # cd /usr/local/lib/phpwiki-1.3
    # cp -pr index.php *css images templates /var/www/phpwiki-test
    # chown -R root:root /var/www/phpwiki-test
    # cd /var/www/phpwiki-test

  3. Setup the PhpWiki admin user and make sure it works with your setup by editing the /var/www/phpwiki-test/index.php file and setting these values (many of the will be commented out so make sure you uncomment them as well as set them):

    ini_set('include_path', '.:/usr/local/lib/phpwiki-1.3');
    define('ADMIN_USER', "admin");
    define('ADMIN_PASSWD', "secretpassword");
    define('ACCESS_LOG', '/var/cache/phpwiki-test/wiki_access_log');
    ini_set('session.save_path', '/var/cache/phpwiki-test');
    'dbtype' => 'dba',
    'directory' => "/var/cache/phpwiki-test",
    'dba_handler' => 'db2',

  4. Now load up the wiki in browser of your choice. You should see it loading a bunch of pages from the pgsrc and then it should "just work".

    # lynx http://www.domain.com/phpwiki/

  5. Now test it and make sure that everything works properly. You need to view a couple pages, login (you can login with a WikiWord and any password) edit and save a page and create a new page. After you've done all that look in /var/cache/phpwiki-test and make sure you see some files. If you don't then you haven't set some of the variables properly in the index.php file.

Migration

Well this hasn't happened yet, but there will be a perl script to migrate MoinMoin's wiki syntax to something compatible with PhpWiki.


CategoryPublished CategorySoftware

InstallPhpWiki (last edited 2003-11-23 07:28:34 by AdamShand)