System Administrator's Guide/Requirements
From Mahara Wiki
< System Administrator's Guide
The following article lists the software and hardware requirements for any Mahara installation. There is a sister article on scalability that provides more details in particular about the hardware.
Software
Recommended Platform
Mahara is designed to run on variants of the popular LAMP stack. Apart from the PHP requirement, all other parts can be swapped for alternatives if necessary. However, the recommended platform is:
- OS: Linux - Debian Etch or later, and Ubuntu Hardy or later, are the distributions that the core developers use, and so Mahara is best tested there.
- Web Server: Apache - 1.3 or greater
- Database Server: PostgreSQL - 8.1 or greater
- Language: PHP - 5.2 or greater
All Possible Software Options
While we have a recommended platform, Mahara will run successfully using replacements for parts of the stack. All possible options, supported and unsupported, are listed here.
OS
Mahara is officially supported on the following operating systems:
- Debian GNU/Linux, all versions from 4.0/"Etch"
- Ubuntu GNU/Linux, all versions from 8.04/"Hardy Heron"
Mahara is not officially supported, but known to work or mostly work, on the following operating systems:
- Most other variants of Linux, including Red Hat Enterprise Linux, CentOS, Slackware, Fedora and SUSE.
- Microsoft Windows - all desktop versions from XP, all server versions from Windows Server 2003.
- Mac OS X Server, from Tiger upwards (note that people seem to be having more luck with Leopard and above).
Currently, we're not certain of the status of Mahara on other operating systems (Solaris springs to mind). If you know more, feel free to add them to the above list!
Web Server
Mahara is officially supported on the following web servers:
- Apache, all versions from 1.3.26
Mahara is not officially supported, but known to work or mostly work, on the following web servers:
- nginx (using fastcgi)
Database Server
Mahara is officially supported on the following database servers:
- PostgreSQL, all versions from 8.1
- MySQL, all versions from 5.0.25. Note that you will need InnoDB table support
Mahara's database must be in UTF8 encoding - this is enforced from Mahara 1.1.6 onwards for new installations (previous old versions will not be forced to upgrade). In MySQL, you can use any UTF8 collation you like - generally, you'll pick the one that suits your locale.
Please be aware that MySQL must be 5.0.25 or above - see http://bugs.mysql.com/bug.php?id=20519 for a bug in previous versions that affects some queries in Mahara.
Mahara is not supported or known to work on any other database server.
PHP
PHP version 5.2 or later is required. In addition, you'll need the following extensions:
- gd
- json
- curl (since Mahara 1.1 this is required. It was required only for networking previously)
- libxml
- SimpleXML
- session
- pgsql OR mysqli
- For networking support: openssl and xmlrpc
- mbstring
- mime_magic OR fileinfo
- Optionally: imagick
- Recommended: zlib, zip, bz2
exif was required from Mahara 1.1.0 to 1.1.4, it is now optional.
You should make sure that magic_quotes_gpc
is off, and that register_globals
is off. Mahara ships with a .htaccess
file that tries to turn these off, but sometimes Apache is not configured to allow this. Mahara will work around these settings if they're on, but it's better if you turn them off.
zip/unzip
The portfolio import/export features introduced in Mahara 1.2 require that you have zip and unzip binaries installed on your webserver.
Hardware
Mahara has hardware requirements that are extremely similar to other PHP-based web applications. A detailed analysis of this is provided in the scalability article, but here are some guiding principles:
- Mahara comprises a PHP application, which is CPU bound, and a database, which is IO bound. If you can put the database on a separate host to the web server(s), you'll be able to tune the machines more appropriately, but this isn't necessary for "small" installations (anything up to a few thousand users).
- Mahara requires somewhere between 8 and 32M of RAM for most script invocations. This means that you'll need a decent amount of RAM for your web server(s) in order to support the most number of concurrent connections. So don't be too stingy with the amount of RAM you allocate if you're going to use virtualisation, else the system will crash and burn when you get more than one user using it at once :). Consider at least 1G if you can.
- If possible, putting a reverse proxy in front of Apache is a great idea - it'll allow your site to handle more concurrent users, as Apache processes won't have to stick around while serving data to clients.
- Installing Mahara alongside other webapps like Moodle makes sense - they have similar performance profiles. But remember, this will increase the amount of load you're putting on the system. So again, if installing Mahara in a limited resource environment, you might have to increase some limits.
The minimum requirements are:
- CPU: any modern CPU produced in the last few years is fine, the faster the better naturally. PHP pages are CPU limited, so faster CPUs mean quicker response times.
- Memory: 256MB at an absolute minimum. 1G or more is recommended.
- Disk: This will depend largely on how much disk quota you want each user to have. For a site of 1000 users, each with a 250M quota, you might need 50G to start with.
For more detailed information about choosing the right hardware, check out the scalability article.
Requirements FAQ
Here are some commonly asked questions about the requirements:
Can I use Windows to host Mahara?
Users may access Mahara with a standard web browser. For hosting solutions, Mahara has been designed for Linux, Apache, PHP and an SQL database, and currently there has been very little testing for Windows hosted environments. Mahara 1.1 and beyond should be installable on Windows, however.
Instructions for installing using WAMP Server are available for Mahara, which may help you too.
Will Windows be supported in future?
Windows support, when it comes is likely to be addressed through our Partner programme or through a specific client funded request. For now, you should be able to install Mahara on Windows without too much bother, but be aware that we do not officially support this and may not be able to assist you if you have any issues.
What about hosting Mahara on Solaris/Mac/BSD/Other OS?
The developers do not explicitly test for these OSes. While they may well work, there may be issues that the developers cannot help you with. If you come across an issue and work out why it doesn't work, please consider posting in the forums or opening a bug report, so that others may benefit too!
What about using Other Web Server/Other Database/Other PHP?
No other webservers are tested, you're on your own. Please contact the dev team in #mahara/on forums if you're interested in implementing support for other databases. PHP 5.1+ is required, all versions above this should be fine.
Maybe. It depends on your host. Some hosts disable certain functions (e.g. exec
) or use safe mode, and these things can badly impact on Mahara functionality. Mahara is not explicitly designed to run on shared hosting - while it is a goal we keep in mind, and will accept patches for, shared hosting by its nature limits what you can do, and you should endeavour to obtain a VPS or dedicated host if at all possible.
If your host has disabled exec, you may lose some functionality - for example, the ability to use Import/Export.
Hosts often (stupidly) set AllowOverride None, meaning that .htaccess isn't allowed. If you are getting 500 errors when trying to set up your site, you may find commenting out the php_flag lines, or removing the .htaccess file is necessary. This will not cause a critical reduction in functionality, but if you are forced to remove the entire file it will make your site less performant than it otherwise would be. [Note: The .htaccess file may be invisible on Mac OS X and your server; it may be best to make changes to this file from a Windows based PC and upload it from that platform, which is possible despite the fact that it may appear as a nameless file.]
I am confused by all of this, where do I go to get help now?
To the Mahara Support forums, or #mahara on freenode.