Note: You are currently viewing documentation for Moodle 2.0. Up-to-date documentation for the latest stable version is available here: Upgrading to Moodle 2.0.

Upgrading to Moodle 2.0: Difference between revisions

From MoodleDocs
(Detailed instructions applied only to Windows installations - hence confusing)
m (Just moving some elements)
Line 6: Line 6:
==System requirements==
==System requirements==


* It's a good idea to read the [[Latest release notes]] and the [[Moodle 2.0 release notes]]
* PHP must be '''5.2.8 or later''' although the latest 5.3.x is better if you have a choice.  
* PHP must be '''5.2.8 or later''' although the latest 5.3.x is better if you have a choice.  
* Databases should be one of the following:
* Databases should be one of the following:
Line 24: Line 23:
'''NOTE''': The upgrade process will irreversibly modify the contents of your database '''and''' your moodledata file storage area. If something goes wrong you '''cannot''' go back. It is vital that you take good backups of both moodledata and the database in case you have problems with the upgrade. If you are not sure how see [[Site backup]] or ask in the moodle.org forums (explaining what your operating system is).   
'''NOTE''': The upgrade process will irreversibly modify the contents of your database '''and''' your moodledata file storage area. If something goes wrong you '''cannot''' go back. It is vital that you take good backups of both moodledata and the database in case you have problems with the upgrade. If you are not sure how see [[Site backup]] or ask in the moodle.org forums (explaining what your operating system is).   


* It's a good idea to read the [[Latest release notes]] and the [[Moodle 2.0 release notes]]
* Always check your site to make sure it meets all system requirements for 2.0 in ''Administration > Server > [[Environment]]''
* Always check your site to make sure it meets all system requirements for 2.0 in ''Administration > Server > [[Environment]]''
* '''Do a full database backup!'''
* '''Do a full database backup!'''
Line 45: Line 45:


Moodle 2.0 supports running the [[CLI|upgrade from the command line]], rather than through a web browser. This is likely to be more reliable, particularly for large sites.
Moodle 2.0 supports running the [[CLI|upgrade from the command line]], rather than through a web browser. This is likely to be more reliable, particularly for large sites.
Note, if you get a strange error about 'handling of PHP float numbers', please see [[Installation_FAQ#Moodle_claims_PHP_float_handling_is_not_compatible|this FAQ entry]].


== Known and Discovered Issues ==
== Known and Discovered Issues ==


* Note, if you get a strange error about 'handling of PHP float numbers', please see [[Installation_FAQ#Moodle_claims_PHP_float_handling_is_not_compatible|this FAQ entry]].
* You now need some additional PHP modules installed (e.g. intl and the zip extension). If you do not have these, installation depends entirely on how your PHP was first installed and your operating system.
* You now need some additional PHP modules installed (e.g. intl and the zip extension). If you do not have these, installation depends entirely on how your PHP was first installed and your operating system.



Revision as of 10:20, 17 January 2011

Template:Moodle 2.0When upgrading to Moodle 2.0, you must have Moodle 1.9 or later. if you are using an earlier version of Moodle (eg 1.8.x) then you need to upgrade to Moodle 1.9.x first.

We advise that you test the upgrade first on a COPY of your production site, to make sure it works as you expect. Moodle 2.0 is a substantial upgrade and may require more planning and testing than you have become accustomed to in prior upgrades. Please read this page carefully before proceeding.


System requirements

  • PHP must be 5.2.8 or later although the latest 5.3.x is better if you have a choice.
  • Databases should be one of the following:
    • MySQL 5.0.25 or later (InnoDB storage engine highly recommended)
    • PostgreSQL 8.3 or later
    • Oracle 10.2 or later
    • MS SQL 2005 or later
  • Any standards-supporting browser from the past few years, for example:

Before upgrading please...

NOTE: The upgrade process will irreversibly modify the contents of your database and your moodledata file storage area. If something goes wrong you cannot go back. It is vital that you take good backups of both moodledata and the database in case you have problems with the upgrade. If you are not sure how see Site backup or ask in the moodle.org forums (explaining what your operating system is).

  • It's a good idea to read the Latest release notes and the Moodle 2.0 release notes
  • Always check your site to make sure it meets all system requirements for 2.0 in Administration > Server > Environment
  • Do a full database backup!
  • Do a full moodledata backup
  • Check your backups carefully
  • Remember to purge PHP cache if using any PHP accelerator

A word about optional plugins and themes

If you have added optional or customised plugins (whether your own custom developments or from the plugins and modules database) or are using a non-core theme you must note that these will not work in Moodle 2.0+. While some plugins have been modified to work in Moodle 2.0+ at the time of writing most have not. The themes system is completely different in 2.0+ and all custom themes will require a complete rewrite.

Do not try to include any (old 1.9) optional plugins and themes in your Moodle 2.0 - it won't work. You should check to see if a 2.0 version is available. If not, you can safely ignore the message that the code is missing for the plugin during the upgrade. You will loose the functionality but the database tables will be retained (dormant) in case a 2.0 version of the plugin is produced in the future.

Checking database schema - old sites

If your 1.9 Moodle site has been upgraded through many prior versions it is quite likely that there will be some problems with the database schema (compared to a fresh 1.9 installation). This may cause the upgrade to fail. If your site started life prior to Moodle 1.9 it is a very good idea to check and correct the database schema before upgrading. See Verify Database Schema

Now upgrade

Once you have satisfied the requirements for Moodle 2.0, follow the instructions on the upgrading page.

Moodle 2.0 supports running the upgrade from the command line, rather than through a web browser. This is likely to be more reliable, particularly for large sites.

Known and Discovered Issues

  • Note, if you get a strange error about 'handling of PHP float numbers', please see this FAQ entry.
  • You now need some additional PHP modules installed (e.g. intl and the zip extension). If you do not have these, installation depends entirely on how your PHP was first installed and your operating system.

See also