Hosting WordPress and Mediawiki on Ubuntu Server

This article will walk you through the steps to host WordPress and Mediawiki on an Ubuntu 12.04 LTS server.

Requirements

Before you start moving around your server, you need to make sure you have everything installed. Here’s a list of requirements:

  • Ubuntu 12.04 LTS (Trusty Tahr)
  • PHP 5.5+ (You can use the latest version of PHP)
  • MySQL 5.5+
  • libxml (a library that allows you to read xml files)
  • libwnck (optional, but helps a lot when developing GUI applications)
  • gd2 (a graphics library)
  • mcrypt (a library that provides cryptographic functions)
  • imagick (a library that provides advanced image manipulation functions)
  • libicu (a library that provides Unicode support)
  • libevent (a library that provides socket event support)
  • openssl (a library that provides cryptography functions)
  • libMagickCore (a core module of Imagemagick)
  • libpcre (a library for regular expressions)
  • libssh2 (a library that provides secure socket connections)
  • libxmlrpc (a library that provides interface for XML-RPC)
  • libwww (a library that provides an interface for parsing HTML)
  • libedit (an ASCII text editor)
  • libexif (a library for manipulating and handling image metadata)
  • libarchive (a library that provides reading, extracting and manipulating compressed archive files)
  • libzip (a library for handling.zip files)
  • libbz2 (a library for handling.bz2 files)
  • libjpeg (a library for handling.jpg files)
  • libtiff (a library for handling.tiff files)
  • libpng (a library for handling.png files)
  • libpq (a library that provides PostgreSQL connection support)
  • liblucid (the library that provides support for the Illumination Game Engine)
  • libonig (a Perl compatible regular expression library)
  • libjemac (a Java source library)
  • libgmp (a library for handling large integers)
  • libsndfile (a library for handling raw midi data)
  • libsdl2 (a library that provides audio access to SDL applications)

Installation

Now that you have all the requirements set up, it’s time to move around your server and install everything. This article will cover three methods of installing WordPress and Mediawiki on an Ubuntu 12.04 LTS server:

1. The Easy Way

If you’re new to Linux or server administration, the easiest way to get everything up and running is to use what’s known as a package manager. There are a few different package managers for Ubuntu. You can use the default Ubuntu package manager or check out the others. Once you have the package manager installed, it’s just a matter of typing in the name of the software you want to install and hitting Enter at the right moment. This will bring up a list of everything available for download. Simply select the ones you need and hit Enter again.

Once everything is installed, you can launch the WordPress website management tool via the terminal (command line interface)

2. The Manual Way

If you’re an experienced Linux user or server administrator, you can manually install WordPress and Mediawiki by following the Ubuntu server guide. However, this method is quite complex and requires you to know what you’re doing. If you’re not confident in your ability to navigate a Linux terminal, this is the way to go.

3. Third Party Application Installers

Some Linux users prefer not to use a package manager and would rather just search for apps in the Ubuntu repository or other popular app stores. Using third party application installers is the easiest way to get WordPress and Mediawiki up and running on an Ubuntu server. Simply search for the software you want to install in the app store and click on the install button. The app will then walk you through the process of setting everything up. This is a simple way to get things done without having to search for the right package or worry about dependencies later on.

Getting WordPress Up and Running

Before you can use WordPress on your server, you need to generate a key pair and install the CA certificate as well as the WordPress app (for mobile devices). To do this, open a terminal (command line interface) and type the following:

  • sudo apt-key adv –keyserver keyserver.ubuntu.com –recv-keys CF641F69CF641F69
  • sudo apt-get install wpca
  • sudo apt-get install mobile-browser

This will add the necessary cryptographic keys to your web server. You’ll see a message like this:

Successfully added the necessary cryptographic keys

Now that everything is set up, it’s time to launch the WordPress website management tool via the terminal (command line interface). Type the following:

  • sudo service apache2 restart
  • sudo service mysql restart

This will launch the Apache HTTP server and allow you to create new websites or domains on your server.

Once everything is installed and Apache is running, visit your server’s IP address (usually starts with http://192.168.0.X) in a web browser. You should see a screen like this:

Congratulations! You have a fully functioning WordPress blog

If you followed the steps correctly, you should now be able to access your WordPress blog via the address http://192.168.0.X. If this is the case, then great! You can now follow the steps below to get Mediawiki up and running on your Ubuntu server.

Setting Up Mediawiki

Before you can use Mediawiki on your server, you need to generate a key pair and install the CA certificate as well as the MediaWiki app. To do this, open a terminal (command line interface) and type the following:

  • sudo apt-key adv –keyserver keyserver.ubuntu.com –recv-keys CF641F69CF641F69
  • sudo apt-get install mediwiki-data
  • sudo apt-get install mediwiki-app-apple-tv

This will add the necessary cryptographic keys to your web server. You’ll see a message like this:

Successfully added the necessary cryptographic keys

Now that everything is set up, it’s time to launch the Mediawiki website management tool via the terminal (command line interface). Type the following:

  • sudo service apache2 restart
  • sudo service mysql restart

This will launch the Apache HTTP server and allow you to create new websites or domains on your server.

Once everything is installed and Apache is running, visit your server’s IP address (usually starts with http://192.168.0.X) in a web browser. You should see a screen like this:

Congratulations! You have a fully functioning Mediawiki blog

If you followed the steps correctly, you should now be able to access your Mediawiki blog via the address http://192.168.0.X. If this is the case, then great! You can now follow the steps below to get the MongoDB database server running on your Ubuntu server.