Tutorial on installing tikiwiki-15.04 on ubuntu-16.04

Posted April 7, 2017 5.6k views
ApacheUbuntu 16.04

Like in description, but I will send 20 USD to someone who makes a a walkthrough for me to install tikiwiki that I can follow through and that works (kindly provide your email address, will let you know when it works and transfer accordingly).

So try your best best and make it work. And if you have a way to make it work, answer this request.

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
2 answers

Hi @Sternenfisch
Have a look at this video - as far as I can see, the only thing you need to change is which version TikiWiki to download (the video downloads the old version 14, you just change that to 15.04)


Update/Sync and Upgrade existing packages, then install NGINX and PHP-FPM (as well as required packages).

apt-get update \
&& apt-get -y dist-upgrade \
&& add-apt-repository -y ppa:ondrej/php \
&& apt-get update \
&& apt-get -y install nginx php5.6-cli php5.6-fpm php5.6-dev php5.6-common php5.6-curl php5.6-gd php5.6-imap php5.6-intl php5.6-mysql php5.6-pspell php5.6-recode php5.6-sqlite3 php5.6-tidy php5.6-opcache php5.6-json php5.6-bz2 php5.6-mcrypt php5.6-readline php5.6-xmlrpc php5.6-enchant php5.6-gmp php5.6-xsl php5.6-bcmath php5.6-mbstring php5.6-soap php5.6-xml php5.6-zip

Install MariaDB (MySQL fork w/ better overall performance)

apt-get -y install mariadb-server

Run mysql_secure_installation to set root password for MySQL


When prompted:

1). Hit enter (you don’t have a root password set yet)

2). Type y to set a root password – make sure it’s secure (16-32 random characters). You’ll be asked to confirm the password.

3). Type y to remove anonymous users.

4). Type y to disable remote login.

5). Type y to remove test database and access to it.

6). Type y to reload privilege tables.

Now we need to create a database for Tiki. From the CLI:

mysql -u root -p

Hit enter and enter in the password you just set for root.

1). Create the Database

create database tikiwiki;

Set user permissions:

grant all on tikiwiki.* to 'tikiwiki'@'localhost' identified by 'password'

In the above, change password to a secure password (that’s different from the root password).

Now we’ll clone the Tiki repo on Github.

cd /opt
git clone

Now we’ll create our directory structure for the site.

mkdir -p /home/tikiwiki/htdocs/public

Move the Tiki files over to the above directory:

