Difference between revisions of "Complete install packages for Windows"

Jump to: navigation, search
(copied Complete install packages)
 
(More tips and cautions)
 
(81 intermediate revisions by 23 users not shown)
Line 1: Line 1:
Complete install packages are available from [http://download.moodle.org/ Moodle Downloads], located on a tab for each of the operating systems. The packages are designed for new installations on a server or standalone computer. Please note the standard distributions only contain the Moodle code.
+
{{Installing Moodle}}
 +
Complete install packages are available from Moodle.org's [https://download.moodle.org/windows/ Windows download page] and also from [https://bitnami.com/stacks Bitnami stacks]. The packages are designed for new installations on a standalone computer. All them use the popular [https://www.apachefriends.org/ XAMPP Apache Friends packages]. The complete install package can be used on a server, but '''it is not recommended that it be used as a production site'''. Please note Moodle.org's [http://download.moodle.org Standard install packages] only contain the Moodle code.
  
 
This document provides instructions for using the Windows packages. Separate instructions are available for [[Complete Install Packages for Mac OS X|Mac OS X packages]].
 
This document provides instructions for using the Windows packages. Separate instructions are available for [[Complete Install Packages for Mac OS X|Mac OS X packages]].
  
For installation on a Windows 2000 or Windows 2003 server it is good practice to perform a manual install (see the manual installation section in [[Windows_installation|Windows Installation]]).  
+
The complete install packages allow Moodle to be installed, along with the prerequisites that includes a web server, Apache, database, MySQL, scripting language, PHP and Moodle all wrapped in the Xampp-lite shell. Several versions of the complete install package are available. The instructions on the download page provide guidance on which version is likely to be most suitable.
  
After installing the Windows package, note that there are other downloads (e.g. additional modules and plugins) that may involve more customization of configuration files.
+
In short, complete install packages are designed to create a matched webserver and Moodle site on a standalone computer with minimal effort.  
  
The complete install packages allow Moodle to be installed, along with the prerequisites that includes a web server, database and scripting language (Apache, MySQL and PHP in this case). Several versions of the complete install package are available. The instructions on the download page provide guidance on which version is likely to be most suitable.
+
==System requirements==
 +
:*256 MB RAM (minimum), 1GB RAM (recommended)
 +
:*500 MB free Fixed Disk (more space will be needed depending on user uploads)
 +
:* For old versions of Moodle:
 +
:**Windows 98/ME (minimum)
 +
:**Windows NT/2000/XP/2003 (recommended)
 +
:* For Moodle 3.1 and later versions:
 +
:**Windows Vista/7/8/10/2008/2012
 +
:**Microsoft Visual C++ 2015 Redistributable package is required for PHP ([https://www.microsoft.com/en-us/download/details.aspx?id=48145 download link)]. This must be the '''vc_redist.x86.exe''' download as the PHP build is 32-bit.
 +
 
 +
===Port 80 Conflict if Skype is already installed===
 +
As the Moodle Windows package uses the same port (80) as [http://www.skype.com/en/ Skype] does, it will not work if the computer has Skype already installed.
 +
 
 +
The fix is very simple: Exit Skype (don't just close the window), then start the Moodle Windows package. Once Moodle for Windows is running, it should be safe to start Skype again. If the local Moodle is using the port 80, Skype will automatically select a different port when it is run.
 +
 
 +
===Vista and Windows 7/8/10===
 +
 
 +
Packages generated for Moodle 3.1 and later versions should work with Vista/7/8/10 out of the box. They include PHP 7 and MariaDB instead of MySQL, resulting in a smoother experience than previous versions of the packages.
 +
 
 +
If you have Windows 7, you must check if [[Errors_FAQ#Check_if_you_need_to_increase_Apache.E2.80.99s_default_stack_size| you need to increase Apache default stack size]].
 +
 
 +
People facing problems with the new packages are advised to:
 +
 
 +
* Check the PC with a good antivirus. Be very cautious when choosing a free/paid Windows antivirus. Good places to look for are [https://www.pcmag.com/article2/0,2817,2372364,00.asp old, reliable, solid PC magazines] and [https://www.tomsguide.com/us/best-antivirus,review-2588-5.html old, reliable, solid PC blogs]. Beware of many malicious malware programs posing as antivirus solutions! Google for any chosen solution before installing it.
 +
* Check the problem text: If it says that the connection was reset, read [https://docs.moodle.org/36/en/Errors_FAQ#.27The_connection_was_reset.27_when_using_a_Moodle_Windows_complete_install_package_for_recent_versions_in_a_modest_hardware this documentation page] for diagnosis and fix.
 +
* Read the Requirements and Troubleshooting information, both here and in the package's README.txt file.
 +
* Report any consistent problem in the [https://tracker.moodle.org Moodle Tracker], so it can be investigated and, hopefully, fixed.
 +
* Consider installing a virtual machine (eg, [https://www.virtualbox.org/ VirtualBox]) with a windows or linux LAMP stack and then install Moodle there.
 +
* Switch to:
 +
** a Windows 10 PC O.S. ([https://www.microsoft.com/en-us/windows/windows-10-specifications if your hardware supports it] and you can afford it),
 +
** a Linux (best option) O.S., [https://www.ubuntu.com/ Ubuntu] is a popular Linux flavour as [https://help.ubuntu.com/lts/installation-guide/armhf/ch02.html?_ga=2.1106225.1061556046.1528904082-1294294419.1525365952 most PCs can support it],
 +
** a Mac if you are tired of Windows problems and money is not an issue.
 +
 
 +
* Use other Moodle-ready alternatives [https://moodlecloud.com out there].
 +
 
 +
* Read the documentation for [[Errors FAQ]]
 +
 
 +
==Install complete package process==
 +
The complete install package is a zip file that contains a webserver called [[Apache]], plus Moodle and Moodle's required [[MySQL]] database and [[PHP]] program.
 +
 
 +
There are three basic parts to the this install process.
 +
#Download and unpack the complete install package.  
 +
#Start the webserver.
 +
#Install Moodle using a web browser.
 +
 
 +
===First create file structure===
 +
====Download the package====
 +
[http://download.moodle.org/windows Download Windows] packed-zip file from Moodle.
  
Note: The latest complete install package version components, may not be backwardly compatible. Always check version compatibility of each component if you intend to develop materials on a later version of Moodle than the version installed on your "main" Moodle site.  In short, complete install packages are designed for first time install on a "clean" machine.  
+
====Unpack the package====
 +
Unpack (extract files by clicking on) the zip file you downloaded to a drive or partition of your choice. The extract process will create three files ("Start Moodle", "Stop Moodle", and "README") and a subfolder called "server".  
 +
*Do NOT rename the "server" subfolder 
 +
:''Note:'' There will also be a folder under this server subfolder, called \moodle that holds the Moodle program.
  
==System requirements==
+
:''TIP:'' Create a folder and extract the files there.  For example, you might have one folder called Moodle254 and another one called Moodle281 for different versions or purposes.
  + 256 MB RAM (minimum), 512 MB RAM (recommended)
+
 
  + 160 MB free Fixed Disk (more space will be needed depending on user uploads)
+
:''TIP:'' Make path to "server" subfolder simple. Best way if it will be in drive root. Like "D:\moodle281\server". A long path, especially with any strange symbols, can prevent XAMPP from working properly.
  + Windows 98/ME (minimum)
 
  + Windows NT/2000/XP (recommended)
 
  
==Install complete package ==
+
:''NOTE:'' If you will be installing a server with a language other than English, the install process will need to download the corresponding language pack, which will take some time, and you will likely get a script timeout error. To prevent this, you will need to edit the server/php/php.ini file and change the line that has 'max_execution_time = 30' into 'max_execution_time = 600'.
As noted above the complete install package is a zip file that contains Moodle and programs to create a webserver called Apache, MySQL and PHP.
 
  
===First steps===
+
===Second - start the webserver===
'''Step 1:''' [http://download.moodle.org/windows Download Windows] packed-zip file from Moodle.
+
Now you are ready to start the webserver. Use the "Start Moodle.exe" file which you should find in the top directory. Once the "Start Moodle.exe" program is open, don't close it; use "Stop Moodle.exe" for that purpose.
[[Image:Moodle Setup zipfile.jpg|frame|center|A downloaded complete install package Windows 1.9 zip file in Windows Explorer]]
 
 
   
 
   
'''Step 2:''' Unpack (extract files by clicking on) the zip file you downloaded to a drive or partition of your choice. The extract process will create a folder called "moodle". For example, C:\moodle or W:\moodle or something like this.
+
:''Note:'' These programs control both Apache and MySQL programs that operate the webserverSome sites will individually start and stop Apache and MySQL with the Xampp bat files found in the "server" subfolder.
*It is a good practice at this point to rename the C:\moodle to something like C:\Moodle19 or C:\Web. 
 
*Note: there will also be a folder under this top folder, called \moodle that holds the Moodle program. [[Image:Moodle_Setup_folders_mu.jpg|thumb|center|Typical file structure after unpacking a zip file]]
 
 
 
'''Step 3:''' Using Window's explorer find and click on "setup_xampp.bat" in the top folderThis will configure Xammplite and the webserver.
 
*Note: XAMPP makes no entries in the windows registry and no settings for the system variables.  
 
  
[[Image:Moodle_Setup_files_1_mu.jpg|thumb|center|Example of webserver files on a standalone computer]]
+
:''Tip:'' Alternatively, on a standalone computer with several potential webservers that might be running, you can use the "xampp_restart.exe" file in the "server" subfolder.
  
'''Step 4:''' Now you are ready to start the webserver.  Use the Xampp_start file which you should find in the top directory (for example C:\Moodle19).  Once the Xampp_start program is open, don't close it, use Xampp_stop for that purpose. 
+
:''Tip:'' You can also add shortcuts to the commands that start and stop the site in your Windows "start" menu.
*Xampp start and stop program(s) control both Apache and MySQL programs that operate the webserver.  Some sites will individually start and stop Apache and MySQL with their bat files found in the top folder such as C:\Moodle19
 
**Or on a stand alone computer with several potential webservers that might be running, use the "restart".
 
**Put shortcuts to the commands that start and stop the site in your Windows "start" menu system.
 
 
   
 
   
 +
Now you are ready to start the Moodle installation.
  
'''Step 5:''' Now you are ready to start the Moodle installation.
+
:''Warning:'' Windows XP requires the msvcr71.dll library file in order to run Xampp. Installing the [http://www.microsoft.com/downloads/details.aspx?familyid=262D25E3-F589-4842-8157-034D1E7CF3A3&displaylang=en .Net 1.1 framework] (not .Net 2.0 and upper) could resolve it. You can also search for the file on Google, download it and copy it into the server/apache/bin folder.
  
===Start the Moodle installation===
+
===Third - start Moodle installation===
 
Start your web browser and type <nowiki> localhost, or  http://127.0.0.1 or http://localhost </nowiki>in the address bar. You will either start your first time Moodle installation or if it is already installed you will enter the Moodle site's [[Front Page]] or Login screen.
 
Start your web browser and type <nowiki> localhost, or  http://127.0.0.1 or http://localhost </nowiki>in the address bar. You will either start your first time Moodle installation or if it is already installed you will enter the Moodle site's [[Front Page]] or Login screen.
  
**Tip: after Moodle installs, put the site in your "favorites" or as a "bookmark" in you browser.
 
 
[[Image:Moodle_Setup_localhost_browser.jpg|frame|center|A browser's addressbar showing "localhost". Click on  the green Goto arrow will go to the installed Moodle site.]]
 
[[Image:Moodle_Setup_localhost_browser.jpg|frame|center|A browser's addressbar showing "localhost". Click on  the green Goto arrow will go to the installed Moodle site.]]
  
**Tip: after Moodle installs, put the site in your "favorites" or as a "bookmark" in you browser.
+
:''Tip:'' After Moodle installs, put the site in your "favorites" or as a "bookmark" in you browser.
 
 
  
 +
====Set language====
 
The initial install page will be displayed after you type "localhost".
 
The initial install page will be displayed after you type "localhost".
  
[[image:Xampp24.gif|thumb|center|665px]]
+
[[Image:C Install Windows 1.png|thumb|center|600px|Set initial language]]
  
 
*Choose your preferred language (English is used in this example) and click the “Next” button.
 
*Choose your preferred language (English is used in this example) and click the “Next” button.
  
*A diagnostic report is displayed – hopefully it will look like this, if not you may need to address some issues.
+
====Diagnostic results====
 
+
A diagnostic report is displayed – hopefully it will look like this, if not you may need to address some issues.
[[image:Xampp25.gif|thumb|center|546px]]
+
[[Image:Complete Windows Install 2.png|thumb|center|546px|Moodle liked and gave a Pass ]]
  
  
 
*Click the “Next” button to continue.
 
*Click the “Next” button to continue.
  
*The paths for your Moodle installation are shown – accept the ones that are shown on your screen.
+
====Moodle paths====
 +
The paths for your Moodle installation are shown – if you are only using this as a local testing server, accept the ones that are shown on your screen.
  
[[image:Xampp26.gif|thumb|center|527px]]
+
What you enter in the "Web Address" field depends on what you intend to use the new Moodle installation for.
 +
If you are just going to use it for local testing, then use 'http://localhost'.
 +
If you are going to test the new installation on a LAN, and will be accessing it from other machines on that LAN, then put the private IP address or network name of the serving machine, followed by a forward slash and moodle: Web Address - http://192.168.1.1/moodle
 +
If you are going to test the installation on the internet, then you will need to put the public ip address followed by a forward slash and moodle: http://your_ip_address/moodle or you can put your domain name here instead.
  
 +
[[image:Complete install Windows 3.png|thumb|center|600px|Installation paths]]
  
 
*Click the “Next” button to continue.
 
*Click the “Next” button to continue.
  
*What you enter in the "Host Server" field depends on what you intend to use the new Moodle installation for.
+
====Database configuration====
If you are just going to use it for local testing, then use 'localhost'.
 
If you are going to test the new installation on a LAN, and will be accessing it from other machines on that LAN, then put the private IP address or network name of the serving machine, followed by a forward slash and moodle: Host Server - 192.168.1.1/moodle
 
If you are going to test the installation on the internet, then you will need to put the public ip address followed by a forward slash and moodle: your_ip_address/moodle or you can put your domain name here instead.
 
 
 
 
*In the next fields, we enter the database settings. The fields are populated with some suggested values.
 
*In the next fields, we enter the database settings. The fields are populated with some suggested values.
  
Line 80: Line 120:
  
 
*DO NOT USE THE “ROOT” USER WITHOUT A PASSWORD FOR PRODUCTION INSTALLATIONS AS THIS CREATES A SECURITY VULNERABILITY
 
*DO NOT USE THE “ROOT” USER WITHOUT A PASSWORD FOR PRODUCTION INSTALLATIONS AS THIS CREATES A SECURITY VULNERABILITY
[[image:Xampp27.gif|thumb|center|535px]]
+
[[image:Complete install Windows 4.png|thumb|center|535px|Installation's database settings]]
  
 +
*When the fields have been populated, click the “Next” button to continue.
  
*When the fields have been populated, click the “Next” button to continue.
+
====Check server====
 +
The install process checks the server is installed. All the checks should pass as far as the [[#System_requirements|system requirements]] have been fulfilled.
 +
[[image:Complete install Windows 5.png|thumb|center|535px|Check server environment screen]]
 +
*Click the “Next” button to continue.
  
*Provided the Moodle folder is writable, a message confirming the configuration has been completed will be displayed.
+
====Confirm initial language pack====
 +
Moodle will now check to see if the language pack is available for the language you selected at the first step.  If it is not, Moodle will continue with the install in English.
 +
[[image:Complete install Windows 6.png|thumb|center|535px|Language pack check]]
  
[[image:Xampp29.gif|thumb|center|549px]]
+
====Confirm config.php====
 +
Provided the Moodle folder is writable, a message confirming the configuration has been completed will be displayed.
 +
[[image:Complete install Windows 7.png|thumb|center|549px|Confirmation that config.php has been created]]
  
 
*Click the “ Continue” button to proceed.
 
*Click the “ Continue” button to proceed.
  
The Moodle copyright / licence notices are displayed.
+
====Moodle copyright & agreement====
 +
The Moodle copyright / license notices are displayed.
  
[[image:Xampp30.gif|thumb|center|723px]]
+
[[image:Complete install Windows 8.png|thumb|center|400px|Copyright notice and agreement]]
  
 +
*Click the “Yes” button to continue. 
  
*Click the “Yes” button to continue. In most cases this will be followed by a series of screens that have a continue button on the bottom.  In Moodle 1.8 look for the "Unattended" checkoff box.  This will press the continue button at the bottom of the screen for you. This process stops with Admin user profile settings which needs to be filled out, then goes to the site setting page.
+
====Current release and unattended option====
 +
The current release information is shown.
 +
'''Check off the unattended operations box'''. This will automatically advance through many screens.  If you would like to watch the install screen by screen, do not check this box and be prepared to press the "continute button" many times.
 +
 +
*Click the "Continue" button and wait.
 +
[[Image:Complete install Windows 9.png|thumb|center|600px|Current release and "unattended" check box]]
 +
 
 +
====Installation modules and blocks screens====
 +
In most cases this will be followed by a series of screens that have a continue button on the bottom.  This process stops with Admin user profile settings which needs to be filled out.
 +
 
 +
====Administrator user profile====
 +
[[Image:Complete install Windows 10.png|thumb|center|The administrator's users profile screen]]
 +
 
 +
Fill out the required fields.
 +
*Click on "Save" to continue
 +
 
 +
====Front page settings====
 +
The next screen is the Front Page settings page.  There are two parts to it.
 +
The first part will ask for your Full site name and a short name for the navigation bar. There is also a place for a description. You can change these later. 
 +
 
 +
[[Image:Complete install Windows 11a.png|thumb|center|The Moodle sites [[Front Page]] information]]
 +
 
 +
The second part on the bottom instructs Moodle if you will disable the new user self [[Authentication|authentication]] through email process.  The default is to disable.  This can be changed later in the [[Site administration block|site administration block]].
 +
 
 +
[[Image:Complete install Windows 11ba.png|thumb|center|500px|Determine if users can create their own profiles when they log onto the side via email self authentication]]
 +
 
 +
*Click on "Save changes" button to go to Moodle sites home page.
 +
 
 +
====Moodle on====
 +
'''Now you are ready to Moodle !'''
 +
 
 +
[[Image:Complete install Windows 12.png|thumb|center|Blank Front page of your new site]]
 +
 
 +
The Site Administration block is on the left, the "Turn edit on" button in the upper right corner, withe the site description block just below it.
  
 
===Congratulations - Moodle has been installed===
 
===Congratulations - Moodle has been installed===
This finishes the installation of a complete package.  Type http://localhost in your browser and Moodle will open.  
+
This finishes the installation of a complete package.  Type <nowiki>http://localhost</nowiki> (or what ever you set for web address earlier in the setup!) in your browser and Moodle will open.  
  
Your next task will be to configure Moodle.  See [[Administrator_documentation#Configuration]] or [[Administrator_documentation]].  Don't worry, it is easy to change any of the settings once Moodle is running.
+
Your next task will be to configure Moodle to meet your needs.  Don't worry, it is easy to change any of the settings now that Moodle is up and running.
 +
*Check ''Settings > Site administration'' for further links.
 +
 
 +
==More tips and cautions==
 +
*For installation on a Windows 2000 or Windows 2003 production server it is good practice to perform a manual install (see the manual installation section in [[Windows_installation|Windows Installation]]).
 +
 
 +
*After installing the Windows package, you may wish to add additional contributed modules and plugins.  These may involve more customization of configuration files.
 +
 
 +
*The latest complete install package version components, may not be backwardly compatible. Always check version compatibility of each component if you intend to develop materials on a later version of Moodle than the version installed on your "main" Moodle site.  In short, complete install packages are designed for first time install on a "clean" machine.
  
 
== Security matters (A MUST READ!)==
 
== Security matters (A MUST READ!)==
Line 113: Line 204:
 
The MySQL administrator (root) has no password.
 
The MySQL administrator (root) has no password.
 
The MySQL daemon is accessible via network.
 
The MySQL daemon is accessible via network.
phpMyAdmin is accessible via network.
 
 
Examples are accessible via network.
 
Examples are accessible via network.
  
 
To fix most of the security weaknesses simply call the following URL:
 
To fix most of the security weaknesses simply call the following URL:
  
http://localhost/security/
+
<nowiki>http://localhost/security/</nowiki>
  
The root password for MySQL + phpMyAdmin and also a XAMPP directory protection can be established here.
+
The root password for MySQL and also a XAMPP directory protection can be established here.
  
 
Note that on the Windows installer package, some (all?) of these issues have been fixed already by default and the above link does not work.
 
Note that on the Windows installer package, some (all?) of these issues have been fixed already by default and the above link does not work.
Line 127: Line 217:
  
 
== Apache and MySQL tweaks ==
 
== Apache and MySQL tweaks ==
 +
Most of the time it is not necessary to tweak Apache or MySQL after completing the complete install package. Nor is it necessary to individually start and stop them because that is what the Xampp_start, Xampp_restart and Xammp_stop files are for. 
 +
 +
 
=== Installing Apache and MySQL as services===
 
=== Installing Apache and MySQL as services===
 
(This is only for NT4 | Windows 2000 | Windows XP operating systems)
 
(This is only for NT4 | Windows 2000 | Windows XP operating systems)
Line 147: Line 240:
 
===Apache Notes===
 
===Apache Notes===
  
You should use the apache_start and apache_stop bat files to start and stop apache from running.
+
You can use the apache_start and apache_stop bat files to start and stop apache from running. However the Xampp_start or Xampp_restart and Xampp_stop is recommended to turn on/off both Apache and MySQL.
  
===Troubleshooting===
+
====Troubleshooting====
  
 
If you find that Apache is very flaky, with the page often not loading properly or even at all (especially on localhost), try adding these lines to the end of C:\your_moodle_installer_directory\apache\conf\httpd.conf  
 
If you find that Apache is very flaky, with the page often not loading properly or even at all (especially on localhost), try adding these lines to the end of C:\your_moodle_installer_directory\apache\conf\httpd.conf  
Line 156: Line 249:
 
   EnableMMAP Off
 
   EnableMMAP Off
 
   Win32DisableAcceptEx
 
   Win32DisableAcceptEx
 +
 +
If You edit some .php files but browser still show old state of them, try to disable eAccelerator extension in \server\php\php.ini
 +
 +
[eAccelerator]
 +
;extension=eaccelerator.dll
  
 
===MySQL notes===
 
===MySQL notes===
 +
Again, the recommendation to start and stop the entire webserver is to use the xampp_start or Xampp_restart and the Xampp_stop.  The following maybe useful if you wish to tweak the system further.  Please be careful.
  
(1) The MySQL server can be started by double-clicking (executing)
+
(1) The MySQL server can be started by double-clicking (executing) mysql_start.bat. This file can be found in the same folder you installed xampp in, most likely this will be C:\xampplite\. The exact path to this file is X:\xampplite\mysql_start.bat, where "X" indicates the letter of the drive you unpacked xampp into.This batch file starts the MySQL server in console mode. The first intialization might take a few minutes.
    mysql_start.bat. This file can be found in the same folder you installed
 
    xampp in, most likely this will be C:\xampplite\.
 
    The exact path to this file is X:\xampplite\mysql_start.bat, where
 
    "X" indicates the letter of the drive you unpacked xampp into.
 
    This batch file starts the MySQL server in console mode. The first  
 
    intialization might take a few minutes.
 
 
      
 
      
    Do not close the DOS window or you'll crash the server!
+
Do not close the DOS window or you'll crash the server! To stop the server, please use mysql_shutdown.bat, which is located in the same directory.
    To stop the server, please use mysql_shutdown.bat, which is located in the same
 
    directory.
 
  
 
(2) To use the MySQL Daemon with "innodb" for better performance,  
 
(2) To use the MySQL Daemon with "innodb" for better performance,  
    please edit the "my" (or "my.cnf") file in the /xampplite/mysql/bin  
+
please edit the "my" (or "my.cnf") file in the /xampplite/mysql/bin directory or for services the c:\my.cnf for windows NT/2000/XP. In that director, activate the
    directory or for services the c:\my.cnf for windows NT/2000/XP.  
+
"innodb_data_file_path=ibdata1:30M"
    In there, activate the "innodb_data_file_path=ibdata1:30M"
+
statement. Attention, "innodb" is not recommended for 95/98/ME.
    statement. Attention, "innodb" is not recommended for 95/98/ME.
 
 
      
 
      
    To use MySQL as Service for NT/2000/XP, simply copy the "my"  
+
:To use MySQL as Service for NT/2000/XP, simply copy the "my" / "my.cnf" file to C:\my, or C:\my.cnf. Please note that this file has to be placed in C:\ (root), other locations are not permitted. Then execute the "mysql_installservice.bat" in the mysql folder.
    / "my.cnf" file to C:\my, or C:\my.cnf. Please note that this  
+
 
    file has to be placed in C:\ (root), other locations are not permitted. Then
 
    execute the "mysql_installservice.bat" in the mysql folder.
 
   
 
  
(3) MySQL starts with standard values for the user id and the password. The preset
+
(3) MySQL starts with standard values for the user id and the password. The preset user id is "root", the password is "" (= no password). To access MySQL via PHP with the preset values, you'll have to use the following syntax:
    user id is "root", the password is "" (= no password). To access MySQL via PHP
+
mysql_connect("localhost","root","");
    with the preset values, you'll have to use the following syntax:
+
If you want to set a password for MySQL access, please use of mysqladmin.
    mysql_connect("localhost","root","");
+
To set the password "secret" for the user "root", type the following:
    If you want to set a password for MySQL access, please use of mysqladmin.
+
 
    To set the passwort "secret" for the user "root", type the following:
+
  \xampplite\mysql\bin\mysqladmin -u root password secret
    \xampplite\mysql\bin\mysqladmin -u root password secret
 
   
 
    After changing the password you'll have to reconfigure phpMyAdmin to use the
 
    new password, otherwise it won't be able to access the databases. To do that,
 
    open the file config.inc.php in \xampplite\phpmyadmin\ and edit the
 
    following lines:   
 
   
 
    $cfg['Servers'][$i]['user']            = 'root';  // MySQL user
 
    $cfg['Servers'][$i]['auth_type']      = 'http';  // HTTP authentificate
 
  
    So first the 'root' password is queried by the MySQL server, before phpMyAdmin
+
Have a lot of fun! Viel Spaß! Bonne Chance!
    may access.
 
     
 
 
 
  
Have a lot of fun! Viel Spaß! Bonne Chance!
+
==If you are  installing Moodle complete install package under Windows 7==
 +
* Check [[Errors_FAQ#Check_if_you_need_to_increase_Apache.E2.80.99s_default_stack_size|if you need to increase Apache's default stack size]]
  
 
==See also==
 
==See also==
*[[Administrator_documentation]] for links that help configure Moodle.
+
 
*[[Installation guide - Moodle for Windows on a USB Memory Stick]]
+
*[https://docs.moodle.org/19/en/Installation_guide_-_Moodle_for_Windows_on_a_USB_Memory_Stick Installation guide - Moodle 1.9 for Windows on a USB Memory Stick]
 
*Return to [[Windows installation]]
 
*Return to [[Windows installation]]
 
*[[Windows 1 computer many servers |Multiple web servers, on 1 computer]] similar to windows installation page, with some tips
 
*[[Windows 1 computer many servers |Multiple web servers, on 1 computer]] similar to windows installation page, with some tips
 
*[https://docs.moodle.org/en/Windows_installation_using_XAMPP#Troubleshooting Troubleshooting]if you are running Skype.  
 
*[https://docs.moodle.org/en/Windows_installation_using_XAMPP#Troubleshooting Troubleshooting]if you are running Skype.  
*[[Installing_AMP]] lots of XAMPP stuff.  XAMPP stands for XP, Apache, MySQL,PHP and Perl.  XAMPPlite does not include Perl. MAMP stands for Mac, Apache, MySQL and PHP.   
+
*[[Installing_AMP]] lots of XAMPP stuff.  XAMPP stands for X (cross platform), Apache, MySQL,PHP and Perl.  XAMPP used in Moodle does not include Perl. MAMP stands for Mac, Apache, MySQL and PHP.   
*[[Complete Install Packages for Mac OS X]]  
+
*[[Installation Package for OS X]]  
 
 
  
[[es:Paquetes_para_Instalaci%C3%B3n_Completa]]
+
[[es:Paquetes para Instalación Completa para Windows]]
 
[[pl:Kompletne pakiety instalacyjne]]
 
[[pl:Kompletne pakiety instalacyjne]]
 +
[[de:Vollständiges Installationspaket für Windows]]
  
[[Category:Administrator]]
 
 
[[Category:Installation]]
 
[[Category:Installation]]
 +
[[Category:Windows]]

Latest revision as of 11:01, 2 February 2019

Complete install packages are available from Moodle.org's Windows download page and also from Bitnami stacks. The packages are designed for new installations on a standalone computer. All them use the popular XAMPP Apache Friends packages. The complete install package can be used on a server, but it is not recommended that it be used as a production site. Please note Moodle.org's Standard install packages only contain the Moodle code.

This document provides instructions for using the Windows packages. Separate instructions are available for Mac OS X packages.

The complete install packages allow Moodle to be installed, along with the prerequisites that includes a web server, Apache, database, MySQL, scripting language, PHP and Moodle all wrapped in the Xampp-lite shell. Several versions of the complete install package are available. The instructions on the download page provide guidance on which version is likely to be most suitable.

In short, complete install packages are designed to create a matched webserver and Moodle site on a standalone computer with minimal effort.

System requirements

  • 256 MB RAM (minimum), 1GB RAM (recommended)
  • 500 MB free Fixed Disk (more space will be needed depending on user uploads)
  • For old versions of Moodle:
    • Windows 98/ME (minimum)
    • Windows NT/2000/XP/2003 (recommended)
  • For Moodle 3.1 and later versions:
    • Windows Vista/7/8/10/2008/2012
    • Microsoft Visual C++ 2015 Redistributable package is required for PHP (download link). This must be the vc_redist.x86.exe download as the PHP build is 32-bit.

Port 80 Conflict if Skype is already installed

As the Moodle Windows package uses the same port (80) as Skype does, it will not work if the computer has Skype already installed.

The fix is very simple: Exit Skype (don't just close the window), then start the Moodle Windows package. Once Moodle for Windows is running, it should be safe to start Skype again. If the local Moodle is using the port 80, Skype will automatically select a different port when it is run.

Vista and Windows 7/8/10

Packages generated for Moodle 3.1 and later versions should work with Vista/7/8/10 out of the box. They include PHP 7 and MariaDB instead of MySQL, resulting in a smoother experience than previous versions of the packages.

If you have Windows 7, you must check if you need to increase Apache default stack size.

People facing problems with the new packages are advised to:

  • Check the PC with a good antivirus. Be very cautious when choosing a free/paid Windows antivirus. Good places to look for are old, reliable, solid PC magazines and old, reliable, solid PC blogs. Beware of many malicious malware programs posing as antivirus solutions! Google for any chosen solution before installing it.
  • Check the problem text: If it says that the connection was reset, read this documentation page for diagnosis and fix.
  • Read the Requirements and Troubleshooting information, both here and in the package's README.txt file.
  • Report any consistent problem in the Moodle Tracker, so it can be investigated and, hopefully, fixed.
  • Consider installing a virtual machine (eg, VirtualBox) with a windows or linux LAMP stack and then install Moodle there.
  • Switch to:
  • Use other Moodle-ready alternatives out there.

Install complete package process

The complete install package is a zip file that contains a webserver called Apache, plus Moodle and Moodle's required MySQL database and PHP program.

There are three basic parts to the this install process.

  1. Download and unpack the complete install package.
  2. Start the webserver.
  3. Install Moodle using a web browser.

First create file structure

Download the package

Download Windows packed-zip file from Moodle.

Unpack the package

Unpack (extract files by clicking on) the zip file you downloaded to a drive or partition of your choice. The extract process will create three files ("Start Moodle", "Stop Moodle", and "README") and a subfolder called "server".

  • Do NOT rename the "server" subfolder
Note: There will also be a folder under this server subfolder, called \moodle that holds the Moodle program.
TIP: Create a folder and extract the files there. For example, you might have one folder called Moodle254 and another one called Moodle281 for different versions or purposes.
TIP: Make path to "server" subfolder simple. Best way if it will be in drive root. Like "D:\moodle281\server". A long path, especially with any strange symbols, can prevent XAMPP from working properly.
NOTE: If you will be installing a server with a language other than English, the install process will need to download the corresponding language pack, which will take some time, and you will likely get a script timeout error. To prevent this, you will need to edit the server/php/php.ini file and change the line that has 'max_execution_time = 30' into 'max_execution_time = 600'.

Second - start the webserver

Now you are ready to start the webserver. Use the "Start Moodle.exe" file which you should find in the top directory. Once the "Start Moodle.exe" program is open, don't close it; use "Stop Moodle.exe" for that purpose.

Note: These programs control both Apache and MySQL programs that operate the webserver. Some sites will individually start and stop Apache and MySQL with the Xampp bat files found in the "server" subfolder.
Tip: Alternatively, on a standalone computer with several potential webservers that might be running, you can use the "xampp_restart.exe" file in the "server" subfolder.
Tip: You can also add shortcuts to the commands that start and stop the site in your Windows "start" menu.

Now you are ready to start the Moodle installation.

Warning: Windows XP requires the msvcr71.dll library file in order to run Xampp. Installing the .Net 1.1 framework (not .Net 2.0 and upper) could resolve it. You can also search for the file on Google, download it and copy it into the server/apache/bin folder.

Third - start Moodle installation

Start your web browser and type localhost, or http://127.0.0.1 or http://localhost in the address bar. You will either start your first time Moodle installation or if it is already installed you will enter the Moodle site's Front Page or Login screen.

A browser's addressbar showing "localhost". Click on the green Goto arrow will go to the installed Moodle site.
Tip: After Moodle installs, put the site in your "favorites" or as a "bookmark" in you browser.

Set language

The initial install page will be displayed after you type "localhost".

Set initial language
  • Choose your preferred language (English is used in this example) and click the “Next” button.

Diagnostic results

A diagnostic report is displayed – hopefully it will look like this, if not you may need to address some issues.

Moodle liked and gave a Pass


  • Click the “Next” button to continue.

Moodle paths

The paths for your Moodle installation are shown – if you are only using this as a local testing server, accept the ones that are shown on your screen.

What you enter in the "Web Address" field depends on what you intend to use the new Moodle installation for. If you are just going to use it for local testing, then use 'http://localhost'. If you are going to test the new installation on a LAN, and will be accessing it from other machines on that LAN, then put the private IP address or network name of the serving machine, followed by a forward slash and moodle: Web Address - http://192.168.1.1/moodle If you are going to test the installation on the internet, then you will need to put the public ip address followed by a forward slash and moodle: http://your_ip_address/moodle or you can put your domain name here instead.

Installation paths
  • Click the “Next” button to continue.

Database configuration

  • In the next fields, we enter the database settings. The fields are populated with some suggested values.
  • We strongly recommend you place a user name and password in this screen. (Don't forget them).
  • DO NOT USE THE “ROOT” USER WITHOUT A PASSWORD FOR PRODUCTION INSTALLATIONS AS THIS CREATES A SECURITY VULNERABILITY
Installation's database settings
  • When the fields have been populated, click the “Next” button to continue.

Check server

The install process checks the server is installed. All the checks should pass as far as the system requirements have been fulfilled.

Check server environment screen
  • Click the “Next” button to continue.

Confirm initial language pack

Moodle will now check to see if the language pack is available for the language you selected at the first step. If it is not, Moodle will continue with the install in English.

Language pack check

Confirm config.php

Provided the Moodle folder is writable, a message confirming the configuration has been completed will be displayed.

Confirmation that config.php has been created
  • Click the “ Continue” button to proceed.

Moodle copyright & agreement

The Moodle copyright / license notices are displayed.

Copyright notice and agreement
  • Click the “Yes” button to continue.

Current release and unattended option

The current release information is shown. Check off the unattended operations box. This will automatically advance through many screens. If you would like to watch the install screen by screen, do not check this box and be prepared to press the "continute button" many times.

  • Click the "Continue" button and wait.
Current release and "unattended" check box

Installation modules and blocks screens

In most cases this will be followed by a series of screens that have a continue button on the bottom. This process stops with Admin user profile settings which needs to be filled out.

Administrator user profile

The administrator's users profile screen

Fill out the required fields.

  • Click on "Save" to continue

Front page settings

The next screen is the Front Page settings page. There are two parts to it. The first part will ask for your Full site name and a short name for the navigation bar. There is also a place for a description. You can change these later.

The Moodle sites Front Page information

The second part on the bottom instructs Moodle if you will disable the new user self authentication through email process. The default is to disable. This can be changed later in the site administration block.

Determine if users can create their own profiles when they log onto the side via email self authentication
  • Click on "Save changes" button to go to Moodle sites home page.

Moodle on

Now you are ready to Moodle !

Blank Front page of your new site

The Site Administration block is on the left, the "Turn edit on" button in the upper right corner, withe the site description block just below it.

Congratulations - Moodle has been installed

This finishes the installation of a complete package. Type http://localhost (or what ever you set for web address earlier in the setup!) in your browser and Moodle will open.

Your next task will be to configure Moodle to meet your needs. Don't worry, it is easy to change any of the settings now that Moodle is up and running.

  • Check Settings > Site administration for further links.

More tips and cautions

  • For installation on a Windows 2000 or Windows 2003 production server it is good practice to perform a manual install (see the manual installation section in Windows Installation).
  • After installing the Windows package, you may wish to add additional contributed modules and plugins. These may involve more customization of configuration files.
  • The latest complete install package version components, may not be backwardly compatible. Always check version compatibility of each component if you intend to develop materials on a later version of Moodle than the version installed on your "main" Moodle site. In short, complete install packages are designed for first time install on a "clean" machine.

Security matters (A MUST READ!)

As mentioned before, XAMPP is not meant for production use but only for developers in a development environment. The way XAMPP is configured is to be open as possible and allowing the developer anything he/she wants. For development environments this is great but in a production environment it could be fatal. Here a list of missing security in XAMPP:

The MySQL administrator (root) has no password. The MySQL daemon is accessible via network. Examples are accessible via network.

To fix most of the security weaknesses simply call the following URL:

http://localhost/security/

The root password for MySQL and also a XAMPP directory protection can be established here.

Note that on the Windows installer package, some (all?) of these issues have been fixed already by default and the above link does not work.

If in doubt, more info is here

Apache and MySQL tweaks

Most of the time it is not necessary to tweak Apache or MySQL after completing the complete install package. Nor is it necessary to individually start and stop them because that is what the Xampp_start, Xampp_restart and Xammp_stop files are for.


Installing Apache and MySQL as services

(This is only for NT4 | Windows 2000 | Windows XP operating systems)

\xampplite\apache\apache_installservice.bat = ==> Install Apache 2 as service

\xampplite\apache\apache_uninstallservice.bat = ==> Uninstall Apache 2 as service

\xampplite\mysql\mysql_installservice.bat = ==> Install MySQL as service

\xampplite\mysql\mysql_uninstallservice.bat = ==> Uninstall MySQL as service

==> After all Service (un)installations, please restart your system!


Apache Notes

You can use the apache_start and apache_stop bat files to start and stop apache from running. However the Xampp_start or Xampp_restart and Xampp_stop is recommended to turn on/off both Apache and MySQL.

Troubleshooting

If you find that Apache is very flaky, with the page often not loading properly or even at all (especially on localhost), try adding these lines to the end of C:\your_moodle_installer_directory\apache\conf\httpd.conf

 EnableSendfile Off
 EnableMMAP Off
 Win32DisableAcceptEx

If You edit some .php files but browser still show old state of them, try to disable eAccelerator extension in \server\php\php.ini

[eAccelerator]
;extension=eaccelerator.dll

MySQL notes

Again, the recommendation to start and stop the entire webserver is to use the xampp_start or Xampp_restart and the Xampp_stop. The following maybe useful if you wish to tweak the system further. Please be careful.

(1) The MySQL server can be started by double-clicking (executing) mysql_start.bat. This file can be found in the same folder you installed xampp in, most likely this will be C:\xampplite\. The exact path to this file is X:\xampplite\mysql_start.bat, where "X" indicates the letter of the drive you unpacked xampp into.This batch file starts the MySQL server in console mode. The first intialization might take a few minutes.

Do not close the DOS window or you'll crash the server! To stop the server, please use mysql_shutdown.bat, which is located in the same directory.

(2) To use the MySQL Daemon with "innodb" for better performance, please edit the "my" (or "my.cnf") file in the /xampplite/mysql/bin directory or for services the c:\my.cnf for windows NT/2000/XP. In that director, activate the

"innodb_data_file_path=ibdata1:30M"

statement. Attention, "innodb" is not recommended for 95/98/ME.

To use MySQL as Service for NT/2000/XP, simply copy the "my" / "my.cnf" file to C:\my, or C:\my.cnf. Please note that this file has to be placed in C:\ (root), other locations are not permitted. Then execute the "mysql_installservice.bat" in the mysql folder.


(3) MySQL starts with standard values for the user id and the password. The preset user id is "root", the password is "" (= no password). To access MySQL via PHP with the preset values, you'll have to use the following syntax:

mysql_connect("localhost","root","");

If you want to set a password for MySQL access, please use of mysqladmin. To set the password "secret" for the user "root", type the following:

 \xampplite\mysql\bin\mysqladmin -u root password secret

Have a lot of fun! Viel Spaß! Bonne Chance!

If you are installing Moodle complete install package under Windows 7

See also