How do I run Dokuwiki on LAMP server?

Posted March 2, 2015 4.7k views

I would like to run dokuwiki on LAMP server.

And i will run other dokuwiki on same server.
For example… wiki
  /B wiki
  /C wiki

But I don’t know what to do.

I just finished to create droplet.

Could you tell me what to do?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

Assuming you have a basic LAMP setup like the one used by the DigitalOcean One-Click application or as described in this tutorial, creating multiple wikis under the same domain is as simple as creating sub-folders in the /var/www/html directory.

First we’ll download Dokuwiki itself and extract it in our home directory:

  • cd ~
  • wget
  • tar xzvf dokuwiki-stable.tgz
  • rm dokuwiki-stable.tgz

Now we’ll make two copies in the wiki-a and wiki-b subfolders:

  • cp -R dokuwiki* /var/www/html/wiki-a
  • cp -R dokuwiki* /var/www/html/wiki-b

We’ll also need to make one addition to our Apache VitualHost. This is to make sure that certain directories are not publicly accessible on the internet. Edit the file /etc/apache2/sites-enabled/000-default.conf and add the following inside the VitualHost block.

<LocationMatch "/(data|conf|bin|inc)/">
    Order allow,deny
    Deny from all
    Satisfy All

Next, make sure the permissions are correct:

  • sudo chown -R www-data:www-data /var/www/html

Finally, you can finish installation by visiting the URLs for both wikis:

by Justin Ellingwood
One of the most common steps to take when setting up a new server is to install a LAMP stack. LAMP stands for Linux, Apache, MySQL, and PHP. These individual components, when used together, allow us to host dynamic web content like websites and web apps on our server. We will demonstrate how to install these pieces and configure a basic setup for Ubuntu 14.04 in this guide.
  • Thanks for the instructions. I followed them using a LAMP one-click droplet with Ubuntu 16 and I only want to add that after loading the install URL I got the following message:

    PHP function utf8_encode is not available. Maybe your hosting provider disabled it for some reason?
    PHP function utf8_decode is not available. Maybe your hosting provider disabled it for some reason?

    Install mbstring php module:

    sudo apt-get install php7.0-mbstring

    And then restart apache:

    sudo service apache2 restart

    Reload the install URL and it should work now.