cp -R /opt/tiki/* /home/tikiwiki/htdocs/public

Set proper permissions:

chown -R www-data:www-data /home/tikiwiki/*

Now all that we need to do is setup our NGINX server block.

rm -rf /etc/nginx/sites-available/default
nano /etc/nginx/sites-available/tikiwiki

In that file, paste in:

    listen 80;
    listen [::]:80;
    server_name _;

    root /home/tikiwiki/htdocs/public;

    location /
        try_files $uri $uri/ /index.php?$args;

    location ~ [^/]\.php(/|$) {
        fastcgi_split_path_info ^(.+?\.php)(/.*)$;
        fastcgi_pass unix:/run/php/php5.6-fpm.sock;
        fastcgi_index index.php;

        fastcgi_connect_timeout 60;
        fastcgi_send_timeout 180;
        fastcgi_read_timeout 180;
        fastcgi_buffer_size 512k;
        fastcgi_buffers 512 16k;
        fastcgi_busy_buffers_size 1m;
        fastcgi_temp_file_write_size 4m;
        fastcgi_max_temp_file_size 4m;
        fastcgi_intercept_errors off;

        fastcgi_param SCRIPT_FILENAME   $request_filename;
        fastcgi_param PATH_INFO         $fastcgi_path_info;
        fastcgi_param PATH_TRANSLATED   $document_root$fastcgi_path_info;
        fastcgi_param QUERY_STRING      $query_string;
        fastcgi_param REQUEST_METHOD    $request_method;
        fastcgi_param CONTENT_TYPE      $content_type;
        fastcgi_param CONTENT_LENGTH    $content_length;
        fastcgi_param SCRIPT_NAME       $fastcgi_script_name;
        fastcgi_param REQUEST_URI       $request_uri;
        fastcgi_param DOCUMENT_URI      $document_uri;
        fastcgi_param DOCUMENT_ROOT     $document_root;
        fastcgi_param SERVER_PROTOCOL   $server_protocol;
        fastcgi_param REQUEST_SCHEME    $scheme;
        fastcgi_param HTTPS             $https if_not_empty;
        fastcgi_param HTTP_PROXY        "";
        fastcgi_param GATEWAY_INTERFACE CGI/1.1;
        fastcgi_param SERVER_SOFTWARE   nginx/$nginx_version;
        fastcgi_param REMOTE_ADDR       $remote_addr;
        fastcgi_param REMOTE_PORT       $remote_port;
        fastcgi_param SERVER_ADDR       $server_addr;
        fastcgi_param SERVER_PORT       $server_port;
        fastcgi_param SERVER_NAME       $server_name;
        fastcgi_param REDIRECT_STATUS   200;

You’ll want to change server_name _; to match that of your domain – i.e.


You’ll then want to create your DNS A and CNAME entries so that your domain resolves to your Droplet.

Now we’ll create the symlink.

ln -s /etc/nginx/sites-available/tikiwiki /etc/nginx/sites-enabled/tikiwiki

and then restart NGINX so the changes take:

service nginx restart

Now we can setup Tiki.

cd /home/tikiwiki/htdocs/public

When prompted, type ‘c’, hit enter (this will take a few minutes). Once returned to the prompt:

1). Hit enter;

2). Hit enter;

3). Hit enter;

4). Hit enter;

Now when you see Your choice [x]?, hit enter one more time (to exit the script).

The default session storage directory for PHP (using the repo I provided) is /var/lib/php/sessions. Since this is owned by root by default, we need to change that to www-data otherwise you won’t be able to run the installer.

chown -R www-data:www-data /var/lib/php/sessions

On a server with multiple sites, I wouldn’t recommend doing this. Each site should have it’s own directory to store sessions, or you should use Redis/Memcached to manage sessions. For the purpose of this quick mini-guide, this will work.

At this point, you should be able to visit (i.e. your domain) and run the installer.

You’ll use tikiwiki as the database name, tikiwiki as the database user, and the password you setup when creating the database to run the installer.

This is just a quick and dirty way of getting things setup, much like most tutorials. There’s more that needs to be done to ensure security, setup HTTPS/SSL, etc. The purpose here is to get things up and running quickly.

That said, if you have any questions, feel free to ask. I didn’t do it for the money though, just hoping I can help :-).

  • @Sternenfisch

    As a general note, PHP 5.6.x was chosen in place of 7.0.x and 7.1.x.

    TikiWiki relies on MCrypt, sadly – at least the initial install – so I chose to go with PHP 5.6.x for the setup and configuration. MCrypt is deprecated in PHP 7.1.x and while still available in 7.0.x, it’s not recommended for use.

    They need to update their script, even though I’d imagine it’ll take a bit of refactoring. Even using OpenSSL is better than using MCrypt, though LibSodium is actually recommended and looking at the game plan for PHP, the goal is to implement LibSodium support in a future release (which I believe should be by the end of the year).

    That said, if this is something you need to setup for the long-term, I’d check to see what plans they have to make sure the script is compatible with future versions of PHP so that you’re not stuck relying on a project that, last I recall, is no longer maintained (MCrypt).

    • Seems like they’re thinking about it since two weeks ago:

      If they use MCrypt for encrypting and decrypting user passwords, which it seems like, then it is a very, very bad security policy they’re using.

      • @hansen

        Agreed – I wish they’d consider LibSodium. It may require a little more work upfront but if all goes well and it does make it to core as expected, there’d be minimal work needed (if any) to make it work with future PHP versions.

    • I am doing a redesign of

      Which has lots of information for prepper communities.
      However, it is badly unstructured, as the author has basically handwritten pages in html and put up the site structure one by one so you get page addresses like this

      Which is hardly intelligible, and I find myself unable to find information on the website when surfing from phone.

      So I was looking for a CMS to fix this.
      He isnt to keen on the footprint on the server of this, but lets me try out what I feel right.

      I thought TikiWiki to be a decent framework, as it would also allow organization of the SAFE Network (Basically Civil defense volunteers) and, most important for me, would give me an option to translate content from pages into German (as basically I try to kickstart this organization here as well).

      But then again, I just found TikiWiki from its descriptions, saw its feature list reflected my needs. And went about using the hosting that someone recommended as never having issues with (and I am sure this scaling here is lovely and will stick to it).

      The alternative would be I start doing the restructuring on
      I did this for the Author Stanislaw Lem on

      Worked well even giving me relevance in Google (until I imported to many articles from Wikipedia and the double content dropped my ratings till I mothballed the effort for a while).

      But I am concerned that using wikia, which has great association for pages, will not delete all the content if I migrated somewhere else. Plus, theyd get all the advertising revenue.

      This project is for service to humanity, but if I can setup something similar to wikia, or just something that would allow for proper structuring of said website, I’d be happy.

  • Hi there,

    great tutorial, learned a lot.

    Now I followed your steps, and all worked so far.

    But when visiting domain

    I get
    Welcome to nginx!

    If you see this page, the nginx web server is successfully installed and working. Further configuration is require

    So how to get from there to the installation?

    I tried which yielded
    Fatal error: Class ‘DOMDocument’ not found in /home/tikiwiki/htdocs/public/vendor_bundled/vendor/symfony/config/Util/XmlUtils.php on line 52

    And I tried which yielded

    As you might have noticed, I have no idea what I am doing :)

    But I still intend to reward those who help me get this up and running. Your time is greatly appreciated.

    • @Sternenfisch

      If you are seeing the Welcome to NGINX page, you’ve most likely skipped a step in the guide I posted – specifically the one about removing the default server block file, creating a new one, pasting in the new server block data and creating the symlink – then restarting NGINX.

      There’s a lot of steps to get Tiki installed, so it’s definitely something that you need to take your time doing when using the guide I posted.

      As noted in the guide, this is a very basic setup. It’s meant to get you setup and running, though if you’re not familiar with managing a server on your own, it may be best to hire someone to help you properly setup a server, secure it, and install the software as there’s a lot that isn’t in that guide that does still need to be done.

      Unlike shared hosting, managing a VPS (Droplet) does require some degree of knowledge about the CLI, overall security, etc. With shared hosting, the provider is managing all of that for you. With a VPS, you’re on your own.

      If you’d like, you can get in touch with me via e-mail (in my profile, just click on my username) and we can discuss things further.