<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ca">
	<id>https://docs.moodle.org/2x/ca/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=ColinFraser</id>
	<title>MoodleDocs - Contribucions de l&amp;#039;usuari [ca]</title>
	<link rel="self" type="application/atom+xml" href="https://docs.moodle.org/2x/ca/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=ColinFraser"/>
	<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/Especial:Contribucions/ColinFraser"/>
	<updated>2026-04-25T10:24:11Z</updated>
	<subtitle>Contribucions de l&amp;#039;usuari</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104402</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104402"/>
		<updated>2013-05-10T10:45:06Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and have their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will restore courses and User data &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.x?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.x(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have used a number of Blocks in v1.9.xxx, can we use them in v2.x?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
In any event, if you chose to continue, make a note of all messages as they arise. You may want to investigate them later, just to make sure you know what they are and they are not going to come back and bite you later.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104401</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104401"/>
		<updated>2013-05-10T10:43:03Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Do I try to upgrade to Moodle 2.0 or just create a new install? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and have their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will retore courses and User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.x?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.x(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have used a number of Blocks in v1.9.xxx, can we use them in v2.x?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
In any event, if you chose to continue, make a note of all messages as they arise. You may want to investigate them later, just to make sure you know what they are and they are not going to come back and bite you later.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104400</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104400"/>
		<updated>2013-05-10T10:42:02Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How do I look up the error logs in Moodle 2.0? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and have their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will retore courses and User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.x?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.x(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have used a number of Blocks in v1.9.xxx, can we use them in v2.x?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
In any event, if you chose to continue, make a note of all messages as they arise. You may want to investigate them later, just to make sure you know what they are and they are not going to come back and bite you later.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104399</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104399"/>
		<updated>2013-05-10T10:41:10Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and have their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will retore courses and User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have used a number of Blocks in v1.9.xxx, can we use them in v2.x?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
In any event, if you chose to continue, make a note of all messages as they arise. You may want to investigate them later, just to make sure you know what they are and they are not going to come back and bite you later.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104383</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104383"/>
		<updated>2013-05-09T09:40:27Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* I am getting error messages about plugins and the installation stops when upgrading. What do I do? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will retore courses and User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have used a number of Blocks in v1.9.xxx, can we use them in v2.x?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
In any event, if you chose to continue, make a note of all messages as they arise. You may want to investigate them later, just to make sure you know what they are and they are not going to come back and bite you later.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104382</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104382"/>
		<updated>2013-05-09T09:37:25Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* That is OK for the Book, but what about other plugins and blocks? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will retore courses and User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have used a number of Blocks in v1.9.xxx, can we use them in v2.x?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104381</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104381"/>
		<updated>2013-05-09T09:35:10Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will retore courses and User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104380</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104380"/>
		<updated>2013-05-09T09:33:53Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will retore courses and User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT restore courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104379</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104379"/>
		<updated>2013-05-09T09:33:25Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.2 will update User data &lt;br /&gt;
: &#039;&#039;&#039;UPDATE&#039;&#039;&#039; Moodle v2.4 will NOT update courses or User Data from any v1.9.xxx or earlier. It is recommended that you install a v2.2.x and use that as a staging point.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104378</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104378"/>
		<updated>2013-05-09T09:28:50Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* See Also */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; This FAQ is being wound down, much of the information here is now duplicated elsewhere or is being moved into more appropriate places. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not been changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2.x [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In the theme/themename folder you will also find the sub-folders for different elements. You should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that encrypted password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
*[[:Category:FAQ | List of FAQ Pages]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104377</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104377"/>
		<updated>2013-05-09T09:28:18Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* See Also */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; This FAQ is being wound down, much of the information here is now duplicated elsewhere or is being moved into more appropriate places. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not been changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2.x [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In the theme/themename folder you will also find the sub-folders for different elements. You should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that encrypted password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
*[[:Category:FAQ | List of FAQ Pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104376</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104376"/>
		<updated>2013-05-09T09:27:39Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* See Also */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; This FAQ is being wound down, much of the information here is now duplicated elsewhere or is being moved into more appropriate places. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not been changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2.x [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In the theme/themename folder you will also find the sub-folders for different elements. You should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that encrypted password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
*[[Category:FAQ | List of FAQ Pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104375</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104375"/>
		<updated>2013-05-09T09:25:37Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; This FAQ is being wound down, much of the information here is now duplicated elsewhere or is being moved into more appropriate places. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not been changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2.x [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In the theme/themename folder you will also find the sub-folders for different elements. You should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that encrypted password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104130</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104130"/>
		<updated>2013-04-23T12:52:08Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104129</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104129"/>
		<updated>2013-04-23T12:51:01Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How do I create a repository? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104128</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104128"/>
		<updated>2013-04-23T12:48:04Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How can I extract original files from a Moodle backup file? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.x, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104127</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104127"/>
		<updated>2013-04-23T12:47:29Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How can I extract original files from a Moodle backup file? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking.&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the time period specified in &#039;Skip courses not modified&#039; in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; &amp;gt; Courses &amp;gt; Backups &amp;gt; Automated backup setup&#039;&#039; (by default 30 days).&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# The target site has a user xxxx (xxxx being the username)&lt;br /&gt;
# The backup archive being restored also contains a user xxxx (same username)&lt;br /&gt;
# After various comparisons, Moodle has determined that the target site user xxxx and the backup user xxxx aren&#039;t the same person.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 are all true, the restore process stops in order to prevent the backup user xxxx&#039;s activities (forum posts, quiz attempts, assignment uploads, etc) from being associated with the target site user xxxx. &lt;br /&gt;
&lt;br /&gt;
These checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. It&#039;s common for the user in question to be the &amp;quot;admin&amp;quot; user (which exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible methods to make the xxxx users match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup archive &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match the ones in backup archive users.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and all activities in the backup file belonging to xxxx will be associated to the already existing target site user xxxx user.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. &lt;br /&gt;
  When editing is complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
==I have a very large course, over 2GB, and the backup process stops.==&lt;br /&gt;
&lt;br /&gt;
Larger courses can be restored in Moodle, but sometimes it needs a bit of tweaking to get it right. Moodle backup files are *.mbz fies and can be renamed to zip files. They can be unzipped, then edited, rezipped and restored. It does not matter if you are using a Linux or Windows or Mac server, a local host or anything else, the technique is the same. &lt;br /&gt;
&lt;br /&gt;
The editing comes in two different ways, one is the resources, activities, quizzes, images. video files and so on are listed, written and referred to in the moodle.xml file. You can find the starting point and the end point of each resouce that you can delete out of the xml file. &lt;br /&gt;
&lt;br /&gt;
The xml might look something like this:&lt;br /&gt;
  &amp;lt;file id=&amp;quot;111&amp;quot;&amp;gt;    &amp;lt;contenthash&amp;gt;b11ac9bc0cebee17acfd28d13b548331f76645bc&amp;lt;/contenthash&amp;gt;&lt;br /&gt;
    &amp;lt;contextid&amp;gt;21&amp;lt;/contextid&amp;gt;&lt;br /&gt;
    &amp;lt;component&amp;gt;mod_resource&amp;lt;/component&amp;gt;&lt;br /&gt;
    &amp;lt;filearea&amp;gt;content&amp;lt;/filearea&amp;gt;&lt;br /&gt;
    &amp;lt;itemid&amp;gt;0&amp;lt;/itemid&amp;gt;&lt;br /&gt;
    &amp;lt;filepath&amp;gt;/&amp;lt;/filepath&amp;gt;&lt;br /&gt;
    &amp;lt;filename&amp;gt;howtomakeatimemachine.flv&amp;lt;/filename&amp;gt;&lt;br /&gt;
    &amp;lt;userid&amp;gt;4&amp;lt;/userid&amp;gt;&lt;br /&gt;
    &amp;lt;filesize&amp;gt;1092320586557&amp;lt;/filesize&amp;gt;&lt;br /&gt;
    &amp;lt;mimetype&amp;gt;video/flv&amp;lt;/mimetype&amp;gt;&lt;br /&gt;
    &amp;lt;status&amp;gt;0&amp;lt;/status&amp;gt;&lt;br /&gt;
    &amp;lt;timecreated&amp;gt;12345432123&amp;lt;/timecreated&amp;gt;&lt;br /&gt;
    &amp;lt;timemodified&amp;gt;12345432123&amp;lt;/timemodified&amp;gt;&lt;br /&gt;
    &amp;lt;source&amp;gt;howtomakeatimemachine.flv&amp;lt;/source&amp;gt;&lt;br /&gt;
    &amp;lt;author&amp;gt;Fred Nurks&amp;lt;/author&amp;gt;&lt;br /&gt;
    &amp;lt;license&amp;gt;allrightsreserved&amp;lt;/license&amp;gt;&lt;br /&gt;
    &amp;lt;sortorder&amp;gt;0&amp;lt;/sortorder&amp;gt;&lt;br /&gt;
    &amp;lt;repositorytype&amp;gt;$@NULL@$&amp;lt;/repositorytype&amp;gt;&lt;br /&gt;
    &amp;lt;repositoryid&amp;gt;$@NULL@$&amp;lt;/repositoryid&amp;gt;&lt;br /&gt;
    &amp;lt;reference&amp;gt;$@NULL@$&amp;lt;/reference&amp;gt;&lt;br /&gt;
  &amp;lt;/file&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When editing, make sure all this is deleted, everything between the &amp;lt;file&amp;gt;&amp;lt;/file&amp;gt; tags.&lt;br /&gt;
&lt;br /&gt;
The second part of editing is locating the actual resouce if it is an image, a separate file or video then deleting it. Really large mbz files tend to have a lot of videos, often flv files, or uncompressed images, like tiffs. They can be found, and deleted easily, in the directory tree of the backup.&lt;br /&gt;
&lt;br /&gt;
You can then rezip the edited file, rename it to an mbz and, if you have edited it right, it should restore. You can use the original file to break down really large backups over and over into four or five smaller mbz files, as many as you like.&lt;br /&gt;
&lt;br /&gt;
It is recommended that you test the technique first on a smaller file, it is easier to follow and gets you used to xml structuring and so on. Say one course with a couple of pages, a number of different image types, a couple of videos will help you immensely.  &lt;br /&gt;
&lt;br /&gt;
You do not have to worry about permissions in Windows or Xos servers, or concern yourself with editing rights usually. However, you may be required to ensure you are the owner fo the files being edited.&lt;br /&gt;
  &lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Before re-zipping, check to make sure you have removed all references to the pages/files/resources you have deleted in the moodle-backup.xml file as well. here msay be none, but check anyway.&lt;br /&gt;
&lt;br /&gt;
==How can I extract original files from a Moodle backup file?==&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), you can do so in much the same way as is suggested above. &lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104126</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104126"/>
		<updated>2013-04-23T12:47:01Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* I have a very large course, over 2GB, and the backup process stops. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking.&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the time period specified in &#039;Skip courses not modified&#039; in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; &amp;gt; Courses &amp;gt; Backups &amp;gt; Automated backup setup&#039;&#039; (by default 30 days).&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# The target site has a user xxxx (xxxx being the username)&lt;br /&gt;
# The backup archive being restored also contains a user xxxx (same username)&lt;br /&gt;
# After various comparisons, Moodle has determined that the target site user xxxx and the backup user xxxx aren&#039;t the same person.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 are all true, the restore process stops in order to prevent the backup user xxxx&#039;s activities (forum posts, quiz attempts, assignment uploads, etc) from being associated with the target site user xxxx. &lt;br /&gt;
&lt;br /&gt;
These checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. It&#039;s common for the user in question to be the &amp;quot;admin&amp;quot; user (which exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible methods to make the xxxx users match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup archive &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match the ones in backup archive users.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and all activities in the backup file belonging to xxxx will be associated to the already existing target site user xxxx user.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. &lt;br /&gt;
  When editing is complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
==I have a very large course, over 2GB, and the backup process stops.==&lt;br /&gt;
&lt;br /&gt;
Larger courses can be restored in Moodle, but sometimes it needs a bit of tweaking to get it right. Moodle backup files are *.mbz fies and can be renamed to zip files. They can be unzipped, then edited, rezipped and restored. It does not matter if you are using a Linux or Windows or Mac server, a local host or anything else, the technique is the same. &lt;br /&gt;
&lt;br /&gt;
The editing comes in two different ways, one is the resources, activities, quizzes, images. video files and so on are listed, written and referred to in the moodle.xml file. You can find the starting point and the end point of each resouce that you can delete out of the xml file. &lt;br /&gt;
&lt;br /&gt;
The xml might look something like this:&lt;br /&gt;
  &amp;lt;file id=&amp;quot;111&amp;quot;&amp;gt;    &amp;lt;contenthash&amp;gt;b11ac9bc0cebee17acfd28d13b548331f76645bc&amp;lt;/contenthash&amp;gt;&lt;br /&gt;
    &amp;lt;contextid&amp;gt;21&amp;lt;/contextid&amp;gt;&lt;br /&gt;
    &amp;lt;component&amp;gt;mod_resource&amp;lt;/component&amp;gt;&lt;br /&gt;
    &amp;lt;filearea&amp;gt;content&amp;lt;/filearea&amp;gt;&lt;br /&gt;
    &amp;lt;itemid&amp;gt;0&amp;lt;/itemid&amp;gt;&lt;br /&gt;
    &amp;lt;filepath&amp;gt;/&amp;lt;/filepath&amp;gt;&lt;br /&gt;
    &amp;lt;filename&amp;gt;howtomakeatimemachine.flv&amp;lt;/filename&amp;gt;&lt;br /&gt;
    &amp;lt;userid&amp;gt;4&amp;lt;/userid&amp;gt;&lt;br /&gt;
    &amp;lt;filesize&amp;gt;1092320586557&amp;lt;/filesize&amp;gt;&lt;br /&gt;
    &amp;lt;mimetype&amp;gt;video/flv&amp;lt;/mimetype&amp;gt;&lt;br /&gt;
    &amp;lt;status&amp;gt;0&amp;lt;/status&amp;gt;&lt;br /&gt;
    &amp;lt;timecreated&amp;gt;12345432123&amp;lt;/timecreated&amp;gt;&lt;br /&gt;
    &amp;lt;timemodified&amp;gt;12345432123&amp;lt;/timemodified&amp;gt;&lt;br /&gt;
    &amp;lt;source&amp;gt;howtomakeatimemachine.flv&amp;lt;/source&amp;gt;&lt;br /&gt;
    &amp;lt;author&amp;gt;Fred Nurks&amp;lt;/author&amp;gt;&lt;br /&gt;
    &amp;lt;license&amp;gt;allrightsreserved&amp;lt;/license&amp;gt;&lt;br /&gt;
    &amp;lt;sortorder&amp;gt;0&amp;lt;/sortorder&amp;gt;&lt;br /&gt;
    &amp;lt;repositorytype&amp;gt;$@NULL@$&amp;lt;/repositorytype&amp;gt;&lt;br /&gt;
    &amp;lt;repositoryid&amp;gt;$@NULL@$&amp;lt;/repositoryid&amp;gt;&lt;br /&gt;
    &amp;lt;reference&amp;gt;$@NULL@$&amp;lt;/reference&amp;gt;&lt;br /&gt;
  &amp;lt;/file&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When editing, make sure all this is deleted, everything between the &amp;lt;file&amp;gt;&amp;lt;/file&amp;gt; tags.&lt;br /&gt;
&lt;br /&gt;
The second part of editing is locating the actual resouce if it is an image, a separate file or video then deleting it. Really large mbz files tend to have a lot of videos, often flv files, or uncompressed images, like tiffs. They can be found, and deleted easily, in the directory tree of the backup.&lt;br /&gt;
&lt;br /&gt;
You can then rezip the edited file, rename it to an mbz and, if you have edited it right, it should restore. You can use the original file to break down really large backups over and over into four or five smaller mbz files, as many as you like.&lt;br /&gt;
&lt;br /&gt;
It is recommended that you test the technique first on a smaller file, it is easier to follow and gets you used to xml structuring and so on. Say one course with a couple of pages, a number of different image types, a couple of videos will help you immensely.  &lt;br /&gt;
&lt;br /&gt;
You do not have to worry about permissions in Windows or Xos servers, or concern yourself with editing rights usually. However, you may be required to ensure you are the owner fo the files being edited.&lt;br /&gt;
  &lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Before re-zipping, check to make sure you have removed all references to the pages/files/resources you have deleted in the moodle-backup.xml file as well. here msay be none, but check anyway.&lt;br /&gt;
&lt;br /&gt;
==How can I extract original files from a Moodle backup file?==&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), you can do so in much the same way as is suggested above. &lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104125</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104125"/>
		<updated>2013-04-23T12:41:03Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* I have a very large course, over 2GB, and the backup process stops. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking.&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the time period specified in &#039;Skip courses not modified&#039; in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; &amp;gt; Courses &amp;gt; Backups &amp;gt; Automated backup setup&#039;&#039; (by default 30 days).&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# The target site has a user xxxx (xxxx being the username)&lt;br /&gt;
# The backup archive being restored also contains a user xxxx (same username)&lt;br /&gt;
# After various comparisons, Moodle has determined that the target site user xxxx and the backup user xxxx aren&#039;t the same person.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 are all true, the restore process stops in order to prevent the backup user xxxx&#039;s activities (forum posts, quiz attempts, assignment uploads, etc) from being associated with the target site user xxxx. &lt;br /&gt;
&lt;br /&gt;
These checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. It&#039;s common for the user in question to be the &amp;quot;admin&amp;quot; user (which exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible methods to make the xxxx users match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup archive &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match the ones in backup archive users.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and all activities in the backup file belonging to xxxx will be associated to the already existing target site user xxxx user.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. &lt;br /&gt;
  When editing is complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
==I have a very large course, over 2GB, and the backup process stops.==&lt;br /&gt;
&lt;br /&gt;
Larger courses can be restored in Moodle, but sometimes it needs a bit of tweaking to get it right. Moodle backup files are *.mbz fies and can be renamed to zip files. They can be unzipped, then edited, rezipped and restored. It does not matter if you are using a Linux or Windows or Mac server, a local host or anything else, the technique is the same. &lt;br /&gt;
&lt;br /&gt;
The editing comes in two different ways, one is the resources, activities, quizzes, images. video files and so on are listed, written and referred to in the moodle.xml file. You can find the starting point and the end point of each resouce that you can delete out of the xml file. &lt;br /&gt;
&lt;br /&gt;
The xml might look something like this:&lt;br /&gt;
  &amp;lt;file id=&amp;quot;111&amp;quot;&amp;gt;    &amp;lt;contenthash&amp;gt;b11ac9bc0cebee17acfd28d13b548331f76645bc&amp;lt;/contenthash&amp;gt;&lt;br /&gt;
    &amp;lt;contextid&amp;gt;21&amp;lt;/contextid&amp;gt;&lt;br /&gt;
    &amp;lt;component&amp;gt;mod_resource&amp;lt;/component&amp;gt;&lt;br /&gt;
    &amp;lt;filearea&amp;gt;content&amp;lt;/filearea&amp;gt;&lt;br /&gt;
    &amp;lt;itemid&amp;gt;0&amp;lt;/itemid&amp;gt;&lt;br /&gt;
    &amp;lt;filepath&amp;gt;/&amp;lt;/filepath&amp;gt;&lt;br /&gt;
    &amp;lt;filename&amp;gt;howtomakeatimemachine.flv&amp;lt;/filename&amp;gt;&lt;br /&gt;
    &amp;lt;userid&amp;gt;4&amp;lt;/userid&amp;gt;&lt;br /&gt;
    &amp;lt;filesize&amp;gt;1092320586557&amp;lt;/filesize&amp;gt;&lt;br /&gt;
    &amp;lt;mimetype&amp;gt;video/flv&amp;lt;/mimetype&amp;gt;&lt;br /&gt;
    &amp;lt;status&amp;gt;0&amp;lt;/status&amp;gt;&lt;br /&gt;
    &amp;lt;timecreated&amp;gt;12345432123&amp;lt;/timecreated&amp;gt;&lt;br /&gt;
    &amp;lt;timemodified&amp;gt;12345432123&amp;lt;/timemodified&amp;gt;&lt;br /&gt;
    &amp;lt;source&amp;gt;howtomakeatimemachine.flv&amp;lt;/source&amp;gt;&lt;br /&gt;
    &amp;lt;author&amp;gt;Fred Nurks&amp;lt;/author&amp;gt;&lt;br /&gt;
    &amp;lt;license&amp;gt;allrightsreserved&amp;lt;/license&amp;gt;&lt;br /&gt;
    &amp;lt;sortorder&amp;gt;0&amp;lt;/sortorder&amp;gt;&lt;br /&gt;
    &amp;lt;repositorytype&amp;gt;$@NULL@$&amp;lt;/repositorytype&amp;gt;&lt;br /&gt;
    &amp;lt;repositoryid&amp;gt;$@NULL@$&amp;lt;/repositoryid&amp;gt;&lt;br /&gt;
    &amp;lt;reference&amp;gt;$@NULL@$&amp;lt;/reference&amp;gt;&lt;br /&gt;
  &amp;lt;/file&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When editing, make sure all this is deleted, everything between the &amp;lt;file&amp;gt;&amp;lt;/file&amp;gt; tags.&lt;br /&gt;
&lt;br /&gt;
The second part of editing is locating the actual resouce if it is an image, a separate file or video then deleting it. Really large mbz files tend to have a lot of videos, often flv files, or uncompressed images, like tiffs. They can be found, and deleted easily, in the directory tree of the backup.&lt;br /&gt;
&lt;br /&gt;
You can then rezip the edited file, rename it to an mbz and, if you have edited it right, it should restore. You can use the original file to break down really large backups over and over into four or five smaller mbz files, as many as you like.&lt;br /&gt;
&lt;br /&gt;
It is recommended that you test the technique first on a smaller file, it is easier to follow and gets you used to xml structuring and so on. Say one course with a couple of pages, a number of different image types, a couple of videos will help you immensely.  &lt;br /&gt;
&lt;br /&gt;
You do not have to worry about permissions in Windows or Xos servers, or concern yourself with editing rights usually. However, you may be required to ensure you are the owner fo the files being edited.&lt;br /&gt;
&lt;br /&gt;
==How can I extract original files from a Moodle backup file?==&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), you can do so in much the same way as is suggested above. &lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104124</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104124"/>
		<updated>2013-04-23T12:37:40Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How can I have two installations of Moodle on my server? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.x, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
===How can I extract original files from a Moodle backup file?===&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), here it goes...&lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Installation_FAQ&amp;diff=104123</id>
		<title>Installation FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Installation_FAQ&amp;diff=104123"/>
		<updated>2013-04-23T12:37:32Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How do I run multiple instances of Moodle without duplicating base code? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Installing Moodle}}&lt;br /&gt;
== System information needed for Installation problems forum ==&lt;br /&gt;
When posting questions to the [http://moodle.org/mod/forum/view.php?id=28 Installation problems forum], try to provide as much background information as possible about your Moodle system. Consider providing some or all of the following:&lt;br /&gt;
* Server Operating System name (version also if possible): &lt;br /&gt;
* PHP version (e.g. PHP 5.3.2)&lt;br /&gt;
* Database server type and version (e.g. MySQL 5.5.18)&lt;br /&gt;
* Browser and version (e.g. Internet Explorer 8):&lt;br /&gt;
* Moodle version (e.g. 2.1):&lt;br /&gt;
* Moodle install type? (New/Upgrade):&lt;br /&gt;
* Moodle config.php attached (please remove passwords):&lt;br /&gt;
* Phpinfo attached?:&lt;br /&gt;
&lt;br /&gt;
Make sure you provide a sensible description (never HELP! or URGENT!) and a full description of what you did and what happened. Copy and paste any error messages accurately in full. &#039;Nothing&#039; is not a symptom, even a blank page is something!&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==PHP - is it installed and what version do I have?==&lt;br /&gt;
&lt;br /&gt;
Make a new file on your web site called &#039;&#039;info.php&#039;&#039;, containing the following text, and call it from your browser:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code php&amp;gt;&lt;br /&gt;
&amp;lt;?PHP phpinfo() ?&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If nothing happens then you don&#039;t have PHP installed or your webserver is not configured to handle .php files properly. See the installation docs for some information about where to download it for your computer. See the [[phpinfo]] page for details about the content of this page.&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==What &amp;amp; where are Moodle&#039;s configuration settings stored?==&lt;br /&gt;
Configuration settings are stored in the config.php file stored in your moodle folder. This file is created during the installation process. If there is a problem and the installation cannot create the file, you can try creating it manually from the [[Configuration file]] docs. &lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==Downloading previous releases of Moodle==&lt;br /&gt;
It is possible to download previous versions of Moodle that are not found on the  [http://download.moodle.org Standard Moodle Download page].  There are zip and tgz compressed located at &amp;lt;nowiki&amp;gt;http://download.moodle.org/stable[version_number]&amp;lt;/nowiki&amp;gt; (see links below). &lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;width:75%; height:75px&amp;quot; border=&amp;quot;0&amp;quot;&lt;br /&gt;
|- &lt;br /&gt;
| 2.0 Versions || [http://download.moodle.org/stable19 1.9 Versions]  || [http://download.moodle.org/stable18 1.8 Versions] &lt;br /&gt;
|- &lt;br /&gt;
|[http://download.moodle.org/stable17 1.7 Versions] || [http://download.moodle.org/stable16 1.6 Versions] || [http://download.moodle.org/stable15/ 1.5 Versions] &lt;br /&gt;
|-&lt;br /&gt;
| [http://download.moodle.org/stable14 1.4 Versions] || [http://download.moodle.org/stable13 1.3 Versions]  || &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
You can download previous releases by using wget, lynx or curl with this URL:&lt;br /&gt;
&amp;lt;nowiki&amp;gt;http://download.moodle.org/stable[version_number]&amp;lt;/nowiki&amp;gt;. &lt;br /&gt;
:For example: to download Moodle version 1.5, use &amp;lt;nowiki&amp;gt;http://download.moodle.org/stable15&amp;lt;/nowiki&amp;gt;. You&#039;ll see a directory tree with the files displayed. Click on the one you want and download as normal - if you require the latest update of the version, scroll to the end of the list and download the &amp;quot;moodle-latest&amp;quot; file.&lt;br /&gt;
* &#039;&#039;&#039;Windows Packages&#039;&#039;&#039;: To download other releases not found in [http://download.moodle.org/windows/ Moodle packages for Windows], use this URL:&lt;br /&gt;
:&amp;lt;nowiki&amp;gt;http://download.moodle.org/windows/MoodleWindowsInstaller-latest-[version_number].zip&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Mac Packages&#039;&#039;&#039;: To download other releases not found in [http://download.moodle.org/macosx/ Mac packages], use either of these URLs (depending on whether you need the Intel or PPC package):&lt;br /&gt;
:&amp;lt;nowiki&amp;gt;http://download.moodle.org/macosx/Moodle4Mac-Intel-[version_number].dmg&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
:&amp;lt;nowiki&amp;gt;http://download.moodle.org/macosx/Moodle4Mac-PPC-[version_number}.dmg&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
== How to enable and check PHP error logs==&lt;br /&gt;
PHP can be set up to log errors in a variety of different ways: two of these involve the use of the php.ini file and the ini_set command.  See [[PHP error logs]].&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;Could not find a top level course&amp;quot; ==&lt;br /&gt;
If this appears immediately after you have attempted to install Moodle it almost certainly means that the installation did not complete. A complete installation will ask you for the administrator profile and to name the site just before it completes. Check your logs for errors. Then drop the database and start again. If you used the web-based installer try the command line one. Does your computer definitely have sufficient resource to run Moodle?&lt;br /&gt;
&lt;br /&gt;
==Email copies are not being sent from my forums==&lt;br /&gt;
&lt;br /&gt;
You &#039;&#039;must&#039;&#039; set up cron properly if you want Moodle to send out automatic email from forums, assignments etc. This same process also performs a number of clean-up tasks such as deleting old unconfirmed users, unenrolling old students and so on. Please refer to the [[Cron|cron instructions]].&lt;br /&gt;
&lt;br /&gt;
Tips:&lt;br /&gt;
* Try the default settings in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Plugins &amp;gt; Message outputs &amp;gt; Email&#039;&#039;. This generally works. Except...&lt;br /&gt;
* On a Windows server you *must* supply the address of an SMTP server (Windows, unlike Unix, does not have a build in mail server) in the above settings page&lt;br /&gt;
* Make sure that &#039;&#039;allowuseremailcharset&#039;&#039; in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Plugins &amp;gt; Message outputs &amp;gt; Email&#039;&#039; is set to No unless you really know what you are doing. Setting this to Yes can cause a problem in some versions of Moodle.&lt;br /&gt;
* Check your firewall or ask your network administrator. Many mail servers are heavily locked down and you may need permission to send mail through them.&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==I can&#039;t log in - I just stay stuck on the login screen==&lt;br /&gt;
&lt;br /&gt;
This may also apply if you are seeing  “Your session has timed out. Please login again” or &amp;quot;A server error that affects your login session was detected. Please login again or restart your browser&amp;quot; and cannot log in.&lt;br /&gt;
&lt;br /&gt;
The following are possible causes and actions you can take (in no particular order):&lt;br /&gt;
&lt;br /&gt;
* Check first that your main admin account (which will be a manual account) is also a problem. If your users are using an external authentication method (e.g. LDAP) that could be the problem. Isolate the fault and make sure it really is Moodle before going any further.&lt;br /&gt;
* Check that your hard disk is not full or if your server is on shared hosting check that you have not reached your disk space quota. This will prevent new sessions being created and nobody will be able to log in. &lt;br /&gt;
* Carefully check the permissions in your &#039;moodledata&#039; area. The web server needs to be able to write to the &#039;sessions&#039; subdirectory. &lt;br /&gt;
* Your own computer (not your Moodle server) may have a firewall that is stripping referrer information from the browser. Here are some instructions for fixing [http://service1.symantec.com/SUPPORT/nip.nsf/46f26a2d6dafb0a788256bc7005c3fa3/b9b47ad7eddd343b88256c6b006a85a8?OpenDocument&amp;amp;src=bar_sch_nam Norton firewall products].&lt;br /&gt;
* Try deleting the &#039;&#039;sessions&#039;&#039; folder in your moodledata directory (anybody currently logged in will be thrown out)&lt;br /&gt;
* Try deleting cookies on your computer and/or try another browser or another client computer&lt;br /&gt;
* In &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Server &amp;gt; Session Handling&#039;&#039;, try setting a value for &#039;Cookie prefix&#039;. You can also do this by setting &amp;lt;code&amp;gt;$CFG-&amp;gt;sessioncookie=&#039;something&#039;;&amp;lt;/code&amp;gt; in config.php. This is especially true if you are using multiple Moodles on the same browser. &lt;br /&gt;
* Make sure you have not removed or changed the [[Password salting|Password Salt]] value(s) in config.php. If passwords were created using a salt the correct salt must be in config.php for those passwords to continue to work. This is easily done if you recreate config.php while performing an upgrade and forget to transfer the salt values. &lt;br /&gt;
* Do you have a .htaccess file in your Moodle folder (or its parent directories). If so, is there anything in there that might be causing trouble (strange redirects, access restrictions etc.)?&lt;br /&gt;
* Check the value of &#039;&#039;&#039;mnet_localhost_id&#039;&#039;&#039; in the mdl_config database table. It&#039;s normally 1 but must match the &#039;&#039;&#039;mnet_hostid&#039;&#039;&#039; field in your user records in the mdl_user table for the user to be recognised. It can sometimes get changed spuriously during upgrades or site migrations. &lt;br /&gt;
* Check config.php - it should NOT have any spaces/new lines at the end of code.&lt;br /&gt;
* You are using the correct username and password, yes?&lt;br /&gt;
&lt;br /&gt;
If you are still having problems, read the [[Can_not_log_in | Cannot log in]] page. You &#039;&#039;&#039;could&#039;&#039;&#039; also try changing the admin password. Proceed as if you have lost it - see [[Administration FAQ]].&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==I log in but the login link doesn&#039;t change. I am logged in and can navigate freely.==&lt;br /&gt;
&lt;br /&gt;
Make sure the URL in your &amp;lt;code&amp;gt;$CFG-&amp;gt;wwwroot&amp;lt;/code&amp;gt; setting is exactly the same as the one you are actually using to access the site.&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
==Uploaded files give &amp;quot;File not found&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
For example: Not Found: The requested URL /moodle/file.php/2/myfile.jpg was not found on this server.&lt;br /&gt;
&lt;br /&gt;
Your web server needs to be configured to allow the part of the URL after a script name to be passed directly to the script. This is usually enabled in Apache 1, but is usually disabled by default in Apache 2. To turn it on, add this line to your &#039;&#039;httpd.conf&#039;&#039;, or to a &#039;&#039;.htaccess&#039;&#039; file in your local directory (see [[Installing Moodle]] for more details):&lt;br /&gt;
&lt;br /&gt;
 &#039;&#039;&#039;AcceptPathInfo&#039;&#039;&#039; on&lt;br /&gt;
&lt;br /&gt;
Note, this will ONLY work for Apache versions 2.x.&lt;br /&gt;
&lt;br /&gt;
For IIS you need to configure URL rewriting. This feature is not available in IIS 6 so you need to install a 3rd party IIS extension - see http://msdn.microsoft.com/en-us/library/ms972974.aspx. &lt;br /&gt;
&lt;br /&gt;
IIS 7 now comes with the new URL Rewrite Module so a 3rd part extension is no longer required if you are running IIS 7. See http://learn.iis.net/page.aspx/734/url-rewrite-module for more details.&lt;br /&gt;
&lt;br /&gt;
Once you&#039;ve got URL rewriting working the recommended rewriting rule is:&lt;br /&gt;
&lt;br /&gt;
 &#039;&#039;&#039;RewriteRule&#039;&#039;&#039; ^([^\?]+?\.php)(\/.+)$ $1\?file=$2 [QSA]&lt;br /&gt;
&lt;br /&gt;
In theory you could try to use path info on IIS too, but it is not reliable, especially when using unicode file names.&lt;br /&gt;
&lt;br /&gt;
If you are unable to configure your server properly then you can switch Moodle to use an alternative method. The major disadvantages is that you will not be able to use SCORM packages at all and some Adobe Flash and Java applets will not work either.&lt;br /&gt;
&lt;br /&gt;
To use this alternative method, you should change the &#039;&#039;slasharguments&#039;&#039; variable. For moodle versions &amp;lt; 1.7, this is located in the Operating System section of &#039;&#039;Administration &amp;gt; Configuration &amp;gt; [[admin/config|Variables]]&#039;&#039;. In later versions, this option is located in &#039;&#039;Site Administration &amp;gt; Server &amp;gt; HTTP&#039;&#039;. You should now be able to access your uploaded files.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;See also&#039;&#039;&#039;:&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/discuss.php?d=145422 Troubleshooting Guide - 404 Errors] forum discussion.&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==Why are all my pages blank?==&lt;br /&gt;
&lt;br /&gt;
Check the dirroot variable in &#039;&#039;config.php&#039;&#039;. You must use complete, absolute pathnames (e.g.)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code php&amp;gt;&lt;br /&gt;
$CFG-&amp;gt;dirroot = &amp;quot;/var/www/moodle&amp;quot;;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Another reason might be that PHP has not been configured to support MySQL (or whatever other database you are using). This is common on RedHat and OpenBSD installations. In this case, an error is generated, but since error displays are often disabled by default, all that is seen on the browser is a blank screen. To enable PHP error displays see [[Installation_FAQ#How_to_enable_and_check_PHP_error_logs | How to enable and check PHP error logs]].&lt;br /&gt;
&lt;br /&gt;
To determine if database support is your problem, insert this as the second line in your &#039;&#039;config.php&#039;&#039; file&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code php&amp;gt;&lt;br /&gt;
phpinfo();&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
then reload the web page. Examine the output closely to see if you chosen database is supported. If not, look for a package you are missing.&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
== Why is a particular page blank or incomplete? ==&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Check your web server log files!!&#039;&#039;&#039; &lt;br /&gt;
:If a particular page is blank or incomplete (it doesn&#039;t display the footer), before you do anything else switch on [[Debugging]] and  [[Installation_FAQ#How_to_enable_and_check_PHP_error_logs | check your PHP error logs]]. Having established that PHP error logging is working, reproduce the error. Immediately check the error log file right at the end. Hopefully you will see a PHP error message at or very near the end of the file. This may solve your problem directly or makes it a lot easier to diagnose the problem in the Moodle forums.&lt;br /&gt;
&lt;br /&gt;
*If you are &#039;&#039;&#039;upgrading to a new version of Moodle&#039;&#039;&#039;, check that you do not have an old version of a non-standard block or module installed. Remove any such blocks or modules installed using the admin settings page and start the install process again. However, do also make sure that you have included all optional plugins that were required by your courses. This is particularly common with &amp;quot;editing on&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
*If you &#039;&#039;&#039;do not see any blocks listed&#039;&#039;&#039;, turn editing on and remove any blocks that you have added to that page and try reloading.&lt;br /&gt;
&lt;br /&gt;
*You may get this error immediately after &#039;&#039;&#039;selecting a language&#039;&#039;&#039;. At this stage of the installation process your Moodle computer may need to connect to the Internet and download a language pack, so check that the computer can access the Internet by using a browser. Check also that your PHP settings are as given in the Moodle [[Installing_Moodle#Requirements | Moodle Requirements]] page.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;See also&#039;&#039;&#039;:&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/discuss.php?d=97734 PHP configuration error] forum discussion&lt;br /&gt;
&lt;br /&gt;
==Installation hangs when setting-up database tables==&lt;br /&gt;
Sometimes the installation will hang when setting up tables, where only half the page displayed in the browser and/or other outputs are removed.  You may see truncated MySQL statements, or the “Scroll to continue” link is displayed but no “Continue” button is there. &lt;br /&gt;
&lt;br /&gt;
See [[Unexpected installation halts]] for more about solutions that involve:&lt;br /&gt;
*Checking for MySQL limits&lt;br /&gt;
*Checking the .htaccess files &lt;br /&gt;
*Code customizations issues&lt;br /&gt;
*Checking memory limit &lt;br /&gt;
*Upgrade incrementally&lt;br /&gt;
*Fix fopen function&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==Why can&#039;t I upload a new image into my profile?==&lt;br /&gt;
&lt;br /&gt;
If you don&#039;t see anything on your user profile pages to let you upload user images then it&#039;s usually one of the following:&lt;br /&gt;
*The permissions associated with the role you are using are preventing you from changing your profile picture.&lt;br /&gt;
* GD is not installed, or is not enabled on your server. Make sure &#039;&#039;&#039;GD has been included in your PHP installation&#039;&#039;&#039;. You can check this by going to &#039;&#039;Site Administration &amp;gt; Server &amp;gt; PHP info&#039;&#039; and looking for the gdversion setting. This setting is chosen automatically every time you visit that page. If it shows GD version 1 or version 2 then everything should be fine. Save that configuration page and go back to your user profile.&lt;br /&gt;
* GD is installed, but is in some way corrupt. For instance, [http://moodle.org/mod/forum/discuss.php?d=44271#p386194 see this discussion on empty lines or white spaces in config files.]&lt;br /&gt;
GD is a library that allows image processing. For example, when all is well with your system, and you upload a new profile image, GD compresses the image and produces two thumbnails, one is 100x100 pixels, and the other is 35x35 pixels.&lt;br /&gt;
&lt;br /&gt;
If Moodle thinks GD is not installed, then you will need to &#039;&#039;&#039;install the GD library&#039;&#039;&#039;. &lt;br /&gt;
*On Unix you may need to re-compile PHP with arguments something like this:&lt;br /&gt;
&lt;br /&gt;
 ./configure --with-apxs=/usr/local/apache/bin/apxs --with-xml --with-gd &lt;br /&gt;
 --with-jpeg-dir=/usr/local --with-png-dir=/usr --with-ttf --enable-gd-native-ttf &lt;br /&gt;
 --enable-magic-quotes --with-mysql --enable-sockets --enable-track-vars &lt;br /&gt;
 --enable-versioning --with-zlib&lt;br /&gt;
&lt;br /&gt;
* On Windows this is usually a matter of &amp;quot;turning on&amp;quot; the extension in PHP by editing your php.ini file. To do this remove the semicolon for the php_gd2.dll extension - check that this file is actually present in your php extensions  folder first (search your php.ini for extension_dir to determine where this points to on your hard disk). You should then have a line that looks like this:&lt;br /&gt;
 extension=php_gd2.dll&lt;br /&gt;
&lt;br /&gt;
:Windows users should see the [[Installing AMP|installation instructions]] for further help. &lt;br /&gt;
&lt;br /&gt;
3. Remember to &#039;&#039;&#039;restart your webserver&#039;&#039;&#039; (if possible) and re-visit the Moodle configuration page after making any changes to PHP so it can pick up the correct version of GD.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;See also&#039;&#039;&#039;: Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=44271 Profile pictures] for additional information.&lt;br /&gt;
&lt;br /&gt;
== Why doesn&#039;t my Moodle site display the time and date correctly? ==&lt;br /&gt;
&lt;br /&gt;
Each language requires a specific language code (called a &#039;&#039;&#039;locale&#039;&#039;&#039; code) to allow dates to be displayed correctly. The language packs contain default standard codes, but sometimes these don&#039;t work on Windows servers.&lt;br /&gt;
&lt;br /&gt;
You can find the correct locale codes for Windows on these two pages: [http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_crt_language_strings.asp Language codes] and [http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_crt_country_strings.asp Country/region] codes (e.g. &amp;quot;esp_esp&amp;quot; for spanish)&lt;br /&gt;
&lt;br /&gt;
These new locale codes can be entered on the Administration &amp;gt;&amp;gt; Configuration &amp;gt;&amp;gt; [[admin/config|Variables]] page, where they override the ones in the currently chosen language pack.&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
== How do I uninstall Moodle?==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Webhost/manual installation&#039;&#039;&#039;: If you have installed Moodle manually or have installed onto a webhost, follow these steps:&lt;br /&gt;
*Delete the moodle database using this mysql command (or delete using your mysql client, e.g. PHPMyAdmin):&lt;br /&gt;
&amp;lt;pre&amp;gt;sql&amp;gt;DROP DATABASE moodle;&amp;lt;/pre&amp;gt;&lt;br /&gt;
:In the above example replace &#039;moodle&#039; with the name of the moodle database you created when installing.&lt;br /&gt;
*Delete the moodledata directory. If you, or your users, have uploaded materials into this directory take a copy of these before deleting this directory.&lt;br /&gt;
*Delete the moodle directory itself. This will delete all of the moodle PHP script files.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;XAMPP windows installation&#039;&#039;&#039;: If you have installed Moodle on windows through the XAMPP package, follow these steps:&lt;br /&gt;
*Open cmd.exe and navigate to this directory within your installation directory:&lt;br /&gt;
&amp;lt;pre&amp;gt;server/mysql/bin&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Run this command, replacing USERNAME with your database username (the default is &amp;quot;root&amp;quot;) and DATABASE with your database name (the default is &amp;quot;moodle&amp;quot;):&lt;br /&gt;
&amp;lt;pre&amp;gt;mysqladmin.exe -u USERNAME -p drop DATABASE&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Enter your database password at the prompt (the default is &amp;quot;&amp;quot; [blank]).&lt;br /&gt;
*Enter &amp;quot;y&amp;quot; to confirm the database drop.&lt;br /&gt;
*Delete the moodledata directory. If you, or your users, have uploaded materials into this directory take a copy of these before deleting this directory.&lt;br /&gt;
*Delete the moodle directory itself. This will delete all of the moodle PHP script files.&lt;br /&gt;
&lt;br /&gt;
==Migrating Moodle to a new site or server==&lt;br /&gt;
Migrating Moodle means that you have to move the current installation to a new server, and so may have to change IP addresses or DNS entries. To do this you will need to change the $CFG-&amp;gt;wwwroot value in the config.php on the new server. You will also have to change any absolute links stored in the database backup file (before restoring the file on the new server) either using the admin/replace.php script, your text editor or another &amp;quot;search and replace&amp;quot; tool, e.g. sed. For more details see the [[Moodle_migration | Moodle Migration]] page.&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
==Why does my new installation display correctly on the server, but when I view it from a different machine, styles and images are missing?==&lt;br /&gt;
In the installation instructions, one of the suggested settings for &#039;webroot&#039; is &#039;localhost&#039;. This is fine if all you want to do is some local testing of your new Moodle installation. If, however, you want to view your new installation from another machine on the same local area network, or view your site on the internet, you will have to change this setting:&lt;br /&gt;
*For local testing, &#039;localhost&#039; is fine for the webroot ($CFG-&amp;gt;wwwroot in config.php). &lt;br /&gt;
*If you want to test your site from other machines on the same local area network (LAN), then you will have to use the private ip address of the serving machine, (e.g. 192.168.1.2/moodle) or the network name of the serving computer (e.g. network_name_of_serving_machine/moodle) as the web root. Depending on your LAN setup, it may be better to use the network name of the computer rather than its (private) ip address, because the ip address can and will change from time to time. If you don&#039;t want to use the network name, then you will have to speak to your network administrator and have them assign a permanent ip address to the serving machine.&lt;br /&gt;
*Finally, if you want to test your new installation across the internet, you will have to use either a domain name or a permanent (public) ip address/moodle as your web root. To handle both types of access, see [https://docs.moodle.org/en/masquerading masquerading].&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
==Maximum upload file size - how to change it?==&lt;br /&gt;
There are several places to change the maximum file upload size. The first place to check is the Administration block.   Security -&amp;gt; Site Policies -&amp;gt; and look for &amp;quot;Maximum Uploaded File Size&amp;quot;.  This is the &amp;quot;maxbyte&amp;quot; variable found in older versions of Moodle (under Admin &amp;gt; Variables). Teachers may also set the maximum file size by the [[Course_settings#Maximum_upload_size|course administration block]].&lt;br /&gt;
&lt;br /&gt;
If the above does not provide a large enough figure you will need to make changes in your server settings. The usual place is in your php.ini file (go to Site administration &amp;gt; Server &amp;gt; PHPinfo and check a few lines down for its location). Look for settings &#039;&#039;&#039;upload_max_filesize&#039;&#039;&#039; and &#039;&#039;&#039;post_max_size&#039;&#039;&#039;, setting them both to your desired new value (e.g. &#039;64MB&#039;). You will need to restart the web server for these changes to take effect - e.g. on Linux, &#039;&#039;&#039;/etc/init.d/apache2 force-reload&#039;&#039;&#039;. Check your documentation or just reboot the server. &lt;br /&gt;
&lt;br /&gt;
For more help see:&lt;br /&gt;
*[[Administration_FAQ#How_do_the_limits_on_uploaded_files_work.3F]]&lt;br /&gt;
*[[Installing_Moodle#Recheck_PHP_settings]]&lt;br /&gt;
*[[Installing_Moodle#Using_a_.htaccess_file_for_webserver_and_PHP_settings]]&lt;br /&gt;
*[[Site_policies#Maximum_uploaded_file_size]]&lt;br /&gt;
*These forum posts: http://moodle.org/mod/forum/discuss.php?d=63840#287960 and http://moodle.org/mod/forum/discuss.php?d=93882#p414650&lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
==Moodle claims PHP float handling is not compatible==&lt;br /&gt;
&lt;br /&gt;
The symptom is that when you try to install or upgrade your Moodle, you get a message &amp;quot;Detected unexpected problem in handling of PHP float numbers&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=114945 This forum thread] and MDL-18253 have more information. In short, this problem should not happen, you can help us by telling posting information about exactly which version of PHP, and OS you are using. That may let us find a way to work around this problem.&lt;br /&gt;
&lt;br /&gt;
You may be able to solve this issue by installing a more recent PHP versions. If you compile PHP yourself from source, changing the compilation options may help. However, since we don&#039;t understand the cause, we don&#039;t really know. If you do find a solution that works for you, please do tell us about it.&lt;br /&gt;
&lt;br /&gt;
Update: we have a guess that the problem may be the [http://au2.php.net/manual/en/ini.core.php#ini.precision &#039;precision&#039; setting in your php.ini file]. In a default PHP install this is set of 14. On at least one server that exhibited this problem it had been changed to a smaller value. So, if you see this problem, please try adding &lt;br /&gt;
 ini_set(&#039;precision&#039;, 14);&lt;br /&gt;
to your config.php file, and report your success in MDL-18253.&lt;br /&gt;
&lt;br /&gt;
==When upgrading Moodle claims my database is not UTF8 when I&#039;m sure it is==&lt;br /&gt;
&lt;br /&gt;
The symptom is that you are upgrading a post-1.6 Moodle to a newer version. The Environment check tells you that your database is not UTF8 and refuses to upgrade. &lt;br /&gt;
&lt;br /&gt;
The database may not have it&#039;s character encoding set quite correctly. You can safely try this command on the database (mySQL):&lt;br /&gt;
&lt;br /&gt;
    ALTER DATABASE moodle DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
&lt;br /&gt;
(Change &#039;moodle&#039; for the name of your database). You need to copy this into your MySQL client program that comes packaged with it. &lt;br /&gt;
&lt;br /&gt;
Alternatively, you maybe adding a new clean install Moodle version to an existing web server and the UTF8 check error will not allow you to proceed.  Use [[phpMyAdmin]] to help you.  This web client is available as a plugin for Moodle or through your web hosting control panel. Using this program, create an empty database (for example moodle199) and make sure &amp;quot;MySQL connection collation&amp;quot; is a utf8 entry, such as utf8_general_ci. Go back to the Moodle installation screen with the check error, hit the previous button on the bottom and make sure the databae has the same name as your new empty database (for example moodle199). &lt;br /&gt;
&lt;br /&gt;
If your Moodle site is version 1.5 or older then it&#039;s telling the truth. &lt;br /&gt;
&lt;br /&gt;
[[#top|Top]]&lt;br /&gt;
&lt;br /&gt;
== How do I run multiple instances of Moodle without duplicating base code? ==&lt;br /&gt;
&lt;br /&gt;
See [http://moodle.org/mod/forum/discuss.php?d=13211 this thread] for a detailed explanation by [[User:Martin_Langhoff| Martin Langhoff]].&lt;br /&gt;
&lt;br /&gt;
==I want to use my server for my test Moodle, how can I run two Moodles at the same time?==&lt;br /&gt;
&lt;br /&gt;
There is always a number of reasons why you may require several different versions of Moodle on your server, or your localhost on a standalone computer. You may want to run two completely different Moodles for different purposes, so they may be the same versions. You may not be knowledgable in the coding practices required to reuse the same code base, or you my want your test Moodle to run in the same environment. The answers are the same for all of them, and you may want to use different techniques depending on your circumstances. &lt;br /&gt;
&lt;br /&gt;
First, in all versions of Moodle you are able to set the cookie prefix. Whenever you install a Moodle, it is a good idea to not just accept the default for the cookie prefix. Go to Administration menu &amp;gt; Server &amp;gt; Session Handling and you will see there is a text box that allows you to add a prefix for the Moodle. If you do this for every installation, you can have any number of installations - the problem is going to be the database.  &lt;br /&gt;
&lt;br /&gt;
At installation, you can create two different databases. again in some circumstances, there may be any number of valid reasons to do this, but fact is, you may not, in v2.x have to worry about it too much. Each installation will generate its own tables so, at installation, you can just give the databases different names.&lt;br /&gt;
&lt;br /&gt;
== What is FreeTDS and how can I use it in my installation? ==&lt;br /&gt;
[[FreeTDS]] is an open source implementation of the Tabular Data Stream protocol used by Microsoft SQL Server and Sybase for their databases. Unfortunately, Microsoft servers don&#039;t usually accept TDS 5.0 connections. FreeTDS allows your Unix/Linux applications to talk to these other database products and import and export data between different systems successfully.&lt;br /&gt;
&lt;br /&gt;
== How do I install a plugin? ==&lt;br /&gt;
&lt;br /&gt;
Please see [[Installing plugins]].&lt;br /&gt;
&lt;br /&gt;
==I can&#039;t enable a plugin on the Plugins overview page because the icon is not clickable==&lt;br /&gt;
The open and closed eye icon on the Plugins overview page is simply there to show whether or not a plugin is enabled. You can&#039;t edit plugins from this screen. If you wish to enable a plugin, to to the appropriate page for managing the type of plugin you need, for instance &#039;&#039;Settings&amp;gt;Site administration&amp;gt;Plugins&amp;gt;Repositories&amp;gt;Manage repositories&#039;&#039; or &#039;&#039;Settings&amp;gt;Site administration&amp;gt;Plugins&amp;gt;Activity modules&amp;gt;Manage activities.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
* [[Errors FAQ]]&lt;br /&gt;
* Using Moodle [http://moodle.org/mod/forum/view.php?id=28 Installation problems forum]&lt;br /&gt;
* [[Beginning_Moodle_2.0_Administration|Beginning Moodle 2.0 Administration FAQ]]&lt;br /&gt;
* Installing Moodle in a shared web hosting environment&lt;br /&gt;
** [https://docs.moodle.org/24/en/Finding_and_Selecting_A_Web_Host Finding and Selecting a web host]&lt;br /&gt;
** [https://docs.moodle.org/24/en/Install_Moodle2.2_on_godaddy Installing on GoDaddy]&lt;br /&gt;
** [https://docs.moodle.org/24/en/Installing_Moodle_on_SmarterASP.NET Installing Moodle on SmarterASP.NET web hosting]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Instalación]]&lt;br /&gt;
[[fr:FAQ d&#039;installation]]&lt;br /&gt;
[[ja:インストールFAQ]]&lt;br /&gt;
[[de:Installation FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Guest_access&amp;diff=104122</id>
		<title>Guest access</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Guest_access&amp;diff=104122"/>
		<updated>2013-04-23T12:29:17Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Admin settings for guest access */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Enrolment}}&lt;br /&gt;
The Guest access plugin allows users with the [[Guest_role |Guest role]] to view the contents of a course. This  might be used, for example, if a Moodle site serves as a website where certain courses contain publicly available information, or else with a commercial Moodle site where courses with guest access can  offers a &amp;quot;taster&amp;quot; of the kind of courses which may be purchased. (Note that the guest cannot participate in any activities; they can only view content.)&lt;br /&gt;
&lt;br /&gt;
==Course settings for guest access==&lt;br /&gt;
*In &#039;&#039;Settings &amp;gt; Course administration &amp;gt; Users &amp;gt; Enrolment methods&#039;&#039;, first ensure that you have added &amp;quot;guest access&amp;quot; as an enrollment method, and that it has its eye open.&lt;br /&gt;
*Ensure that self enrolment is also enabled.&lt;br /&gt;
*In &#039;&#039;Settings &amp;gt; Course administration &amp;gt; Edit settings&#039;&#039;, scroll to &amp;quot;Guest access&amp;quot;&lt;br /&gt;
*Set the drop down to &amp;quot;Yes&amp;quot;&lt;br /&gt;
*If you wish guests to use a password to access the course then add it here.&lt;br /&gt;
[[File:Guestaccesscoursesettings.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Admin settings for guest access==&lt;br /&gt;
*In &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Plugins &amp;gt; Enrolments &amp;gt; Manage enrol plugins&#039;&#039;,ensure Guest access is enabled (has its eye open.) This enables Guest access.&lt;br /&gt;
* In &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Plugins &amp;gt; Manage authentication&#039;&#039; set the Guest login button to Show if you want the button on the Frontpage or Hide if you do not. &lt;br /&gt;
* Also Guest accounts can be logged - check the &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Server &amp;gt; Cleanup &amp;gt; Log guest access&#039;&#039; setting&lt;br /&gt;
&lt;br /&gt;
===Default settings for guest access===&lt;br /&gt;
*Clicking on &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Plugins &amp;gt; Enrolments &amp;gt; Guest access&#039;&#039; brings up the screen where admin can set defaults for guest access in courses. Guest access can be turned on by default in all new courses and you can also:&lt;br /&gt;
**require each course with guest access to have a password for guests. (Note: this can confuse teachers who are not aware of the requirement.)&lt;br /&gt;
**use or ignore your Moodle&#039;s standard password policy for guest access passwords&lt;br /&gt;
**offer if needed the first letter of the password as a hint.&lt;br /&gt;
&lt;br /&gt;
===Auto-login guests===&lt;br /&gt;
*In &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Users &amp;gt; Permissions &amp;gt; User policies&#039;&#039;, you can tick the box so that visitors are automatically logged in as guests when accessing a course with guest access (i.e. they don&#039;t have to click the &amp;quot;login as guest button&amp;quot;.&lt;br /&gt;
*In &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Security &amp;gt; Site policies&#039;&#039; you can check &amp;quot;Open to Google&amp;quot; setting so that the Google search robot will be allowed to enter your site as a Guest. In addition, people coming in to your site via a Google search will automatically be logged in as a Guest.&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
&lt;br /&gt;
* [[Guest role]]&lt;br /&gt;
&lt;br /&gt;
[[de:Gastzugang zum Kurs]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Guest_role&amp;diff=104121</id>
		<title>Guest role</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Guest_role&amp;diff=104121"/>
		<updated>2013-04-23T12:27:01Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Skip login page for guest account */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Standard roles}}&lt;br /&gt;
==The guest account==&lt;br /&gt;
&lt;br /&gt;
Moodle has a built-in &amp;quot;Guest account&amp;quot;. Visitors can log in as guests using the &amp;quot;Login as a guest&amp;quot; button on the login screen and enter any courses which allow guest access. In addition, logged-in users can enter any courses which allow guest access without being required to enrol.&lt;br /&gt;
&lt;br /&gt;
Guests ALWAYS have &amp;quot;read-only&amp;quot; access - meaning they can&#039;t leave any posts or otherwise mess up the course for real students.&lt;br /&gt;
&lt;br /&gt;
They &#039;&#039;cannot&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
* Post in [[Forum module|forums]]&lt;br /&gt;
* Edit [[Wiki module|wiki]] pages&lt;br /&gt;
* Participate in a [[Chat module|chat]]&lt;br /&gt;
* Take [[Quiz|quizzes]]&lt;br /&gt;
* Submit [[Assignment|assignments]]&lt;br /&gt;
* Add [[Glossary|glossary]] or [[Database activity module|database activity]] entries or comments&lt;br /&gt;
* Receive any scores or grades (because of the read-only access)&lt;br /&gt;
&lt;br /&gt;
This feature can be handy when you want to let a colleague in to look around at your work, or to let students see a course before they have decided to enrol.&lt;br /&gt;
&lt;br /&gt;
If you want guests to be able to take quizzes, or any of the other activities listed above, and have considered the security implications, you can create a visitor account, say with username = password = visitor, for everyone to share.&lt;br /&gt;
&lt;br /&gt;
==Enabling guest access==&lt;br /&gt;
To allow guests into courses on your Moodle, see [[Guest_access|Guest access]].&lt;br /&gt;
&lt;br /&gt;
==Skip login page for guest account==&lt;br /&gt;
&lt;br /&gt;
All users will be automatically logged in as guests if you enable &#039;&#039;Auto-login guests&#039;&#039; in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; Users &amp;gt; Permissions &amp;gt; User policies&#039;&#039;. The standard login page is displayed after users visit page that requires real user login.&lt;br /&gt;
&lt;br /&gt;
==How can I deny Guest Access to my site altogether?==&lt;br /&gt;
&lt;br /&gt;
Look at Site administration &amp;gt; Plugins &amp;gt; Authentication &amp;gt; Manage authentication and scroll down. Look for Guest login button and a drop down options list that allows you to &amp;quot;Hide&amp;quot; the Guest Login button altogether.&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=69674 Allowing guests to post in forum?]&lt;br /&gt;
&lt;br /&gt;
[[fr:Visiteur anonyme]]&lt;br /&gt;
[[ja:ゲストアクセス]]&lt;br /&gt;
[[de:Gast-Rolle]]&lt;br /&gt;
[[es:Rol de invitado]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104120</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=104120"/>
		<updated>2013-04-23T12:24:50Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How can I deny Guest Access to my site altogether? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.x, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
===How can I extract original files from a Moodle backup file?===&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), here it goes...&lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
===How can I have two installations of Moodle on my server?===&lt;br /&gt;
&lt;br /&gt;
There is always a number of reasons why you may require several different versions of Moodle on your server, or your localhost on a standalone computer. You may want to run two completely different Moodles for different purposes, so they may be the same versions. The answers are the same for all of them, and you may want to use different techniques depending on your circumstances. &lt;br /&gt;
&lt;br /&gt;
First, in all versions of Moodle you are able to set the cookie prefix. Whenever you install a Moodle, it is a good idea to not just accept the default for the cookie prefix. Go to Administration menu &amp;gt; Server &amp;gt; Session Handling and you will see there is a text box that allows you to add a prefix for the Moodle. If you do this for every installation, you can have any number of installations - the problem is going to be the database.  &lt;br /&gt;
&lt;br /&gt;
At installation, you can create two different databases. again in some circumstances, there may be any number of valid reasons to do this, but fact is, you may not, in v2.x have to worry about it too much. Each installation will generate its own tables so, at installation, you may not have to worry too much apart from giving the databases different names.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104119</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=104119"/>
		<updated>2013-04-23T12:18:18Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Location&#039;&#039;&#039; You may not be able to alter the database from within itself. Make sure you are up one level, in the parent folder, if you like.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104118</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104118"/>
		<updated>2013-04-23T12:05:26Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* I have a very large course, over 2GB, and the backup process stops. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking.&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the time period specified in &#039;Skip courses not modified&#039; in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; &amp;gt; Courses &amp;gt; Backups &amp;gt; Automated backup setup&#039;&#039; (by default 30 days).&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# The target site has a user xxxx (xxxx being the username)&lt;br /&gt;
# The backup archive being restored also contains a user xxxx (same username)&lt;br /&gt;
# After various comparisons, Moodle has determined that the target site user xxxx and the backup user xxxx aren&#039;t the same person.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 are all true, the restore process stops in order to prevent the backup user xxxx&#039;s activities (forum posts, quiz attempts, assignment uploads, etc) from being associated with the target site user xxxx. &lt;br /&gt;
&lt;br /&gt;
These checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. It&#039;s common for the user in question to be the &amp;quot;admin&amp;quot; user (which exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible methods to make the xxxx users match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup archive &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match the ones in backup archive users.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and all activities in the backup file belonging to xxxx will be associated to the already existing target site user xxxx user.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. &lt;br /&gt;
  When editing is complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
==I have a very large course, over 2GB, and the backup process stops.==&lt;br /&gt;
&lt;br /&gt;
Larger courses can be restored in Moodle, but sometimes it needs a bit of tweaking to get it right. Moodle backup files are *.mbz fies and can be renamed to zip files. They can be unzipped, then edited, rezipped and restored. It does not matter if you are using a Linux or Windows or Mac server, a local host or anything else, the technique is the same. &lt;br /&gt;
&lt;br /&gt;
The editing comes in two different ways, one is the resources, activities, quizzes, images. video files and so on are listed, written and referred to in the moodle.xml file. You can find the starting point and the end point of each resouce that you can delete out of the xml file. &lt;br /&gt;
&lt;br /&gt;
The xml might look something like this:&lt;br /&gt;
  &amp;lt;file id=&amp;quot;111&amp;quot;&amp;gt;    &amp;lt;contenthash&amp;gt;b11ac9bc0cebee17acfd28d13b548331f76645bc&amp;lt;/contenthash&amp;gt;&lt;br /&gt;
    &amp;lt;contextid&amp;gt;21&amp;lt;/contextid&amp;gt;&lt;br /&gt;
    &amp;lt;component&amp;gt;mod_resource&amp;lt;/component&amp;gt;&lt;br /&gt;
    &amp;lt;filearea&amp;gt;content&amp;lt;/filearea&amp;gt;&lt;br /&gt;
    &amp;lt;itemid&amp;gt;0&amp;lt;/itemid&amp;gt;&lt;br /&gt;
    &amp;lt;filepath&amp;gt;/&amp;lt;/filepath&amp;gt;&lt;br /&gt;
    &amp;lt;filename&amp;gt;howtomakeatimemachine.flv&amp;lt;/filename&amp;gt;&lt;br /&gt;
    &amp;lt;userid&amp;gt;4&amp;lt;/userid&amp;gt;&lt;br /&gt;
    &amp;lt;filesize&amp;gt;1092320586557&amp;lt;/filesize&amp;gt;&lt;br /&gt;
    &amp;lt;mimetype&amp;gt;video/flv&amp;lt;/mimetype&amp;gt;&lt;br /&gt;
    &amp;lt;status&amp;gt;0&amp;lt;/status&amp;gt;&lt;br /&gt;
    &amp;lt;timecreated&amp;gt;12345432123&amp;lt;/timecreated&amp;gt;&lt;br /&gt;
    &amp;lt;timemodified&amp;gt;12345432123&amp;lt;/timemodified&amp;gt;&lt;br /&gt;
    &amp;lt;source&amp;gt;howtomakeatimemachine.flv&amp;lt;/source&amp;gt;&lt;br /&gt;
    &amp;lt;author&amp;gt;Fred Nurks&amp;lt;/author&amp;gt;&lt;br /&gt;
    &amp;lt;license&amp;gt;allrightsreserved&amp;lt;/license&amp;gt;&lt;br /&gt;
    &amp;lt;sortorder&amp;gt;0&amp;lt;/sortorder&amp;gt;&lt;br /&gt;
    &amp;lt;repositorytype&amp;gt;$@NULL@$&amp;lt;/repositorytype&amp;gt;&lt;br /&gt;
    &amp;lt;repositoryid&amp;gt;$@NULL@$&amp;lt;/repositoryid&amp;gt;&lt;br /&gt;
    &amp;lt;reference&amp;gt;$@NULL@$&amp;lt;/reference&amp;gt;&lt;br /&gt;
  &amp;lt;/file&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When editing, make sure all this is deleted, everything between the &amp;lt;file&amp;gt;&amp;lt;/file&amp;gt; tags.&lt;br /&gt;
&lt;br /&gt;
The second part of editing is locating the actual resouce if it is an image, a separate file or video then deleting it. Really large mbz files tend to have a lot of videos, often flv files, or uncompressed images, like tiffs. They can be found, and deleted easily, in the directory tree of the backup.&lt;br /&gt;
&lt;br /&gt;
You can then rezip the edited file, rename it to an mbz and, if you have edited it right, it should restore. You can use the original file to break down really large backups over and over into four or five smaller mbz files, as many as you like.&lt;br /&gt;
&lt;br /&gt;
It is recommended that you test the technique first on a smaller file, it is easier to follow and gets you used to xml structuring and so on. Say one course with a couple of pages, a number of different image types, a couple of videos will help you immensely.  &lt;br /&gt;
&lt;br /&gt;
You do not have to worry about permissions in Windows or Xos servers, or concern yourself with editing rights usually. However, you may be required to ensure you are the owner fo the files being edited.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104117</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=104117"/>
		<updated>2013-04-23T11:51:11Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* See also */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking.&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the time period specified in &#039;Skip courses not modified&#039; in &#039;&#039;Settings &amp;gt; Site administration &amp;gt; &amp;gt; Courses &amp;gt; Backups &amp;gt; Automated backup setup&#039;&#039; (by default 30 days).&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# The target site has a user xxxx (xxxx being the username)&lt;br /&gt;
# The backup archive being restored also contains a user xxxx (same username)&lt;br /&gt;
# After various comparisons, Moodle has determined that the target site user xxxx and the backup user xxxx aren&#039;t the same person.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 are all true, the restore process stops in order to prevent the backup user xxxx&#039;s activities (forum posts, quiz attempts, assignment uploads, etc) from being associated with the target site user xxxx. &lt;br /&gt;
&lt;br /&gt;
These checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. It&#039;s common for the user in question to be the &amp;quot;admin&amp;quot; user (which exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible methods to make the xxxx users match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup archive &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match the ones in backup archive users.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and all activities in the backup file belonging to xxxx will be associated to the already existing target site user xxxx user.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. &lt;br /&gt;
  When editing is complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
==I have a very large course, over 2GB, and the backup process stops.==&lt;br /&gt;
&lt;br /&gt;
Larger courses can be restored in Moodle, but sometimes it needs a bit of tweaking to get it right. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Discussi%C3%B3:Table_of_Contents&amp;diff=101490</id>
		<title>Discussió:Table of Contents</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Discussi%C3%B3:Table_of_Contents&amp;diff=101490"/>
		<updated>2012-10-25T10:52:33Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: Created page with &amp;quot;===&amp;#039;&amp;#039;&amp;#039;Page layout&amp;#039;&amp;#039;&amp;#039;=== The layout of this page is not good. While it is linear, it becomes a long scroll to the bottom of the page. Perhaps each part could be in a multi-columne...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===&#039;&#039;&#039;Page layout&#039;&#039;&#039;===&lt;br /&gt;
The layout of this page is not good. While it is linear, it becomes a long scroll to the bottom of the page. Perhaps each part could be in a multi-columned table? Each group of topics would be in its own cell. Would make it easier to find something.&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101436</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101436"/>
		<updated>2012-10-21T11:47:24Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
On Windows systems, if you have configured Moodle to use an external zip program then the IIS IUSR_computername user needs to have Execute access to cmd.exe so that it can run the zip program. See the Note in [https://docs.moodle.org/en/System_paths#Path_to_zip Path to zip] for more details.  &lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking (generally internal zip libraries, try to switch to external executables instead).&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the last month.&lt;br /&gt;
&lt;br /&gt;
The [http://moodle.org/mod/forum/discuss.php?d=80367#p714733 Hide courses excluded from automatic backup] discussion in the Using Moodle forum describes a way that you can disable or override this thirty day check. This could be useful if, for example, you wanted to change the period from thirty days to six months.&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# Your target site has one xxxx user (xxxx being the username)&lt;br /&gt;
# The backup being restored also has one xxxx user&lt;br /&gt;
# After various comparisons, Moodle has detected that the xxxx user in 1. and the xxxx user in 2. aren&#039;t the same user.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 above happens, restore stops before performing any action as far as restoring that user will end associating &amp;quot;things&amp;quot; (create activities, posts, attempts... whatever...) to the xxxx user in the target site, when those &amp;quot;things&amp;quot; weren&#039;t performed by the same user at all.&lt;br /&gt;
&lt;br /&gt;
Those checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. Usually the xxxx user in the messages is the &amp;quot;admin&amp;quot; user (that exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible solutions to make both xxxx users in 1 and 2 to match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup&#039;s &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match with the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match with the ones in backup&#039;s user.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and every &amp;quot;thing&amp;quot; in the backup file belonging to xxxx will be associated to the already existing xxxx user in the target site.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. &lt;br /&gt;
  When editing is complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101435</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101435"/>
		<updated>2012-10-21T11:47:06Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
On Windows systems, if you have configured Moodle to use an external zip program then the IIS IUSR_computername user needs to have Execute access to cmd.exe so that it can run the zip program. See the Note in [https://docs.moodle.org/en/System_paths#Path_to_zip Path to zip] for more details.  &lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking (generally internal zip libraries, try to switch to external executables instead).&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the last month.&lt;br /&gt;
&lt;br /&gt;
The [http://moodle.org/mod/forum/discuss.php?d=80367#p714733 Hide courses excluded from automatic backup] discussion in the Using Moodle forum describes a way that you can disable or override this thirty day check. This could be useful if, for example, you wanted to change the period from thirty days to six months.&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# Your target site has one xxxx user (xxxx being the username)&lt;br /&gt;
# The backup being restored also has one xxxx user&lt;br /&gt;
# After various comparisons, Moodle has detected that the xxxx user in 1. and the xxxx user in 2. aren&#039;t the same user.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 above happens, restore stops before performing any action as far as restoring that user will end associating &amp;quot;things&amp;quot; (create activities, posts, attempts... whatever...) to the xxxx user in the target site, when those &amp;quot;things&amp;quot; weren&#039;t performed by the same user at all.&lt;br /&gt;
&lt;br /&gt;
Those checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. Usually the xxxx user in the messages is the &amp;quot;admin&amp;quot; user (that exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible solutions to make both xxxx users in 1 and 2 to match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup&#039;s &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match with the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match with the ones in backup&#039;s user.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and every &amp;quot;thing&amp;quot; in the backup file belonging to xxxx will be associated to the already existing xxxx user in the target site.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. &lt;br /&gt;
  When editing complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101434</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101434"/>
		<updated>2012-10-21T11:46:30Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
On Windows systems, if you have configured Moodle to use an external zip program then the IIS IUSR_computername user needs to have Execute access to cmd.exe so that it can run the zip program. See the Note in [https://docs.moodle.org/en/System_paths#Path_to_zip Path to zip] for more details.  &lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking (generally internal zip libraries, try to switch to external executables instead).&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the last month.&lt;br /&gt;
&lt;br /&gt;
The [http://moodle.org/mod/forum/discuss.php?d=80367#p714733 Hide courses excluded from automatic backup] discussion in the Using Moodle forum describes a way that you can disable or override this thirty day check. This could be useful if, for example, you wanted to change the period from thirty days to six months.&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# Your target site has one xxxx user (xxxx being the username)&lt;br /&gt;
# The backup being restored also has one xxxx user&lt;br /&gt;
# After various comparisons, Moodle has detected that the xxxx user in 1. and the xxxx user in 2. aren&#039;t the same user.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 above happens, restore stops before performing any action as far as restoring that user will end associating &amp;quot;things&amp;quot; (create activities, posts, attempts... whatever...) to the xxxx user in the target site, when those &amp;quot;things&amp;quot; weren&#039;t performed by the same user at all.&lt;br /&gt;
&lt;br /&gt;
Those checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. Usually the xxxx user in the messages is the &amp;quot;admin&amp;quot; user (that exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible solutions to make both xxxx users in 1 and 2 to match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup&#039;s &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match with the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match with the ones in backup&#039;s user.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and every &amp;quot;thing&amp;quot; in the backup file belonging to xxxx will be associated to the already existing xxxx user in the target site.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;mbz&#039;&#039;&#039;&#039;&#039; is a zip file and can be renamed to &#039;&#039;moodle-filename-backup.&#039;&#039;&#039;zip&#039;&#039;&#039;&#039;&#039; and unzipped. When editing complete, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101433</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101433"/>
		<updated>2012-10-21T11:45:18Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
On Windows systems, if you have configured Moodle to use an external zip program then the IIS IUSR_computername user needs to have Execute access to cmd.exe so that it can run the zip program. See the Note in [https://docs.moodle.org/en/System_paths#Path_to_zip Path to zip] for more details.  &lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking (generally internal zip libraries, try to switch to external executables instead).&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the last month.&lt;br /&gt;
&lt;br /&gt;
The [http://moodle.org/mod/forum/discuss.php?d=80367#p714733 Hide courses excluded from automatic backup] discussion in the Using Moodle forum describes a way that you can disable or override this thirty day check. This could be useful if, for example, you wanted to change the period from thirty days to six months.&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# Your target site has one xxxx user (xxxx being the username)&lt;br /&gt;
# The backup being restored also has one xxxx user&lt;br /&gt;
# After various comparisons, Moodle has detected that the xxxx user in 1. and the xxxx user in 2. aren&#039;t the same user.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 above happens, restore stops before performing any action as far as restoring that user will end associating &amp;quot;things&amp;quot; (create activities, posts, attempts... whatever...) to the xxxx user in the target site, when those &amp;quot;things&amp;quot; weren&#039;t performed by the same user at all.&lt;br /&gt;
&lt;br /&gt;
Those checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. Usually the xxxx user in the messages is the &amp;quot;admin&amp;quot; user (that exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible solutions to make both xxxx users in 1 and 2 to match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup&#039;s &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match with the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match with the ones in backup&#039;s user.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and every &amp;quot;thing&amp;quot; in the backup file belonging to xxxx will be associated to the already existing xxxx user in the target site.&lt;br /&gt;
&lt;br /&gt;
  &#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using method a) be aware that the &#039;&#039;moodle-filename-backup.mbz&#039;&#039; is a zip file and can be renamed and unzipped. When editing compelte, rezip and then &lt;br /&gt;
  rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101432</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101432"/>
		<updated>2012-10-21T11:44:47Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
On Windows systems, if you have configured Moodle to use an external zip program then the IIS IUSR_computername user needs to have Execute access to cmd.exe so that it can run the zip program. See the Note in [https://docs.moodle.org/en/System_paths#Path_to_zip Path to zip] for more details.  &lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking (generally internal zip libraries, try to switch to external executables instead).&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the last month.&lt;br /&gt;
&lt;br /&gt;
The [http://moodle.org/mod/forum/discuss.php?d=80367#p714733 Hide courses excluded from automatic backup] discussion in the Using Moodle forum describes a way that you can disable or override this thirty day check. This could be useful if, for example, you wanted to change the period from thirty days to six months.&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# Your target site has one xxxx user (xxxx being the username)&lt;br /&gt;
# The backup being restored also has one xxxx user&lt;br /&gt;
# After various comparisons, Moodle has detected that the xxxx user in 1. and the xxxx user in 2. aren&#039;t the same user.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 above happens, restore stops before performing any action as far as restoring that user will end associating &amp;quot;things&amp;quot; (create activities, posts, attempts... whatever...) to the xxxx user in the target site, when those &amp;quot;things&amp;quot; weren&#039;t performed by the same user at all.&lt;br /&gt;
&lt;br /&gt;
Those checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. Usually the xxxx user in the messages is the &amp;quot;admin&amp;quot; user (that exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible solutions to make both xxxx users in 1 and 2 to match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup&#039;s &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match with the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match with the ones in backup&#039;s user.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and every &amp;quot;thing&amp;quot; in the backup file belonging to xxxx will be associated to the already existing xxxx user in the target site.&lt;br /&gt;
&lt;br /&gt;
  NOTE: When using method a) be aware that the &#039;&#039;moodle-filename-backup.mbz&#039;&#039; is a zip file and can be renamed and unzipped. When editing compelte, rezip and then &lt;br /&gt;
  rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101431</id>
		<title>Backup and restore FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Backup_and_restore_FAQ&amp;diff=101431"/>
		<updated>2012-10-21T11:44:12Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Backup}}&lt;br /&gt;
==How do I backup a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course backup]] and [[Automated backup setup]]. &lt;br /&gt;
&lt;br /&gt;
==How do I restore a course?==&lt;br /&gt;
&lt;br /&gt;
See [[Course restore]].&lt;br /&gt;
&lt;br /&gt;
==How do I backup my site?==&lt;br /&gt;
&lt;br /&gt;
See [[Site backup]].&lt;br /&gt;
&lt;br /&gt;
==What are the pros and cons of course versus site backups?==&lt;br /&gt;
&lt;br /&gt;
[[Site backup|Site backups]] are recommended in order to have all data saved with the best confidence and the shortest recovery time.&lt;br /&gt;
&lt;br /&gt;
For a site administrator, [[Automated course backup|automated course backups]] are more expensive in terms of time, CPU usage and storage. The recovery time to have a site running again takes longer than a site backup. However,  teachers and site administrators might find a course backups as a way to create a &amp;quot;fresh&amp;quot; copy of a course that can be re-used (in older versions of Moodle, in newer versions see [[Import course data]]) or as a method to distribute a course(s) to other Moodle sites.&lt;br /&gt;
&lt;br /&gt;
==Why is my automated course backup much smaller in size than my manual course backup?==&lt;br /&gt;
&lt;br /&gt;
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disc space and makes the backup procedure much faster. &lt;br /&gt;
&lt;br /&gt;
==What data is not contained in course backups?==&lt;br /&gt;
&lt;br /&gt;
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:&lt;br /&gt;
* Quiz questions are only backed up if at least one question from their category has been added to a quiz.&lt;br /&gt;
* Scales are only backed up if they are used by at least one activity.&lt;br /&gt;
* Users&#039; passwords are not backed up when the &amp;quot;Include enrolled users&amp;quot; option is selected.&lt;br /&gt;
&lt;br /&gt;
==Why is there no &amp;quot;all/none&amp;quot; feature when selecting items to  backup?==&lt;br /&gt;
This was enabled in MDL-32705 and is available in Moodle 2.3.2 onwards.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;Error: An error occurred deleting old backup data&amp;quot;. What should I do?==&lt;br /&gt;
&lt;br /&gt;
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:&lt;br /&gt;
&lt;br /&gt;
# Delete old records from &amp;quot;backup_ids&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old records from &amp;quot;backup_files&amp;quot; table: Check the table exists, repair it and try again.&lt;br /&gt;
# Delete old files from &amp;quot;moodledata/temp/backup&amp;quot;: Delete the dir completely and try again.&lt;br /&gt;
&lt;br /&gt;
[[Image:BackupProblem.gif|thumb|Backup error message]]For points 1 &amp;amp; 2, there are various ways of repairing tables, including using MySQL Admin.&lt;br /&gt;
For point 3 see below:&lt;br /&gt;
&lt;br /&gt;
The error message states that the &amp;quot;directory not empty&amp;quot; and gives the path to that directory. If you go there with an FTP program you can see what is there and clean up. It could be just some empty subfolders that were leftover. Deleting these has been able to help. One can also delete the dir &amp;quot;moodledata/temp/backup&amp;quot; completely. That can take a bit longer but may solve several problems at once.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;XML error: not well-formed (invalid token) at line YYYY&amp;quot;. What can I do?==&lt;br /&gt;
&lt;br /&gt;
This problem can appear at any point in the restore process. It&#039;s caused when the XML parser detects something incorrect in the backup file that prevent correct operation. Usually, it&#039;s caused by some &amp;quot;illegal&amp;quot; characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...).&lt;br /&gt;
&lt;br /&gt;
The best method to handle this issue is:&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic backup file under one empty folder.&lt;br /&gt;
&lt;br /&gt;
* Open the moodle.xml with Firefox. It will show you where (exact char) the problem is happening.&lt;br /&gt;
&lt;br /&gt;
* Edit the moodle.xml file with some UTF8-compatible editor and delete such characters. Save changes.&lt;br /&gt;
&lt;br /&gt;
* Test the moodle.xml file again with Firefox until no error was displayed.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but not the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
* Restore still not working? See the next question.&lt;br /&gt;
&lt;br /&gt;
Also, if possible, it&#039;s highly recommended to solve those problems in the original course too from Moodle itself. Once &amp;quot;repaired&amp;quot; there, problems will be out if you create new backup files in the future.&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;moodle xml not found at root level of zip file&amp;quot;. What can I do?==&lt;br /&gt;
If you are restoring from a zip file backup make sure the moodle.xml file is at the root level. To ensure this:&lt;br /&gt;
#Unzip the backup file of the course (example: mycourse.zip)&lt;br /&gt;
#Once the file is unzipped, open the folder (example: mycourse).&lt;br /&gt;
#Select the folders within the mycourse folder AND the moodle.xml file and create a zip of those item (example: mycourse_new.zip)&lt;br /&gt;
#Upload the new zip file (example: mycourse_new.zip) and restore from that.&lt;br /&gt;
&lt;br /&gt;
If the backup file is guaranteed to be correct, check paths to external files (zip, unzip). Incorrect settings also lead to this error message (see the Using Moodle forum discussion [http://moodle.org/mod/forum/discuss.php?d=140355 moodle.xml not found in root...] and MDL-14812).&lt;br /&gt;
&lt;br /&gt;
==The process ends with: &amp;quot;An error occurred while copying the zip file...&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
This problem is most likely caused by a permissions issue in the destination directory. Backup files are copied to &amp;quot;XXX/backupdata&amp;quot; under your dataroot directory (where XXX is the id of the course being backed up).&lt;br /&gt;
&lt;br /&gt;
On Windows systems, if you have configured Moodle to use an external zip program then the IIS IUSR_computername user needs to have Execute access to cmd.exe so that it can run the zip program. See the Note in [https://docs.moodle.org/en/System_paths#Path_to_zip Path to zip] for more details.  &lt;br /&gt;
&lt;br /&gt;
The problem could also be caused by a disk being full, though this is far less likely.&lt;br /&gt;
&lt;br /&gt;
To obtain precise information about what&#039;s happening, you can enable debug messages in &#039;&#039;Administration &amp;gt; Server &amp;gt; [[Debugging]]&#039;&#039; (select the maximum level - DEVELOPER) and/or check the web server error logs.&lt;br /&gt;
&lt;br /&gt;
==I Still get an XML error. How can I clean the borked XML file?==&lt;br /&gt;
&lt;br /&gt;
In some cases XML backup files may contain characters causing the restore process to abort, even after the steps described in the previous question. In such cases you may want to try the following:&lt;br /&gt;
&lt;br /&gt;
* Download the [http://repository.atlassian.com/atlassian-xml-cleaner/jars/atlassian-xml-cleaner-0.1.jar Atlassian XML Cleaner Utility] from the [http://confluence.atlassian.com/display/JIRA/Removing+invalid+characters+from+XML+backups JIRA Atlassian site].&lt;br /&gt;
&lt;br /&gt;
* Unzip the problematic Moodle backup file under one empty folder. Moodle will create the course file folders as long as the unclean moodle.xml file. Please unzip using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Rename the unclean moodle.xml file to moodle-unclean.xml. &lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t have access to your Moodle server&#039;s command prompt, using the Moodle zip feature, zip the moodle-unclean.xml file only, download the zip file locally and unzip it. It is very important to download the xml file in zipped format to avoid unwanted character encoding when transferring from an operating system to another.&lt;br /&gt;
&lt;br /&gt;
* Move the downloaded Atlassian XML Cleaner Utility in the same folder where is your moodle-unclean.xml file.&lt;br /&gt;
&lt;br /&gt;
* Issue the following command from the command prompt: &lt;br /&gt;
&lt;br /&gt;
 java -jar atlassian-xml-cleaner-0.1.jar moodle-unclean.xml &amp;gt; moodle.xml&lt;br /&gt;
&lt;br /&gt;
* If you launched the utility on your local computer, zip the just created (and hopefully cleaned) moodle.xml file and upload it in the same place from where you downloaded the moodle-unclean.xml file. Once uploaded, unzip it using the Moodle unzip feature.&lt;br /&gt;
&lt;br /&gt;
* Zip everything again (all the folder contents but the folder itself!).&lt;br /&gt;
&lt;br /&gt;
* Restore the course. It should work now.&lt;br /&gt;
&lt;br /&gt;
==What does &amp;quot;Some of your courses weren&#039;t saved!!&amp;quot; mean?==&lt;br /&gt;
&lt;br /&gt;
There are three possible causes of this problem:&lt;br /&gt;
# Error - this happens when the backup procedure has found an error and so hasn&#039;t finished the backup of a particular course. These are &amp;quot;controlled&amp;quot; errors and the scheduled backup continues with the next course.&lt;br /&gt;
# Unfinished - this happens when the backup procedure dies without knowing why. When the cron is next executed it detects that the last execution went wrong, and continues skipping the problematic course. A possible solution would be to raise the PHP/Apache limit in your installation (memory, time of execution...). By taking a look to your log tables you should be able to see if the &amp;quot;crash&amp;quot; is happening at exact time intervals (usually a problem with the max_execution_time php&#039;s variable), or if there is some exact point were all the courses are breaking (generally internal zip libraries, try to switch to external executables instead).&lt;br /&gt;
# Skipped - this happens when a course is unavailable to students and has not been changed in the last month (31 days). This isn&#039;t an error situation - it&#039;s a feature, especially useful for sites with many unavailable old courses, saving process time.&lt;br /&gt;
&lt;br /&gt;
==Why are some courses being skipped?==&lt;br /&gt;
&lt;br /&gt;
Course backups automatically skip courses which are unavailable to students and have not been changed in the last month.&lt;br /&gt;
&lt;br /&gt;
The [http://moodle.org/mod/forum/discuss.php?d=80367#p714733 Hide courses excluded from automatic backup] discussion in the Using Moodle forum describes a way that you can disable or override this thirty day check. This could be useful if, for example, you wanted to change the period from thirty days to six months.&lt;br /&gt;
&lt;br /&gt;
==Why does restore stop, rather than completing?==&lt;br /&gt;
&lt;br /&gt;
Attempting to restore a course to an older version of Moodle than the one the course was backed up on can result in the restore process failing to complete. To ensure a successful restore, make sure that the version of Moodle you are restoring the course to is the same, or newer, than the one the course was backed up on.&lt;br /&gt;
&lt;br /&gt;
If it stop unexpectedly with no errors shown try again with [[Debugging]] switched on. Any errors you now see can help experts in the support forums diagnose your problem. You can also check the discussion links in the See also section below for further advice.&lt;br /&gt;
&lt;br /&gt;
==Restore stops with the message &amp;quot;Trying to restore user xxxx from backup file will cause conflict&amp;quot;==&lt;br /&gt;
&lt;br /&gt;
[[Image:Moodle 2.0 Restore breaks.png|thumb|Error message in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
This message is displayed when:&lt;br /&gt;
&lt;br /&gt;
# Your target site has one xxxx user (xxxx being the username)&lt;br /&gt;
# The backup being restored also has one xxxx user&lt;br /&gt;
# After various comparisons, Moodle has detected that the xxxx user in 1. and the xxxx user in 2. aren&#039;t the same user.&lt;br /&gt;
&lt;br /&gt;
If 1, 2 and 3 above happens, restore stops before performing any action as far as restoring that user will end associating &amp;quot;things&amp;quot; (create activities, posts, attempts... whatever...) to the xxxx user in the target site, when those &amp;quot;things&amp;quot; weren&#039;t performed by the same user at all.&lt;br /&gt;
&lt;br /&gt;
Those checks and behaviour were introduced in Moodle 1.9.x and continue being valid under 2.0. Usually the xxxx user in the messages is the &amp;quot;admin&amp;quot; user (that exists in practically all Moodle installations).&lt;br /&gt;
&lt;br /&gt;
There are two possible solutions to make both xxxx users in 1 and 2 to match (and avoid the conflict):&lt;br /&gt;
&lt;br /&gt;
a) Modify the backup&#039;s &#039;&#039;&#039;users.xml&#039;&#039;&#039; file and make the &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields match with the ones in target site.&amp;lt;br /&amp;gt;&lt;br /&gt;
b) Modify the &#039;&#039;&#039;target site&#039;&#039;&#039; and set the user &#039;&#039;email&#039;&#039; or &#039;&#039;firstaccess&#039;&#039; fields to match with the ones in backup&#039;s user.xml file.&lt;br /&gt;
&lt;br /&gt;
Method a) is recommended so the restore process will match both xxxx users and every &amp;quot;thing&amp;quot; in the backup file belonging to xxxx will be associated to the already existing xxxx user in the target site.&lt;br /&gt;
&lt;br /&gt;
 NOTE: When using method a) be aware that the &#039;&#039;moodle-filename-backup.mbz&#039;&#039; is a zip file and can be renamed and unzipped. When editing compelte, rezip and then rename using the original file name with the &amp;quot;*.mbz&amp;quot; extention.&lt;br /&gt;
&lt;br /&gt;
==Why are certain course links broken in a restored course?==&lt;br /&gt;
&lt;br /&gt;
Inter-activity links must be absolute (full) URLs e.g. &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://site.com/mod/resource/view.php?id=xxx&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; in order to be processed properly during backup and restore.&lt;br /&gt;
&lt;br /&gt;
Any relative URLs e.g. &amp;lt;code&amp;gt;/mod/resource/view.php?id=xxx&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;../resource/view.php?id=xxx&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;view.php?id=xxx&amp;lt;/code&amp;gt; will result in broken links when the course is restored.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
*Using Moodle [http://moodle.org/mod/forum/view.php?f=128 Backup and Restore forum]&lt;br /&gt;
*[http://www.databasejournal.com/features/mysql/article.php/10897_3300511_2 databasejournal.com article on repairing database corruption in MySQL]&lt;br /&gt;
* [[Site backup]]&lt;br /&gt;
* [[Moodle migration]]&lt;br /&gt;
* [[Beginning Moodle 2.0 Administration]]&lt;br /&gt;
&lt;br /&gt;
Using Moodle forum discussions:&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=142720 Trying to restore user &#039;admin&#039; from backup file will cause conflict]&lt;br /&gt;
*[http://moodle.org/mod/forum/discuss.php?d=167471 Where is the Moodle 2.0 &amp;quot;Course Backup Filearea&amp;quot;?]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;br /&gt;
&lt;br /&gt;
[[es:FAQ Backup]]&lt;br /&gt;
[[pl:Backup FAQ]]&lt;br /&gt;
[[fr:FAQ de sauvegarde]]&lt;br /&gt;
[[ja:バックアップFAQ]]&lt;br /&gt;
[[pt:FAQ sobre cópias de segurança]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=101375</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=101375"/>
		<updated>2012-10-17T21:09:08Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* My Password is not being accepted as valid. How can I login as an Admin? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.x, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should be able to access your Moodle as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
===How can I extract original files from a Moodle backup file?===&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), here it goes...&lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
===How can I have two installations of Moodle on my server?===&lt;br /&gt;
&lt;br /&gt;
There is always a number of reasons why you may require several different versions of Moodle on your server, or your localhost on a standalone computer. You may want to run two completely different Moodles for different purposes, so they may be the same versions. The answers are the same for all of them, and you may want to use different techniques depending on your circumstances. &lt;br /&gt;
&lt;br /&gt;
First, in all versions of Moodle you are able to set the cookie prefix. Whenever you install a Moodle, it is a good idea to not just accept the default for the cookie prefix. Go to Administration menu &amp;gt; Server &amp;gt; Session Handling and you will see there is a text box that allows you to add a prefix for the Moodle. If you do this for every installation, you can have any number of installations - the problem is going to be the database.  &lt;br /&gt;
&lt;br /&gt;
At installation, you can create two different databases. again in some circumstances, there may be any number of valid reasons to do this, but fact is, you may not, in v2.x have to worry about it too much. Each installation will generate its own tables so, at installation, you may not have to worry too much apart from giving the databases different names.&lt;br /&gt;
&lt;br /&gt;
===How can I deny Guest Access to my site altogether?===&lt;br /&gt;
&lt;br /&gt;
Look at Site administration ► Plugins ► Authentication ► Manage authentication and there is a switch there that allows you to turn the Guest Access button off altogether.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=101374</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=101374"/>
		<updated>2012-10-17T21:04:46Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How do I create a repository? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.x, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should then be able to get into your Moodle then, as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How can I extract original files from a Moodle backup file?===&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), here it goes...&lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
===How can I have two installations of Moodle on my server?===&lt;br /&gt;
&lt;br /&gt;
There is always a number of reasons why you may require several different versions of Moodle on your server, or your localhost on a standalone computer. You may want to run two completely different Moodles for different purposes, so they may be the same versions. The answers are the same for all of them, and you may want to use different techniques depending on your circumstances. &lt;br /&gt;
&lt;br /&gt;
First, in all versions of Moodle you are able to set the cookie prefix. Whenever you install a Moodle, it is a good idea to not just accept the default for the cookie prefix. Go to Administration menu &amp;gt; Server &amp;gt; Session Handling and you will see there is a text box that allows you to add a prefix for the Moodle. If you do this for every installation, you can have any number of installations - the problem is going to be the database.  &lt;br /&gt;
&lt;br /&gt;
At installation, you can create two different databases. again in some circumstances, there may be any number of valid reasons to do this, but fact is, you may not, in v2.x have to worry about it too much. Each installation will generate its own tables so, at installation, you may not have to worry too much apart from giving the databases different names.&lt;br /&gt;
&lt;br /&gt;
===How can I deny Guest Access to my site altogether?===&lt;br /&gt;
&lt;br /&gt;
Look at Site administration ► Plugins ► Authentication ► Manage authentication and there is a switch there that allows you to turn the Guest Access button off altogether.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101368</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101368"/>
		<updated>2012-10-17T20:56:01Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Administration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. If you need them, you will pick these skills up as you go, and if you already have any programming skills, it is going to be fairly easy to do so. If you have never done any programming before, it is a little more difficult, but once you have the idea, it becomes a lot easier. Unless you intend on developing your Moodle, e.g. build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101363</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101363"/>
		<updated>2012-10-17T12:11:48Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages. The questions asked here are mostly questions that I was confronted with when I first started with administering a Moodle, but I had some experience as a user which helped me a lot. The other source of questions is the Moodle Forums.   &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go, if you need them. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101362</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101362"/>
		<updated>2012-10-17T12:09:38Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Adminsitration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Administration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go, if you need them. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101361</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101361"/>
		<updated>2012-10-17T12:09:07Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go, if you need them. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101360</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101360"/>
		<updated>2012-10-17T12:01:37Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Adminsitration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go, if you need them. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy the code for them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101359</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101359"/>
		<updated>2012-10-17T12:00:37Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Adminsitration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to make things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy the code for them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101358</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101358"/>
		<updated>2012-10-17T11:49:54Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Adminsitration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things available, useful plugins and extra blocks and so on, but the majority of those things are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to ake things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy the code for them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101357</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101357"/>
		<updated>2012-10-17T11:48:28Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Adminsitration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]As a newbie Administrator, it is easy to get overwhelmed with all the different things avaiable, plugins, blocks and so on, but the majority of those plugins and blocks are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thumb, the further you move away from the standard Moodle, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to ake things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy the code for them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101356</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101356"/>
		<updated>2012-10-17T11:47:29Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Adminsitration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
As a newbie Administrator, it is easy to get overwhelmed with all the different things avaiable, plugins, blocks and so on, but the majority of those plugins and blocks are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thimb, the further you move away from the standard Moolde, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]&lt;br /&gt;
&lt;br /&gt;
Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to ake things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy the code for them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101355</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101355"/>
		<updated>2012-10-17T11:46:54Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* What kind of technical skills do I need to take on Moodle Adminsitration? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
As a newbie Administrator, it is easy to get overwhelmed with all the different things avaiable, plugins, blocks and so on, but the majority of those plugins and blocks are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thimb, the further you move away from the standard Moolde, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]]&lt;br /&gt;
&lt;br /&gt;
 Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to ake things easy. Try things there first, if there is no problems, then you can replicate it on your production site.&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy the code for them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101354</id>
		<title>Beginning Moodle 2.0 Administration</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.0_Administration&amp;diff=101354"/>
		<updated>2012-10-17T11:46:17Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The pages began life with the [https://docs.moodle.org/19/en/Beginning_Administration_FAQ Beginning v1.9 Administration FAQ] pages but are aimed specifically at Moodle 2.x. Many of the solutions to problems will work in both versions of Moodle so if you do not find something here, then you may find it in the other pages.  &lt;br /&gt;
&lt;br /&gt;
===What kind of technical skills do I need to take on Moodle Adminsitration?===&lt;br /&gt;
Reading and writing are handy skills, and probably the most useful. This is something of a loaded question, and the answer is actually, depends on what you want to do, and what skills you already have. &lt;br /&gt;
&lt;br /&gt;
Do you have any HTML, CSS and PHP skills? Do you have any SQL database skills. If you do, then you have a good start, if you do not, then do not worry about it. You will pick these skills up as you go. Unless you intend on developing your Moodle, build your own home made theme, alter code to reflect your own organization, then you can get away without any of these skills. What you need is a way of developing a quick understanding of how Moodle works. With the introduction of Moodle v2, the learning curve has steepened somewhat, but it is still not that difficult. &lt;br /&gt;
&lt;br /&gt;
Installing and setting up a new Moodle is not as difficult as it used to be. Some servers and service providers do have problems, from time to time, but if you work with your ISP, and the Moodle Community, you will get your Moodle up and running. Once it is going, start looking at it. You won&#039;t break anything, unless you start deleting things. Your best bet would be to read the documents. Look at the page you are working on. Somewhere on that page is a link that points to &amp;quot;Moodle Docs for this page&amp;quot;. That is your best, most readily available, clues on how to do things. Once familiar with the environment, and how to get around it, how to get information on it, then the major steps have been taken, the rest is a continual refinement of that.        &lt;br /&gt;
&lt;br /&gt;
As a newbie Administrator, it is easy to get overwhelmed with all the different things avaiable, plugins, blocks and so on, but the majority of those plugins and blocks are third-party made, not Moodle.org in origin. Be aware that, as a general rule of thimb, the further you move away from the standard Moolde, the greater your risks of things going wrong. This does not mean the plugins are badly written, and some are really handy, just sometimes things go wrong. If you are going to use them, be deliberate in your choice, do not use them just because it might be a good idea. &lt;br /&gt;
&lt;br /&gt;
[[Image:lightbulb.png|frame|left|Tip]] Perhaps the best thing is that you create a Moodle on your desktop, or laptop, and you use that as a testbed. It should be the same version as your production site, to ake things easy. Try things there first, if there is no problems, then you can replicate it on your production site. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===I am being told that I need the &#039;&#039;&#039;intl php plugin&#039;&#039;&#039; to continue to install Moodle 2.x===&lt;br /&gt;
The intl.dll from Zend is part of the PHP 5.2.8 release and later. It is aimed at improving the internationalization of php pages and Moodle 2.x uses it as part of this process. If your install is on a local machine or network, then you can download the latest version of PHP and update your PHP. You then have to uncomment all the required dynamic extensions you need, including the php_intl.dll extension. The problem is then solved. If the install is on a host server, then you need to contact your host and ask them to do the same, As an alternative, you can unzip/untar the download file, copy and paste the intl.dll file to your php/ext folder and include the line:&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
in the Dynamic Extensions section of your php.ini file.&lt;br /&gt;
&lt;br /&gt;
You can also set the error level using:&lt;br /&gt;
  intl.error_level = E_WARNING &lt;br /&gt;
but this is not essential&lt;br /&gt;
&lt;br /&gt;
If you are using a Linux install, use your system package manager or specify compilation flag.&lt;br /&gt;
    * Debian 5.0 (&amp;amp; Ubuntu) use: apt-get install php-intl or apt-get install php5-intl &lt;br /&gt;
    * CentOS 5.5 (&amp;amp; RedHat) you should (probably) be using php 5.3 from remi and then use: yum install php-intl&lt;br /&gt;
&lt;br /&gt;
This technique can be applied to any updated dynamic extension from Zend. You may want to use later dll files in your php/ext folder, you can do so by doing the same as above, but be careful, your version may not be able to take full advantage of the extension, or some very new extensions may cause an unexpected instability. The best option is still to update on a regular basis, perhaps once a year or so for the PHP.&lt;br /&gt;
&lt;br /&gt;
===What Dynamic Extensions do I really need uncommented in my php.ini file? What else do I need to change?===&lt;br /&gt;
This assumes you have complete control over the installation and running of your server, if your Moodle is hosted, you need to do something different, which is also discussed below. In the php.ini you need to delete the semi-colon, the ;, from the start of any line to uncomment it. For Moodle, you really should only need to change some values, and make sure the extensions you require are available. These are:&lt;br /&gt;
&lt;br /&gt;
Resource Limits&lt;br /&gt;
  memory_limit = 128M     //This is the maximum it requires and on a shared server you may get much less. &lt;br /&gt;
&lt;br /&gt;
Data Handling &lt;br /&gt;
  post_max_size = 512M    //This allows postings of up to 512MB, but set it to suit yourself and your circumstances&lt;br /&gt;
&lt;br /&gt;
Paths and Directories&lt;br /&gt;
  doc_root =&amp;quot;driveletter:\path\to\server\active\web\directory&amp;quot;  (e.g. d:\Apache\htdocs or e:\iis\wwwroot )&lt;br /&gt;
  and&lt;br /&gt;
  extension_dir = &amp;quot;driveletter:\path\to\php\ext&amp;quot; (e.g. d:\php\ext or e:\iis\php\ext)&lt;br /&gt;
&lt;br /&gt;
File Uploads&lt;br /&gt;
  upload_max_filesize = 512M    (This is different from the post_max_size this is for file uploads.)&lt;br /&gt;
&lt;br /&gt;
Dynamic Extensions&lt;br /&gt;
{| class=&amp;quot;nicetable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! PHP 5.2.x (Moodle 1.9 with additions) &lt;br /&gt;
! PHP 5.3.x&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_exif.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_mcrypt.dll&lt;br /&gt;
  extension=php_mssql.dll&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  &#039;&#039;&#039;extension=php_intl.dll&#039;&#039;&#039;&lt;br /&gt;
  &#039;&#039;&#039;extension=php_zip.dll&#039;&#039;&#039;  ; Added Extensions&lt;br /&gt;
|&lt;br /&gt;
  extension=php_curl.dll&lt;br /&gt;
  extension=php_gd2.dll&lt;br /&gt;
  extension=php_gettext.dll&lt;br /&gt;
  extension=php_intl.dll&lt;br /&gt;
  extension=php_imap.dll&lt;br /&gt;
  extension=php_ldap.dll&lt;br /&gt;
  extension=php_mbstring.dll&lt;br /&gt;
  extension=php_exif.dll      ; Must be after mbstring as it depends on it&lt;br /&gt;
  extension=php_mysql.dll&lt;br /&gt;
  extension=php_mysqli.dll&lt;br /&gt;
  extension=php_openssl.dll&lt;br /&gt;
  extension=php_pdo_mssql.dll&lt;br /&gt;
  extension=php_pdo_mysql.dll&lt;br /&gt;
  extension=php_soap.dll&lt;br /&gt;
  extension=php_sockets.dll&lt;br /&gt;
  extension=php_sqlite.dll&lt;br /&gt;
  extension=php_xmlrpc.dll&lt;br /&gt;
  extension=php_zip.dll&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;NOTE:&#039;&#039;&#039; If you are using a PHP version earlier than v5.2.8, then for Moodle 2.0.x please add the Dynamic extensions of intl.dll and zip.dll as outlined above. Be aware this structure does &#039;&#039;&#039;not&#039;&#039;&#039; work in Moodle 2.1. &lt;br /&gt;
&lt;br /&gt;
These edits and Dynamic extensions cover a range of options here, there are a number of other possibilities, but these listed are the most common ones. Unless you have a specific need, there may not be any reason to deviate from these settings, but if you do, make sure you know what is going to happen. These extensions will also allow you to successfully install and run many other PHP applications. &lt;br /&gt;
&lt;br /&gt;
One example is the Oracle extensions are not shown here, but Oracle can be used for the Moodle database. Another area people often get themselves into trouble is using &amp;quot;Magic quotes&amp;quot;. Magic quotes really should be set to off, they were only introduced early in the use of PHP to allow for some inexperienced scripting practices, (read poor, shoddy or dodgy here). If someone is still writing poor scripts, then they deserve to draw attention to themselves and their scripts deleted.&lt;br /&gt;
&lt;br /&gt;
===My Host took my Moodle 2 down from the server due to an overload of the database.===&lt;br /&gt;
This happens far too often on shared servers. The additional memory requirements of Moodle 2+ for installation and the additional database storage required is going to make it worse. The best bet is to find a dedicated server, that is the optimum, but reality is that costs do play a large part in making decisions about where a Moodle will be stored. A dedicated server will give you the entire disc space and all the memory on that server to use as you need. A virtual dedicated server means you are sharing with a few other users on a server, possibly as many as 10, but more likely 5 or 6. A shared server mean you are sharing one box with as many of the Host&#039;s clientele that can be put onto one server. This means sharing all resources and Moodle&#039;s demands get higher as the number of Users increases which affects all other Clients of the Host. There are any number of Moodle Partners who may be willing to host your Moodle, and the Internet also means you are not restricted by national or natural boundaries or currency transactions - politics, oceans and banks have no impact on where you host your Moodle.&lt;br /&gt;
&lt;br /&gt;
===Why am I having trouble restoring my existing Moodle 1.9.x courses into Moodle 2.0?===&lt;br /&gt;
Simply put, the changes in coding between Moodle 1.9.x and Moodle 2.0 are large. Additional security has forced changes to the backup processes. In just looking at the databases there are an additional 60 or more tables, so that creates a number of restoring issues alone. To bring Moodle 1.9.x courses into Moodle 2.0 is a monumental challenge, and full credit to those who are trying it. There is, currently, one commercial Windows based solution but it is not fully successful in its restoration of courses. &lt;br /&gt;
 &lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039; Moodle 2.0 can backup and restore courses from within itself perfectly, the issue appears to be centred on v1.x.x courses.&lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;UPDATE:&#039;&#039;&#039; Moodle 2.1 was released on July 1, 2011 and can now restore course files from backups made in v1.9.x. Student file restorations are not yet available but are expected to be included in v2.2 to be released November, 2011.&lt;br /&gt;
&lt;br /&gt;
===How do I look up the error logs in Moodle 2.0?===&lt;br /&gt;
First, turn the error logs on, go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Development ► Debugging&lt;br /&gt;
&lt;br /&gt;
and set error messages to DEVELOPER: .... Then go to&lt;br /&gt;
&lt;br /&gt;
  Site administration ► Reports ► Logs&lt;br /&gt;
&lt;br /&gt;
set your report options to Home 2.0(Site), All Participants, All Activities or Site Errors, View, Display on Page and then click, &amp;quot;Get these logs&amp;quot;. The report should give you something, and you may be able to develop an appropriate response from there.&lt;br /&gt;
&lt;br /&gt;
===Do I try to upgrade to Moodle 2.0 or just create a new install?=== &lt;br /&gt;
There is always debate around these issues, but simply put, Moodle 2.0 is a complete re-write of a tried and tested tool. This presents its own challenges, obviously, and those challenges need be met in the best way we can. It is a temptation to go all in and jump to the new tool, but this can be a dangerous practice when dealing with a lot of people who are resistant to change, and the change from Moodle 1.9.x to 2.0 is massive.&lt;br /&gt;
  Upgrading to Moodle 2.0 has always been an option, but make sure your environment will meet the newer specifications. &lt;br /&gt;
Consider your own circumstances. Are you starting out on the Moodle journey or have you just been dropped into it? Perhaps you are starting out, and you have no resources or courses and you are building for the next few months when you want it to become a part of your learning centre and a showpiece for your institute. A complete new Moodle 2.x.x install and starting from scratch is most appropriate in this circumstance. All major features work in it and some of the tools are a lot more interesting than for Moodle 1.9.x. &lt;br /&gt;
  Don&#039;t worry about Moodle 1.9.x, just use the new Moodle 2.x.x and learn it if you are starting from scratch.&lt;br /&gt;
If you have been dropped into it, and have a lot of courses, and you need to administer your Moodle 1.9.x as well as look at updating, then the next best option is to install a new Moodle and open it just for your Administrators and Staff. Let them get used to the new interface, develop training courses around the new Moodle, not just for staff but for Users as well. Aim at your staff first, let them learn it then they can be more confident in using the new Moodle when they come to teaching their Users/Students. &lt;br /&gt;
  In short, best advice is NOT to install a Moodle 2.0 as a production site without thoroughly testing and training first. &lt;br /&gt;
To install and run more than one Moodle successfully is actually simple. Install your Moodle 2.0 and then go to &#039;&#039;&#039;&#039;&#039;Site administration &amp;gt; Server &amp;gt; Session handling&#039;&#039;&#039;&#039;&#039;. Look for the Cookie prefix dialogue and add a value to it. Repeat the exercise in every other Moodle you have on your server, it should all work as it is supposed to - as long as the cookie prefixes are different for every Moodle, of course. &lt;br /&gt;
&lt;br /&gt;
[[Image:cookieprefix.png|frame|center|Cookie prefix for Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Essentially, take your time and not be in too much of a rush if you have to convert your Staff and Learners to a new tool. Let the Staff get used to it first, then you can make the swap any time.&lt;br /&gt;
&lt;br /&gt;
If you do update your v1.9.x to v 2.0, and experience some problems, you may want to consider putting the issues and any error messages into a [http://tracker.moodle.org/secure/Dashboard.jspa Moodle Tracker item]. If you do, you may be providing information to resolve a number of updating issues for a lot of people.&lt;br /&gt;
&lt;br /&gt;
===Well, we want to try and upgrade to test our systems.===&lt;br /&gt;
Try, by all means. However, there are a couple of issues you may need be aware of. &lt;br /&gt;
&lt;br /&gt;
A rough guide and checklist: &lt;br /&gt;
#Plugins that work in Moodle 1.9.x may not be updated to Moodle 2.0. Check your plugins. Are you using any non-core plugins? &lt;br /&gt;
#Can you remove any non-core plugins? &lt;br /&gt;
#Have you backed up your database?&lt;br /&gt;
#Have you backed up your moodledata folder? &lt;br /&gt;
#Have you allocated additional time make the update, as a contingency?&lt;br /&gt;
&lt;br /&gt;
You may not necessarily have to remove the non-core plugins from the Moodle, or, they may still be present in the database even if you have deleted them from your Moodle Mod folder. The issue arising is that some plugins appear to be causing update errors as there is no matching core plugin from Moodle 2.0, or the plugin APIs are different and cannot accommodate the older plugins, or the older plugins that have not been properly maintained, cannot handle the newer environment. &lt;br /&gt;
&lt;br /&gt;
: &#039;&#039;&#039;NOTE:&#039;&#039;&#039;This is not meant to be an exhaustive checklist or to scare people off trying to upgrade their v1.9.x to v2.0.x, just be aware that Moodle 2.0 is still a work in progress, as is this checklist.&lt;br /&gt;
&lt;br /&gt;
===We have extensively used the Book for parts of our previous Moodle, can we do so for Moodle 2.0?===&lt;br /&gt;
The really good news is that Petr Skoda (Skodak) has the Maintainer role for the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=319&amp;amp;filter=1 Book plugin/module]. Petr announced some time back that when his major coding tasks for Moodle 2.0 had been done, he was taking a short break then he would begin work on updating the Book for Moodle 2.0. &lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;UPDATE&#039;&#039;&#039;: Petr&#039;s updating of the Book module is now complete, and is available at the above link. Initial testing shows it installs easily and seems to run faster than the original. Seems the code has been better optimized by Petr, who deserves a hearty congratulations!!!&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; the book module is available as standard in Moodle 2.3&lt;br /&gt;
&lt;br /&gt;
===That is OK for the Book, but what about other plugins and blocks?===&lt;br /&gt;
As a general rule-of-thumb, if a plugin or block has not been maintained through Moodle 1.9.x then it is extremely unlikely it will make it to Moodle 2.0.x. This means the developer has not kept it current and may feel it is too much of a distraction from their current projects to keep active. This does not mean that you, or someone else, may not take it on, as long as you ensure that what you are working with is creative commons, open source or other non-proprietal software and you are not infringing either copyright or intellectual property rights. If you are not sure, try to contact the developer or last maintainer, they may be different - if required, get permission from them to continue development. Of course, you may also seek to develop an entirely new plugin, or block, but it is clear that it is actually duplicating something that already exists or was used in earlier versions of Moodle, but is no longer current. As long as you can prove the provenance of such a plugin or block, and do not use any code from anywhere else that is not original or acknowledged where the code came from, then you should be OK. For ideas and guidelines around developing or updating a plugin, look at this page from [https://docs.moodle.org/dev/Developer_documentation Developer Documentation].  You can also join a [http://dev.moodle.org/ class of developers] and learn how it can be done.&lt;br /&gt;
&lt;br /&gt;
===I am getting error messages about plugins and the installation stops when upgrading. What do I do?===&lt;br /&gt;
Quite frequently, not a lot at all, you can just continue on. Many of these messages are just that, messages, they are not supposed to stop or break the installation, they are just warnings that not all is working as you may be used to in an install. Usually they relate to plugins that are not part of Moodle 2.0 yet. Moodle is designed to display a message, but continue on. Or, you can consider that, given the above, upgrading is not really viable and just do a fresh install. If those messages continue, then you have another problem. If there were database errors, or code errors, then it is different, you really do need to stop and investigate.&lt;br /&gt;
&lt;br /&gt;
===We are installing Moodle and getting error messages about not using the unicode or UTF-8 charset===&lt;br /&gt;
In recent times, this has become an issue with CPanel and Fantastico installers on some Linux servers. Apparently the default charset for these tools is a latin_swedish_ci charset. Moodle requires the UTF-8 charset. This is a relatively simple fix, if you have the right tools. Install phpMyAdmin and check it is working, if you do not already have it. You can then go to the SQL page and enter the following code:&lt;br /&gt;
  ALTER DATABASE `moodle` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;&lt;br /&gt;
There have been, in the past, reports of tables that do not change using this SQL code, so try:  &lt;br /&gt;
  ALTER TABLE `mdl_tablename` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci; &lt;br /&gt;
There have been no reasons as to why some tables are missed, but you can alter individual tables by using the code above. The code should look something like: &lt;br /&gt;
&lt;br /&gt;
[[Image:altertablesqlm202.png|frame|center|Changing the charset in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;This also works in Moodle 1.9.x IF you use the utf8_general_ci charset.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; This SQL is supposed to work across the database, but recent reports suggest that the ALTER DATABASE seems to have a number of issues stemming from problems with the GRANT command. GRANT &amp;lt;nowiki&amp;gt;[permissiontype]&amp;lt;/nowiki&amp;gt; is supposed to allow a user to access the entire database, but it no longer appears to be the case. The ALTER TABLE SQL has not been affected by this issue.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FURTHER NOTE:&#039;&#039;&#039; When using the ALTER DATABASE SQL, it appears to be diverted to altering the &#039;&#039;db.opt&#039;&#039; file, but is not continued into the tables of the database. So whether this is a deliberate security feature of more recent editions of MySQL or not is, at this stage, unknown. How this affects Postgres, or Oracle databases is also unknown.&lt;br /&gt;
&lt;br /&gt;
===OK, but how can we tell what tables are not converted?===&lt;br /&gt;
Using phpMyAdmin, you can find out almost anything you like about your database, as long as you know where to look. There is some real documentation about using phpMyAdmin that is linked both in the left and right panels. Go to the Database tab and then select the database you want to look at.&lt;br /&gt;
&lt;br /&gt;
[[Image:selectdatabasetab.png|thumb|150px|frame|center|Selecting the database tab in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Once selected, you will see what the charset is of each table. Any table that does not comply you can change using the table SQL code above. &lt;br /&gt;
&lt;br /&gt;
[[Image:phpmyadmintablelisting.png|frame|center|Checking the table listings in phpMyAdmin]]&lt;br /&gt;
&lt;br /&gt;
===How do I get and install phpMyAdmin?===&lt;br /&gt;
phpMyAdmin is another very useful plugin. In Moodle 2.0 the plugin has been updated and is now located in a different place than it was in earlier versions. Go to the [http://moodle.org/mod/data/view.php?d=13&amp;amp;rid=448&amp;amp;filter=1 phpMyAdmin page in Modules and Plugins] and download the Moodle 2.0 version. Unzip it to the &#039;&#039;&#039;moodle/local&#039;&#039;&#039; folder and then go to &#039;&#039;&#039;Notifications&#039;&#039;&#039;. Moodle will then tell you it has been successfully installed. If you look in Administration &amp;gt; Server you will now find a line &amp;quot;phpMyAdmin&amp;quot;. To access your database, click the link. &lt;br /&gt;
&lt;br /&gt;
===When I update over a 1.9 install, I get an error message about an incompatible plugin and it all stops. What can I do?===&lt;br /&gt;
&lt;br /&gt;
One piece of advice is that you just do not do that!&lt;br /&gt;
&lt;br /&gt;
Sometimes, a file/folder will be removed from the code between one version of Moodle and the next. If you upgrade Moodle by copying the new Moodle code over the top of the old code, then the older files not duplicated or no longer existent, or just disused and dropped, will remain, and can break things.&lt;br /&gt;
&lt;br /&gt;
The correct way to upgrade is (assuming your Moodle code is in a folder called &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; on the server:&lt;br /&gt;
# Upload the new code onto the server into a folder with a temporary name, like &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;.&lt;br /&gt;
# Copy the &amp;lt;tt&amp;gt;config.php&amp;lt;/tt&amp;gt; file from the moodle folder to the &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; folder.&lt;br /&gt;
# For any third-party plugins you have installed, copy the code for them into &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt;. (Make sure the plugin is compatible with the version of Moodle you are upgrading to.)&lt;br /&gt;
# Then rename the &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt; folder to &amp;lt;tt&amp;gt;moodle_old&amp;lt;/tt&amp;gt;, and then rename &amp;lt;tt&amp;gt;moodle_new&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;moodle&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you insist though, then you can expect to be getting all sorts of error messages. Given the fundamental changes to the database and the manner in which plugins are structured, and employed, in Moodle 2.0.x this is a very time consuming and, ultimately, futile (I would suggest) approach. You can, of course, remove all non-core plugins, and their corresponding tables from the database, and then you give yourself a chance at getting through it somewhat less scathed, but I doubt it.&lt;br /&gt;
&lt;br /&gt;
===What is happening to my uploaded files? I cannot see them in the moodledata folder!===&lt;br /&gt;
To improve security, Moodle has change how files are stored in the moodledata folder. There are there, but no longer obvious. When a file is uploaded it is given a storage name, an encrypted name, and it is placed into a specific folder within the moodledata folder. That folder&#039;s name is directly related to the file storage name. So we have a file with an encrypted name, inside a folder with a related name, inside the moodledata folder. Now comes the nifty part, these encrypted names are used as connections to the database. The database stores those encrypted names as aliases for the files and uses them to link the files to the courses. You see them, but you do not see them, well they are not obvious. Unfortunately, you cannot edit them in place, like you could files in Moodle 1.9.x you have to edit them, delete the older file and upload the new ones.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.x Administration 2 FAQ |  Beginning Moodle 2.x Administration 2 FAQ ]] &lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=100656</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=100656"/>
		<updated>2012-09-23T11:54:29Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How can I extract original files from a Moodle backup file? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.0, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should then be able to get into your Moodle then, as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How can I extract original files from a Moodle backup file?===&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), here it goes...&lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, let&#039;s assume there is a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder have been extracted. There is a PDF file named &amp;quot;Leadership.pdf&amp;quot; that is required for another purpose.&lt;br /&gt;
&lt;br /&gt;
Open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in this case is found under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which was previously extracted), and there is a file named &amp;quot;fb6cf43a9b...&amp;quot;. Rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location. Repeat this for all the files required, using the correct contenthash value of course.&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
===How can I have two installations of Moodle on my server?===&lt;br /&gt;
&lt;br /&gt;
There is always a number of reasons why you may require several different versions of Moodle on your server, or your localhost on a standalone computer. You may want to run two completely different Moodles for different purposes, so they may be the same versions. The answers are the same for all of them, and you may want to use different techniques depending on your circumstances. &lt;br /&gt;
&lt;br /&gt;
First, in all versions of Moodle you are able to set the cookie prefix. Whenever you install a Moodle, it is a good idea to not just accept the default for the cookie prefix. Go to Administration menu &amp;gt; Server &amp;gt; Session Handling and you will see there is a text box that allows you to add a prefix for the Moodle. If you do this for every installation, you can have any number of installations - the problem is going to be the database.  &lt;br /&gt;
&lt;br /&gt;
At installation, you can create two different databases. again in some circumstances, there may be any number of valid reasons to do this, but fact is, you may not, in v2.x have to worry about it too much. Each installation will generate its own tables so, at installation, you may not have to worry too much apart from giving the databases different names.&lt;br /&gt;
&lt;br /&gt;
===How can I deny Guest Access to my site altogether?===&lt;br /&gt;
&lt;br /&gt;
Look at Site administration ► Plugins ► Authentication ► Manage authentication and there is a switch there that allows you to turn the Guest Access button off altogether.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=100655</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=100655"/>
		<updated>2012-09-23T11:48:27Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How can I have two installations of Moodle on my server? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.0, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should then be able to get into your Moodle then, as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How can I extract original files from a Moodle backup file?===&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), here it goes...&lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, lets assume I have a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which I already extracted the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder, and that I&#039;m looking for a PDF file named &amp;quot;Leadership.pdf&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
So I open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in my case I find under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. I take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, I open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which I previously extracted), and there I will find a file named &amp;quot;fb6cf43a9b...&amp;quot;, so now I can rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location (where I&#039;ll gather all the files I need from the backup).&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
===How can I have two installations of Moodle on my server?===&lt;br /&gt;
&lt;br /&gt;
There is always a number of reasons why you may require several different versions of Moodle on your server, or your localhost on a standalone computer. You may want to run two completely different Moodles for different purposes, so they may be the same versions. The answers are the same for all of them, and you may want to use different techniques depending on your circumstances. &lt;br /&gt;
&lt;br /&gt;
First, in all versions of Moodle you are able to set the cookie prefix. Whenever you install a Moodle, it is a good idea to not just accept the default for the cookie prefix. Go to Administration menu &amp;gt; Server &amp;gt; Session Handling and you will see there is a text box that allows you to add a prefix for the Moodle. If you do this for every installation, you can have any number of installations - the problem is going to be the database.  &lt;br /&gt;
&lt;br /&gt;
At installation, you can create two different databases. again in some circumstances, there may be any number of valid reasons to do this, but fact is, you may not, in v2.x have to worry about it too much. Each installation will generate its own tables so, at installation, you may not have to worry too much apart from giving the databases different names.&lt;br /&gt;
&lt;br /&gt;
===How can I deny Guest Access to my site altogether?===&lt;br /&gt;
&lt;br /&gt;
Look at Site administration ► Plugins ► Authentication ► Manage authentication and there is a switch there that allows you to turn the Guest Access button off altogether.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=100627</id>
		<title>Beginning Moodle 2.x Administration 2 FAQ</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/2x/ca/index.php?title=Beginning_Moodle_2.x_Administration_2_FAQ&amp;diff=100627"/>
		<updated>2012-09-21T00:52:17Z</updated>

		<summary type="html">&lt;p&gt;ColinFraser: /* How can I have two installations of Moodle on my server? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page is a follow on from the Beginning Moodle 2.0 Administration page.&lt;br /&gt;
&lt;br /&gt;
===How do I create a repository?===&lt;br /&gt;
To setup and use a repository in Moodle 2.0, is not complex, just detailed. What follows will set up a site wide repository, that is the contents of this repository will be available to the entire site - so make sure this is really what you want. This is for the kind of resources you may want to use across a number of courses. &lt;br /&gt;
&lt;br /&gt;
1. In the moodledata folder there is a folder called Repository. Create whatever folders you want in there, but it is suggested you use a consistent naming convention, so everyone knows what type of materials reside there, e.g. CalculusPDFs, EnglishCivilWarDocs, and so on. You can copy the required materials into each folder as you create them or add to it at any time thereafter. &lt;br /&gt;
&lt;br /&gt;
2. In your Moodle 2.0 there are a couple of things you need to do, but first you have to activate the user repository system by going to &#039;&#039;&#039;Site Administration &amp;gt; Plugins &amp;gt;Repositories &amp;gt; Manage Repositories&#039;&#039;&#039; and you will see in the list contained in the right-hand panel an item named &amp;quot;File System&amp;quot;. Select the dropdown list box and change the value to &amp;quot;Enabled and visible&amp;quot;&lt;br /&gt;
[[Image:repository01.png|frame|center|Setting the File System Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
3. Click the &amp;quot;Settings&amp;quot; link and that will take you to the &amp;quot;Setup repository on file system&amp;quot; page. Click the &amp;quot;Create a Repository Instance&amp;quot; button and this will take you to the next page. On that page you have two text boxes and two buttons. Add the name of the repository you created in the Repository folder and click &amp;quot;Save&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
[[Image:repository02.png|frame|center|Saving the new Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
When you return to the &amp;quot;Setup repository on file system&amp;quot; page, you will now see that a list of repositories is available. When you access any course file or image picker, the repository will be available to you under the name you have given it. Any file inside the repository will be available for uploading to your course.&lt;br /&gt;
&lt;br /&gt;
===How do I set up a course repository?===&lt;br /&gt;
Setting up the Course repository is almost exactly the same, but the major difference is that is should only be accessible to that one course. &lt;br /&gt;
&lt;br /&gt;
Create a folder in your moodledata/Repository folder, naming it whatever is relevant. Add the files you want in that repository as you create the folder, or you can add them later. &lt;br /&gt;
&lt;br /&gt;
In the Course Administration menu, click the Repository item which takes you to the &amp;quot;Course Repositories&amp;quot; page. You will see a list of all available Repositories so you can access one of them if you chose, or you can select the Create A Repository Instance, Create a &amp;quot;FileSystem&amp;quot;  instance link. This takes you to the same page as shown above.  &lt;br /&gt;
&lt;br /&gt;
[[Image:repository03.png|frame|center|Creating a new Course Repository in Moodle 2.0]]&lt;br /&gt;
&lt;br /&gt;
Create your repository instance in the same manner as described above and when you return to the Course Repositories page, you will see your repository listed there. &lt;br /&gt;
&lt;br /&gt;
When you are adding a file to your course from the repository, you can access the stored file from the image or file picker via your repository. The repository is not available outside the course you create it  for.&lt;br /&gt;
&lt;br /&gt;
===How do I set the maximum upload file size limit?===&lt;br /&gt;
This is probably the most frequently asked question, and the answer is not that straightforward. The changes that need be made are the same in all versions of Moodle, just in different OS&#039; they need be made in different places. Upload file sizes are restricted in a number of ways and each one in this list restricts the following ones: &lt;br /&gt;
  Server level&lt;br /&gt;
  Moodle site level&lt;br /&gt;
  Course level&lt;br /&gt;
  Activity level&lt;br /&gt;
&lt;br /&gt;
Perhaps the best place to find this information is at [[File_upload_size|File upload size]] There is a full explanation for a number of different OSs but there are a few missing. &lt;br /&gt;
&lt;br /&gt;
This is a contentious issue, mainly because you might think that it should be set inside the Moodle. Unfortunately, this is not so, these are environment issues that need to be set in the server and PHP folders, Moodle cannot work outside itself.&lt;br /&gt;
&lt;br /&gt;
===The previous answer is OK if you control the server, but I am hosted, what can I do to override limitations set by my Host?===&lt;br /&gt;
Before doing this, consult with your host, they may have very different ideas about what your Moodle should be permitted - try not to tread on their toes - they may get annoyed at you breaching your user conditions. In an Apache server, you can create a file called &#039;&#039;&#039;.htaccess&#039;&#039;&#039; which can allow you to override some of the limitations set by PHP on your Moodle. Be aware that this file only applies to your Moodle, and nothing else. Your host will often place a .htaccess file into your root folder which will usually read something like: &lt;br /&gt;
  deny from all&lt;br /&gt;
  AllowOverride None&lt;br /&gt;
These are security related, so there is no need to delete them or otherwise edit them. To overwrite set values in the hosts php.ini file, you may want to use:&lt;br /&gt;
  php_value upload_max_filesize 512M&lt;br /&gt;
  php_value post_max_size 512M &lt;br /&gt;
  php_value memory_limit 128M&lt;br /&gt;
To overwrite boolean or logical settings use: &lt;br /&gt;
  php_flag register_globals off&lt;br /&gt;
or&lt;br /&gt;
  php_flag register_globals 0&lt;br /&gt;
&lt;br /&gt;
Something similar can be done in IIS, but it is a lot more complex. &lt;br /&gt;
&lt;br /&gt;
Thanks Muano&lt;br /&gt;
&lt;br /&gt;
===Can I still use the TeX Notation filter in Moodle 2 like I did in Moodle 1.9?===&lt;br /&gt;
Yes, you can. In fact there is very little that has changed in the changing version. Not that the TeX filter has not be changed, it certainly has, but it does not affect how you will   [[Using_TeX_Notation|use TeX Notation]]. It is supposed to be easier to add a third party plugin for TeX, but the relationship between Moodle and such tools as MathJax or Geogebra, or similar tools, is still to be determined.&lt;br /&gt;
&lt;br /&gt;
:UPDATE: Mauno Korpelainen has successfully integrated a number of Maths tools onto Moodle. These tools include Geogebra, JSXGraph, Math, MathML, MathTran, tex, DragMath, Geonext, JSQuery, MathJax and if that were not enough, Mauno had also included a version of TinyMCE that has, as native, a Maths editing toolbar. Further information can be found on the Moodle 2 [[Advanced Maths Tools]] page.&lt;br /&gt;
&lt;br /&gt;
===I want to change our logo and some other images but there seems no clear way of doing it.===&lt;br /&gt;
Moodle 2 has done things very differently here. Logos and other images are all controlled by the theme. Each theme folder is constructed the same way so it makes it easy to edit. Native Moodle themes use the moodle/pix folder to store common images. Look in there to find the logo for any native theme and that can be replaced by a new logo. Third party themes often use the moodle/theme/pix folder to store images, including logos.    &lt;br /&gt;
&lt;br /&gt;
Go and look at the theme folder and in it you will find the name of the theme you are using. In it you will also find the sub-folders for different elements and you should find your layout folder contains most of the instructions for controlling the layout, the Styles folder controls the appearance and so on. Images used in the theme can all be located there as well, in the pix folder.    &lt;br /&gt;
&lt;br /&gt;
If you want to use a theme that does not have an image or a logo, just the default icons, then you are talking a serious revamp. For that, you need to look at the [https://docs.moodle.org/dev/Themes_2.0| Themes 2.0] page.&lt;br /&gt;
&lt;br /&gt;
===What about other elements of the Front Page?===&lt;br /&gt;
In some ways, Moodle 2 has made it easier to setup a front page the way you want it. Different themes will use different defaults, many moving away from the traditional three collumn, blocks, categories/courses, blocks, structure that pervaded Moodle 1.9. The Moodle 2 documentation has a more complete look at the [[Front page settings]] than can be viewed here. Also, for a better overview of how this can all be done at a site level, look at the [[Customising appearance]] pages.&lt;br /&gt;
&lt;br /&gt;
===My Password is not being accepted as valid. How can I login as an Admin?===&lt;br /&gt;
There are a couple of causes for this problem, but the main one seems to be we forget the jumble of passwords we are required to remember. There are also a number of ways of getting around it, as well. &lt;br /&gt;
&lt;br /&gt;
[http://moodle.org/mod/forum/discuss.php?d=18103 This discussion] covers just about all of them. There are a couple of scripts so be careful and use the right one if you need to. &lt;br /&gt;
&lt;br /&gt;
If you do not wish to use a script, then you can try this: &lt;br /&gt;
Using phpMyAdmin, enter the database and look for the mdl_users table. The first line of that table&#039;s data should be the Guest, and the password for Guest is &amp;quot;guest&amp;quot;, without the quote marks. Copy that password and then look for your identity. Paste the &amp;quot;guest&amp;quot; password over the top of yours when you locate it. You should then be able to get into your Moodle then, as an Admin.&lt;br /&gt;
It has been reported this does not work in every circumstance, but most. To get around that problem you might want to try commenting out the line &lt;br /&gt;
  $CFG-&amp;gt;passwordsaltmain =&lt;br /&gt;
That should then work.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===How can I extract original files from a Moodle backup file?===&lt;br /&gt;
If you really want to get original files from the backup file (an &amp;quot;.mbz&amp;quot; file) you downloaded (using the backup and restore feature), here it goes...&lt;br /&gt;
&lt;br /&gt;
The backup file can actually be opened with any zip/unzip program you can download. Once you open the file, you need to extract:&lt;br /&gt;
&lt;br /&gt;
    The files.xml file.&lt;br /&gt;
    The files directory (folder).&lt;br /&gt;
&lt;br /&gt;
Next step would be to open the &amp;quot;files.xml&amp;quot; file in a text editor, and:&lt;br /&gt;
&lt;br /&gt;
    Search for the name of each file you want to get.&lt;br /&gt;
    Take note of the value of the corresponding contenthash tag.&lt;br /&gt;
    In the &amp;quot;files&amp;quot; folder you extracted, locate the file whose name is the same as the value of the contenthash and which will always be located in a folder whose name corresponds to the two first characters of the file name.&lt;br /&gt;
&lt;br /&gt;
For example, lets assume I have a &amp;quot;backup_courses-120730.mbz&amp;quot; file of which I already extracted the &amp;quot;files.xml&amp;quot; file and the &amp;quot;files&amp;quot; folder, and that I&#039;m looking for a PDF file named &amp;quot;Leadership.pdf&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
So I open the files.xml file and:&lt;br /&gt;
&lt;br /&gt;
1. Search for the string &amp;quot;Leadership.pdf&amp;quot;, which in my case I find under the following &amp;amp;lt;file id...&amp;amp;gt; group tag:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;file id=&amp;quot;12345&amp;quot;&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;contenthash&amp;amp;gt;fb6cf43a9b2d432403c70a2cb4c340dbb6225631&amp;amp;lt;/contenthash&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;filename&amp;amp;gt;Leadership.pdf&amp;amp;lt;/filename&amp;amp;gt;&lt;br /&gt;
                :&lt;br /&gt;
  &amp;amp;lt;license&amp;amp;gt;allrightsreserved&amp;amp;lt;/license&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;sortorder&amp;amp;gt;1&amp;amp;lt;/sortorder&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/file&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. I take note of the corresponding contenthash value: fb6cf43a9b2d432403c70a2cb4c340dbb6225631.&lt;br /&gt;
&lt;br /&gt;
3. As the first two characters of the contenthash are &amp;quot;fb&amp;quot;, I open the &amp;quot;fb&amp;quot; folder inside the &amp;quot;files&amp;quot; directory (which I previously extracted), and there I will find a file named &amp;quot;fb6cf43a9b...&amp;quot;, so now I can rename that file as &amp;quot;Leadership.pdf&amp;quot;, and then move it to another location (where I&#039;ll gather all the files I need from the backup).&lt;br /&gt;
&lt;br /&gt;
Thanks to Guillermo Madero S for this answer.&lt;br /&gt;
&lt;br /&gt;
===How can I have two installations of Moodle on my server?===&lt;br /&gt;
&lt;br /&gt;
There is always a number of reasons why you may require several different versions of Moodle on your server, or your localhost on a standalone computer. You may want to run two completely different Moodles for different purposes, so they may be the same versions. The answers are the same for all of them, and you may want to use different techniques depending on your circumstances. &lt;br /&gt;
&lt;br /&gt;
First, in all versions of Moodle you are able to set the cookie prefix. Whenever you install a Moodle, it is a good idea to not just accept the default for the cookie prefix. Go to Administration menu &amp;gt; Server &amp;gt; Session Handling and you will see there is a text box that allows you to add a prefix for the Moodle. If you do this for every installation, you can have any number of installations - the problem is going to be the database.  &lt;br /&gt;
&lt;br /&gt;
At installation, you can create two different databases. again in some circumstances, there may be any number of valid reasons to do this, but fact is, you may not, in v2.x have to worry about it too much. Each installation will generate its own tables so, at installation, you may not have to worry too much apart from giving the databases different names.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
*[[Beginning Moodle 2.0 Administration | Beginning Moodle 2.0 Administration ]]&lt;br /&gt;
*[[:Category:Administrator | Index of all Administrator-related pages]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FAQ]]&lt;/div&gt;</summary>
		<author><name>ColinFraser</name></author>
	</entry>
</feed>