Xampp Installer FAQ
The Xampp Installer package has been designed for an easy installation of Moodle onto a standalone computer. This, in effect, has allowed a lot of people who do not have extensive IT skills to get a private Moodle up and running quickly and easily.
The Xampp Installer package consists of Xampp-Lite, Apache, MySQL, PHP and Moodle. As well, some very kind and thoughtful person has integrated phpMyAdmin into the package, which has a lot of benefits for anyone wanting to learn a lot more about Moodle at the nuts and bolts level.
At this time, there is a development release of Moodle 2.0 in the Downloads area, so please download it and have a play. If you find anything that does not work, please enter it as an item in Moodle Tracker and ask a question in either the General or Windows forums.
This FAQ is a set of simple questions that seem to be recurring in the forums.
Where should I use the full Moodle Windows XAMPP Installer package?
The Windows XAMPP Installer is a very simplistic package that has pre-configured Apache, PHP, MySQL And the latest releases of Moodle 1.9 and a version of Moodle 2.0. It was set up specifically for the standalone Windows environments, like XP and Vista. The Moodle/Windows XAMPP Installer is very handy for Teachers to use on their personal computers, or laptops, to develop courses they can backup then transport to their production sites. As a production site, it is useful on a very small LAN and for a small number of users, perhaps 20 or 25 at a time. Any more users and there are resource issues. It is not useful for large numbers of students or a full production web site.
This version of the XAMPP installer is modified for the Moodle installation. The full XAMPP Installer package is produced by Apache Friends and does not include Moodle. You can use the XAMPP Installer in other OS's but you need to get more information from Apache Friends about how to use it. Bear in mind though that many distros of Linux include Apache, PHP and a database, MySQL or PostGres, as native, why would you want to use it. XAMPP is also used as a core module of some Web on a Stick (WOS) services, that is, it allows you to carry your Moodle around with you on your USB, so you would only need a Standard Moodle Package install for a USB.
If you wanted to create a test site that is easy to reinstall, then the Windows XAMPP Installer is probably the easiest to use. While it obviously cannot replicate environmental, that is platform, issues, it can be handy for just about anything else.
Can I migrate my XAMPP Moodle to the Web?
There is no special coding inside Moodle that specifically connects it to XAMPP so there is no reason to think you cannot, just not in the XAMPP environment. Once set up, try to upload the Moodle files to a web site, they should upload without difficulty. The problem is going to be accessing the PHP and mySQL files to make it work and you could probably get away with this if you reuse the existing config.php file on your production site and the one on your XAMPP install. If you already have a working production site, then all you may want to do is to upgrade it to a newer version, and you can do that in any number of other ways. What you can also do is to download and unzip a Standard Moodle, then replace the existing files with updated files. While this may be a little messier than using CVS updates, it should still work. Whatever you try, or whenever you do anything like this, you need a long conversation with your host service. They may not appreciate you trying something like this without their help or knowledge.
We are using Windows Server, IIS and the Xampp installer is just not working
This happens a lot more than people like to think it does. In these circumstances, you either use Xampp or you use IIS. Moodle will run quite comfortably in either environment, even if there is a bit of tweaking to IIS and PHP you may have to complete for it to run successfully. See below for more information
Why is Xampp not running in my Windows 7?
There is any one of a number of reasons why this may happen, but the more common reasons are simple, Windows 7 automatically starts IIS as a service. As a consequence, there is a conflict between the Xampp installed Apache and IIS, so Windows 7 assigns preference to IIS and will not see Apache. You can stop IIS before Windows 7 starts it up in the configuration files. An alternative is to reset the port that IIS listens to to something other than Port 80 in the IIS ini file. The other reasons the Windows 7 refuses to allow Xampp to run are often based around permissions.
- Think Smarter: While it may not be Xampp, the addition of Xampp may be far more problematic than using what is there. Consider downloading and installing PHP and MySQL, if PHP is not already installed, and if they work, try an install of a Standard Moodle package. This may be a better option and Moodle does not care about its server environment. Microsoft is insisting on having its own way, so the ultimate alternative may be to not use Windows at all.
XAMPP or AppServ?
Both the XAMPP and AppServ packages are useful if you want to install a web server as an independent environment. They offer similar things and it is difficult to differentiate between them. Neither package is offering Moodle as native, but Moodle will comfortably run in either, once they are set up and configured properly.
How does the Xampp/Moodle package actually install?
It does so quite easily. As a general rule of thumb, it does not usually write critical elements to the Registry. This makes it considerably easier to uninstall. A simple deletion is normally all that is required, and a step through the Registry deleting anything connected to Xampp will clean it all up. The MySQL installation, however, will create the C:\Documents and Settings\All Users\Application Data\MySQL\MySQL Server 5.1\data folder. This folder contains the database you create when installing Moodle. If you install, say, MediaWiki, it will create the database and write the tables in the same folder.
I have just installed Moodle using the XAMPP Installer, but Apache will not start
Do the simple first, have you got Skype installed and running? If it is go to Skype > File > Options > Connection and uncheck the "Use port 80..." box after reading the note below it. This is the usual problem. For more information go to the Skype FAQ page.
Do the more complex next. XAMPP will usually set the Apache httpd.conf file right, but sometimes, ok, rarely, and then usually when someone has decided that they want to use a different Server root and different document root than the default, it does not always go right. If there is no Skype on the computer, then open the httpd.conf file in your text editor, NOT Word, not Notepad, and check the lines:
36: ServerRoot "G:/Server/Apache" #or your path to the Apache server folder and 179: DocumentRoot "G:/Server/Apache/htdocs" #or your path to the place you put your web documents.
The third option is that occasionally, the Windows "Hosts" file will sometimes get in the way. Go to C:\Windows\System32\drivers\etc and you will find there a file called "hosts". There is no file extension, just that name. Open the file in your text editor and there should be a line there that reads
127.0.0.1 localhost # this is my host server on my local machine
If it does not exist, enter it. If it reads something like .::1 localhost or anything else, then replace it with the line above. Make sure that every other line has a # at the start of the line, these are comments, not valid text for Windows to use. If you have anything else there uncommented, then comment it out. As usual in Windows, you need to restart.
If these are right, and you still cannot access your Apache server after starting the XAMPP Controller, then it is suggested you not waste time on it, delete it all and reinstall, just make careful note of everything, normal or abnormal, that happens during the install process. Don't panic here, if it does not work first time, it will the second, or third, or...
My test Moodle won't start even after I run XAMPP's "Moodle Start.exe", the localhost changes to http://localhost/xampp/
Basically your browser does not know where Moodle is located. This could be for any number of reasons. Usually this is an issue with an Apache configuration or with the browser address.
Browser address alternatives. Try: http://localhost/xampp/moodle or http://localhost/moodle
Remember, there are two different Xampp packages, the one you get when you download from Moodle.org that has Moodle init, aka XamppLite, and afull package directly from Apache Friends. In an XAMPP package installed from Apachefriends.org, Moodle should be installed in the htdocs folder along with a folder called XAMPP. Edit the htdocs/index.htm file so that both a HTML link to the XAMPP and Moodle sites are shown.
You could check or change the Apache httpd.conf file so that the web server links directly to Moodle when "Localhost" or the desktop's IP is typed by another machine on the local network.
Go to C:\Moodle\server\apache\conf (or whatever your path may be) Open httpd.conf file in your text editor. DocumentRoot variable should read:
DocumentRoot "C:/Moodle/server/moodle" (Your path to the Moodle index.php file)
and the Directory
<Directory "C:/Moodle/server/moodle"> (Your path to the Moodle index.php file)
Make sure the paths specified are correct.
After that, check the moodle/config.php file which is located in your Directory path folder. Look for the line:
$CFG->wwwroot = 'http://localhost';
If the wwwroot variable reads anything else, then change it to read the same as above.
If none of these things work, then delete your Moodle and reinstall, most likely something has not installed properly.
Can I use Moodle pages from the XAMPP Installer to upgrade a production server?
Yes, of course you can. There is no difference between the two in the Moodle PHP pages, just the environments in which they sit. If you have the patience and the understanding, you can reverse a XAMPP installation and remove XAMPP altogether, or rather, extract Apache, PHP, MySQL and Moodle from the XAMPP shell, and it will still run. Why bother, it is easier to just install Apache, MySQL and PHP as standalone applications.
Can I use XAMPP installed Moodle on a network?
Yes, of course. There are some limitations though. This installer was never designed for a production site, so it has some issues with hardware resources. The more people that are on line simultaneously, the greater the demands, obviously. However, the memory requirement for the server increases dramatically and therefore uses up system resources too quickly.
Perhaps a good application of the XAMPP Moodle across a network is for a course developer Moodle. That is, instead of tying up the production site, your course writers, Teachers, Course Creators, whomever, have a localized Moodle that they alone have access to to prepare courses, which are then uploaded to the production site.
If we do use XAMPP Installer that way, can courses be directly uploaded to our production site?
Yes, there is a couple of ways of doing it, either backup and restore, usually the fastest, or copy and paste, time consuming but can assure complete accuracy. But there is a couple of issues in copy and pasting. The first is that images do not copy and paste. You still have to upload your images to your production site then you have to make sure that the url pointers are aiming at the right files. Be careful here, do not get fooled into thinking that the images are OK, just because they are displaying. The production site is referencing the XAMPP site for images, which works only as long as the XAMPP Moodle is online. The same applies to links, cross referencing, and other links to documentation.
How can I make my XAMPP Moodle accessible/viewable across a small LAN?
The same way it is done for every other Moodle. The XAMPP Moodle installs to a "localhost" and if you go to the config.php file in the Moodle folder, you will find the line:
$CFG->wwwroot = "http://localhost/";
Change that to read
$CFG->wwwroot = "http://192.168.1.109/"; //or whatever you have given as an address of your server machine.
That should allow your Moodle to be accessible from elsewhere. The restriction here is that this address is not set by DHCP, it is fixed.
I keep getting the message that the maintainence cron file has not run in the last 24 hours. How can I stop that?
Run the cron job. Most Windows users are unfamiliar with the term "cron job" but essentially, it is a batch file that can be automated. Perhaps the simplest way of dealing with it is to set up a Scheduled Task. The problem is that the Windows Scheduler does not always do its job like it is supposed to in Windows XP.
I want to install and use MediaWiki in my XAMPP installed Moodle, but how?
This is not that difficult. In the XAMPP installed Moodle the Server Root can lie, for example, in the C:/Server/Apache folder and Document Root lies in C:/Server/Moodle folder, both paths are generally the same. The installation of the MediaWiki can then occur in the Moodle folder. There are no special provisions for the different use of database engines, Moodle using ISAM and MediaWiki using InnoDB, that can all be taken care of by PHP and MySQL. To make it work properly though, you may want to consider using VHosts in Apache, segmenting the server.
Can I use the Moodle XAMPP Installer for a portable webserver
It is best not to try actually. There are a number of "Webservers On a Stick", WOS, available, Server2Go, MoWeS to name just two these are more appropriate for a portable Moodle. Download and instal a WOS that has as native, Apache, PHP and MySQL, or a similar configuration, then install Moodle to the Document Root in the WOS. You could also have a look at Poodle (portable Moodle) developed by MAF Learning Technologies for use in isolated and remote areas [1]
We have outgrown XAMPP so what is next?
At this point you need to carefully consider just what do you want in the way of a Moodle. The XAMPP is a good learning and development environment for Teachers and Course Creators, but it is, more or less, a benign environment. All the major problems have been taken care of which allows it to fulfill its primary purpose, a standalone installation for teachers to develop courses in, outside of normal hours and without threatening the production site. What is nxt is what server environment do you want to use? Windows or Linux? For your web server, Apache is credible. It is scalable and, despite its apocryphal beginnings, is a stable and popular server. PHP is required, irrespective of the environment - Moodle is written in it.
The database environment is your choice, as long as it is SQL compliant, it should make little difference what database server you choose. In saying that though, realize that each database manufacturer uses their own implementation of SQL. The Moodle database interoperability layer is incredibly complex and is limited to four database environments, MySQL, MSSQL, PostGres and Oracle because of the implementation of the SQL in the database environments. In the main, this is OK, but in detail, it can be something of a minefield for anyone not fully conversant with all the different flavors of SQL. However, in these pages the majority support seems to be for MySQL. This could be because it is relatively easy to install, the right price and, if I have Moodle history right, the first database used in Moodle. This creates the "AMP" part of the acronym - Apache, MySQL, PHP, with either Windows or Linux making up the first letter.
To install Moodle in this environment is a little more demanding than XAMPP, but you end up with a stable and scalable Moodle. You can also add in so much, like a MediaWiki, if you do not like the native Moodle Wiki, or any other web tools or applications you like. You can also use Moodle for your public site - in your own server. You can also add in Mahara, or create a Joomla or Drupal site, adding Moodle, Mahara and MediaWiki, the environment is seriously flexible.
One issue that is not always clear, is that of accessing your database. You may have gotten used to using the phpMyAdmin plugin to look inside your database and find yourself somewhat at a loss to realise that your new server model Moodle does not include that as a standard Module. Download it from the link above and unzip it to the Moodle/admin folder. Go to the Administration > Server > Database page and phpMyAdmin will automatically install. Alternatively, if you want to, you can download a full version of phpMyAdmin and unzip it to its own folder. As long as you have the password and Root user name correct, phpMyAdmin can act as an additional supervisory tool for accessing any and all SQL databases you use in you web site.