You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
961 lines
54 KiB
961 lines
54 KiB
13 years ago
|
<html lang="en">
|
||
|
<head>
|
||
|
<meta charset="utf-8" />
|
||
|
<title>Chamilo Installation Guide</title>
|
||
4 years ago
|
<link rel="stylesheet" href="../build/css/app.css" type="text/css" media="screen,projection" />
|
||
|
<link rel="stylesheet" href="../build/css/themes/chamilo/default.css" type="text/css" media="screen,projection" />
|
||
13 years ago
|
<link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
|
||
4 years ago
|
<link rel="stylesheet" href="../build/css/print.css" type="text/css" media="print" />
|
||
|
<script src="../build/app.js"></script>
|
||
8 years ago
|
</head>
|
||
15 years ago
|
<body>
|
||
10 years ago
|
<nav class="navbar navbar-default navbar-fixed-top">
|
||
|
<div class="container">
|
||
|
<div class="navbar-header">
|
||
|
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
|
||
|
<span class="sr-only">Toggle navigation</span>
|
||
|
<span class="icon-bar"></span>
|
||
|
<span class="icon-bar"></span>
|
||
|
<span class="icon-bar"></span>
|
||
|
</button>
|
||
|
<a class="navbar-brand" href="#">Chamilo - Documentation</a>
|
||
|
</div>
|
||
|
<div class="collapse navbar-collapse">
|
||
|
<ul class="nav navbar-nav">
|
||
|
<li class="active"><a href="index.html">Home</a></li>
|
||
13 years ago
|
<li ><a href="readme.html">About</a></li>
|
||
10 years ago
|
<li><a href="license.html">License</a></li>
|
||
11 years ago
|
<li><a href="credits.html">Credits</a></li>
|
||
10 years ago
|
<li ><a href="dependencies.html">Dependencies</a></li>
|
||
13 years ago
|
<li><a href="changelog.html">Changelog</a></li>
|
||
11 years ago
|
</ul>
|
||
10 years ago
|
</div><!--/.nav-collapse -->
|
||
13 years ago
|
</div>
|
||
10 years ago
|
</nav>
|
||
13 years ago
|
|
||
11 years ago
|
<div class="container">
|
||
8 years ago
|
<h1>Chamilo 1.11 - Installation Guide</h1>
|
||
15 years ago
|
|
||
12 years ago
|
<p>Thank you for downloading Chamilo</p>
|
||
15 years ago
|
<ul>
|
||
11 years ago
|
<li>You can test Chamilo LMS, as teacher, without installing it, on <a href="http://campus.chamilo.org">Free Campus</a></li>
|
||
15 years ago
|
</ul>
|
||
15 years ago
|
<p>This guide explains how to install Chamilo FREE. Please read this fully before proceeding with the installation.</p>
|
||
11 years ago
|
<p>Spanish: También puede leer <a href="installation_guide_es_ES.html">esta guía de instalación en español</a>.</p>
|
||
|
<p>French: Vous pouvez aussi lire <a href="installation_guide_fr_FR.html">ce guide d'installation en français</a>.</p>
|
||
10 years ago
|
<p>Italian: You can also read <a href="installation_guide_it_IT.html">this guide in Italian</a>.</p>
|
||
15 years ago
|
|
||
|
<h2><b>Contents</b></h2>
|
||
|
<ol>
|
||
|
<li><a href="#1._Pre-requisites">Pre-requisites</a></li>
|
||
15 years ago
|
<li><a href="#2._Installation_of_Chamilo_LMS">Installation of Chamilo LMS</a></li>
|
||
8 years ago
|
<li><a href="#3._Upgrade">Upgrade</a></li>
|
||
15 years ago
|
<li><a href="#4._Troubleshooting">Troubleshooting</a></li>
|
||
|
<li><a href="#5._Administration_section">Administration section</a></li>
|
||
|
<li><a href="#6._LDAP">LDAP </a></li>
|
||
14 years ago
|
<li><a href="#9._WIRIS_mathematical_formulas">Mathematical formulas with WIRIS</a></li>
|
||
14 years ago
|
<li><a href="#10._Xapian_fulltext_indexing">Full-text indexation with Xapian</a></li>
|
||
|
<li><a href="#11._Chamilo_rapid_ppt_conversion">Chamilo Rapid - PPT conversion system</a></li>
|
||
14 years ago
|
<li><a href="#12._Setting_cron_up">Setting chronological tasks</a></li>
|
||
9 years ago
|
<li><a href="#13._Changing_language_names_order">Changing the language's firstname/lastname order</a></li>
|
||
11 years ago
|
<li><a href="#14._Improving_files_download">Improving files download time</a></li>
|
||
10 years ago
|
<li><a href="#15._Videoconference">Videoconference</a></li>
|
||
9 years ago
|
<li><a href="#16._Rewrite">Rewrite configurations</a></li>
|
||
9 years ago
|
<li><a href="#17._Git_Upgrade">Upgrading from Git</a></li>
|
||
15 years ago
|
</ol>
|
||
|
|
||
|
<br />
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
|
<h2><a name="1._Pre-requisites"></a>1. Pre-requisites</h2>
|
||
|
|
||
15 years ago
|
Chamilo
|
||
15 years ago
|
can be installed on Windows, Linux, Mac OS X and UNIX servers
|
||
|
indifferently. However, we recommend the use of Linux server for
|
||
|
optimal flexibility, remote control and scalability. <br />
|
||
|
|
||
|
<br />
|
||
|
|
||
10 years ago
|
Chamilo is mainly a LMS running (the so called <span style="font-weight: bold;">AMP</span> trilogy): <br />
|
||
|
<ul>
|
||
9 years ago
|
<li><span style="font-weight: bold;">Apache 2.2+</span></li>
|
||
7 years ago
|
<li><span style="font-weight: bold;">MySQL 5.6+ or MariaDB 5+</span></li>
|
||
7 years ago
|
<li><span style="font-weight: bold;">PHP 5.5+ (7.2 recommended for greater efficiency)</span></li>
|
||
10 years ago
|
</ul>
|
||
15 years ago
|
<br />
|
||
8 years ago
|
All these pieces of software are free software and freely available. <br /><br />
|
||
15 years ago
|
To run Chamilo <span style="font-weight: bold;">LMS</span> on your server, you need to install WAMP, LAMP or MAMP:
|
||
15 years ago
|
<ul>
|
||
|
<li>To install <span style="font-weight: bold;">WAMP</span> (AMP on Windows), we recommend the <a href="http://www.apachefriends.org/en/xampp.html">XAMPP</a> .exe installer<a href="http://www.apachefriends.org/en/xampp.html"></a></li>
|
||
|
<li>To install <span style="font-weight: bold;">LAMP</span>
|
||
|
(AMP on Linux), use the Package manager of your favourite distribution (Synaptic, RPMFinder etc.).
|
||
|
For instance, on a Ubuntu server, use Shell or Synaptic following the
|
||
8 years ago
|
<a href="http://ubuntuguide.org/wiki/Ubuntu:Feisty#Apache_HTTP_Server">Ubuntuguide on Apache</a> and the following sections
|
||
|
</li>
|
||
15 years ago
|
<li>To install <span style="font-weight: bold;">MAMP</span> (AMP on Mac OS X), refer to the <a href="http://www.mamp.info/en/index.php">MAMP</a> dedicated website<a href="http://www.mamp.info/en/index.php"></a></li>
|
||
12 years ago
|
<li>Make sure you check the <a href="dependencies.html" title="Dependencies">Dependencies page</a> if you need to know the requirements in more precise way.
|
||
15 years ago
|
</ul>
|
||
|
<br />
|
||
|
|
||
12 years ago
|
<h3><span style="font-weight: bold;">MySQL or MariaDB database server</span></h3>
|
||
7 years ago
|
You will need a login and password allowing you to manage <em>and drop+create</em> a database. Usually, the default configuration on local computers is
|
||
9 years ago
|
to allow you to connect as root with an empty password. It is <b>HIGHLY RECOMMENDED</b> to change the password and define a user with access to
|
||
|
only a specific database. Please refer to the MySQL or MariaDB documentation in order to do this.<br />
|
||
|
<br />
|
||
|
<span class="text-muted">Chamilo versions prior to 1.9.0 required to choose between multiple databases and a deprecated single-database mode.
|
||
|
This has been cleaned up and simplified to one single database.</span><br />
|
||
7 years ago
|
<span class="text-muted">If you don't have create permissions for your database user, Chamilo will fail during
|
||
|
installation because, to maintain the database clear of any remains of other systems, it will try to drop it
|
||
|
before creating it again. This is explained in some detail in <a href="https://github.com/chamilo/chamilo-lms/issues/2172">this issue report</a></span><br />
|
||
8 years ago
|
|
||
|
<h3><span style="font-weight: bold;">Apache's redirects</span></h3>
|
||
7 years ago
|
Since version 1.10, Chamilo requires the web server to be able to deal with redirects. This is now very common within web platforms (be them CMS, LMS, ERP, etc) and allows them, between other things, to use URLs in an efficient and user-friendly manner.<br />
|
||
8 years ago
|
If you don't use Apache as a web server, go to section "Rewrite configurations" at the end of this document.<br />
|
||
|
If you do use Apache, configuring redirects is done in two small steps:
|
||
|
<ul>
|
||
|
<li>Enable the "rewrite" module in Apache (on the command line, run "<i>sudo a2enmod rewrite</i>")</li>
|
||
|
<li>Configure the Apache's VirtualHost for your Chamilo to include the following block, which will allow .htaccess files within Chamilo to be interpreted</li>
|
||
|
</ul>
|
||
7 years ago
|
For Apache <=2.2 (where /var/www/chamilo should be replaced by the path to your Chamilo install):
|
||
8 years ago
|
<pre>
|
||
|
<Directory />
|
||
|
AllowOverride All
|
||
|
Order allow,deny
|
||
|
allow from all
|
||
|
</Directory>
|
||
7 years ago
|
<Directory /var/www/chamilo/>
|
||
|
AllowOverride All
|
||
|
Order allow,deny
|
||
|
allow from all
|
||
|
</Directory>
|
||
8 years ago
|
</pre>
|
||
|
and for Apache >=2.4:
|
||
|
<pre>
|
||
|
<Directory />
|
||
|
AllowOverride All
|
||
|
Require all granted
|
||
|
</Directory>
|
||
7 years ago
|
<Directory /var/www/chamilo/>
|
||
|
AllowOverride All
|
||
|
Require all granted
|
||
|
</Directory>
|
||
8 years ago
|
</pre>
|
||
|
<br />
|
||
|
Once configured (and maybe this has already been done by your hosting provider), you can simply restart the web server to enable the change.
|
||
|
|
||
15 years ago
|
<hr style="width: 100%; height: 2px;" />
|
||
15 years ago
|
<h2><a name="2._Installation_of_Chamilo_LMS"></a><span style="font-weight: bold;">2. Installation of Chamilo LMS</span></h2>
|
||
9 years ago
|
<p>
|
||
|
Before you start installing Chamilo LMS, you must understand that, because we provide Chamilo as free software, many services providers
|
||
|
have been able to develop extensions of Chamilo, which have made it possible to install Chamilo in many ways:<br />
|
||
|
<ul>
|
||
|
<li>As an all-in-one package through an official provider, certified by the Chamilo Association</li>
|
||
|
<li>As an installable solution from one of many hosting providers who support cPanel with Scriptaculous</li>
|
||
|
<li>At your preferred hosting provider using remote installers like Installatron</li>
|
||
8 years ago
|
<li>Through a Docker container image</li>
|
||
9 years ago
|
<li>On your own server, downloading and installing manually</li>
|
||
|
<li>On your own computer, at home or at the office, just for testing or development</li>
|
||
|
</ul>
|
||
|
This guide only covers these 2 last methods. For other methods, you can always ask more information from the provider you will choose.
|
||
|
<br /><br />
|
||
|
To install, follow these 6 simple steps:
|
||
12 years ago
|
<ol>
|
||
9 years ago
|
<li><a href="https://chamilo.org/chamilo-lms/">Download Chamilo LMS</a></li>
|
||
15 years ago
|
<li>Unzip it</li>
|
||
9 years ago
|
<li>Copy the Chamilo directory in your web server's root directory. This can be
|
||
8 years ago
|
<span style="font-weight: bold;">C:\xampp\htdocs\</span> on a Windows server or <span style="font-weight: bold;">/var/www/html/chamilo</span> (or /var/www/chamilo/) on a Linux server (You need to create the folder "chamilo")</li>
|
||
9 years ago
|
<li>Verify your web server supports .htaccess files (see Rewrite section below)</li>
|
||
8 years ago
|
<li>Open your web browser and type
|
||
|
<span style="font-weight: bold;">http://localhost/chamilo/</span> if you install locally for test purposes or
|
||
|
<span style="font-weight: bold;">http://www.your-chamilo-domain.com</span> if you install remotely*
|
||
12 years ago
|
</li>
|
||
9 years ago
|
<li>Follow the web installation process. You can accept all default values. Consider changing the admin password to remember it. </li>
|
||
12 years ago
|
</ol>
|
||
9 years ago
|
|
||
8 years ago
|
<h3>Recommendations</h3>
|
||
|
<ul>
|
||
|
<li>We recommend defining a specific Virtual Host for this installation.</li>
|
||
|
<li>If you have to install multiple Chamilo instances, avoid the installation of Chamilo in a inside a folder, instead prefer the use of different domains or using subdomains examples:
|
||
|
<ol>
|
||
|
<li>http://www.my-domain.com/ (<i class="fa fa-check" aria-hidden="true"></i> recommended)</li>
|
||
|
<li>http://chamilo.my-domain.com (<i class="fa fa-check" aria-hidden="true"></i> recommended)</li>
|
||
|
<li>http://chamilo2.my-domain.com (<i class="fa fa-check" aria-hidden="true"></i> recommended)</li>
|
||
|
<li>http://www.my-domain.com/chamilo (<i class="fa fa-times" aria-hidden="true"></i> not recommended)</li>
|
||
|
<li>http://www.my-domain.com/chamilo2 (<i class="fa fa-times" aria-hidden="true"></i> not recommended)</li>
|
||
|
<li>http://chamilo.my-domain.com/my-chamilo/ (<i class="fa fa-times" aria-hidden="true"></i> not recommended)</li>
|
||
|
</ol>
|
||
|
</li>
|
||
|
</ul>
|
||
|
|
||
|
<br />
|
||
9 years ago
|
<span class="text-muted">
|
||
|
Note: if installing Chamilo locally using localhost or the IP address of your computer during the installation, you might get issues
|
||
|
while accessing from another computer. To avoid this, you can
|
||
|
<a href="https://beeznest.com/blog/2013/01/15/answering-to-different-addresses-with-chamilo/">apply a little change to your configuration file</a>.
|
||
|
</span>
|
||
8 years ago
|
|
||
|
|
||
|
<h3>Permissions</h3>
|
||
|
|
||
|
<p>The following directories need to be <b>readable, writeable and executable</b> by your web server.
|
||
|
This usually requires no specific action on Windows servers, but will require a "chmod" under Linux and Mac. See instructions below.</p>
|
||
9 years ago
|
Replace [chamilo] with the directory where your Chamilo installation is located):
|
||
15 years ago
|
<ul>
|
||
9 years ago
|
<li>[chamilo]/app/</li>
|
||
|
<li>[chamilo]/vendor/ (only needs to be readable and executable)</li>
|
||
|
<li>[chamilo]/web/</li>
|
||
10 years ago
|
<li>[chamilo]/main/default_course_document/images/</li>
|
||
15 years ago
|
</ul>
|
||
9 years ago
|
Optionally, you can do the same to the following directory if you want to
|
||
|
enable sub-languages definition:
|
||
15 years ago
|
<ul>
|
||
|
<li>[chamilo]/main/lang/</li>
|
||
15 years ago
|
</ul>
|
||
8 years ago
|
<p>
|
||
|
If you find a tests/ directory at the root of your package, please delete it.
|
||
11 years ago
|
This is a development directory that has not been checked for security issues,
|
||
8 years ago
|
an it should *never* be accessible to final users on a production server.
|
||
|
</p>
|
||
9 years ago
|
<p><span class="text-muted">On Linux, Mac OS X and BSD operating systems you can use the <em>chmod 0775</em> command for this (although we recommend you seek advice from an
|
||
|
experienced system administrator to avoid security issues). On Windows, you may need to check the properties of the folders (by right-clicking on them).</span></p>
|
||
15 years ago
|
|
||
|
|
||
9 years ago
|
<h3>Post-installation security checklist</h3>
|
||
15 years ago
|
|
||
|
<ul>
|
||
11 years ago
|
<li><strong>Protect your configuration folder: </strong>
|
||
11 years ago
|
make sure no one (but you) can overwrite it. You can find the config directory in
|
||
9 years ago
|
<em>(chamilo folder)</em>/app/config.
|
||
15 years ago
|
Make it read-only (windows/xwindows: right-click the file to edit the
|
||
12 years ago
|
properties. linux/bsd/macosx: use the chmod 0555 command). The config
|
||
11 years ago
|
file is created by your web server (Apache + PHP, usually) so you may
|
||
12 years ago
|
need to be root user to change its permissions.</li>
|
||
11 years ago
|
<li><strong>Configure your Chamilo portal: </strong>
|
||
11 years ago
|
in the administration section of Chamilo, you can use the Chamilo Configuration
|
||
|
Settings to adjust the behavior of your installation.</li>
|
||
4 years ago
|
<li>For stronger security tips, please check our new <a href="security.html">security guide</a> for more</li>
|
||
15 years ago
|
</ul>
|
||
|
|
||
|
<br />
|
||
|
|
||
|
|
||
|
<h3>PHP configuration</h3>
|
||
|
|
||
|
|
||
12 years ago
|
To get the best out of Chamilo, you need to finetune your PHP settings. Consider : <br />
|
||
15 years ago
|
|
||
|
<ul>
|
||
9 years ago
|
<li>Configuring Chamilo mail: Most of Chamilo uses the mail settings from the php.ini file. However,
|
||
|
if you use a distinct e-mail server, you might need to adjust the
|
||
|
e-mail setting in <em>(chamilo folder)</em>/app/config/mail.conf.php.</li>
|
||
15 years ago
|
|
||
9 years ago
|
<li>Editing php.ini file (on Windows can usually be located at
|
||
11 years ago
|
<span style="font-weight: bold;">C:\xampp\php\php.ini</span>,
|
||
|
on Ubuntu Linux :
|
||
14 years ago
|
<span style="font-weight: bold;">/etc/php5/apache2/php.ini</span></li>
|
||
9 years ago
|
<li>search the word "_max" and increase the following values to optimise the server</li>
|
||
15 years ago
|
</ul>
|
||
|
|
||
8 years ago
|
<pre>
|
||
|
max_execution_time = 300; Maximum execution time of each script, in seconds
|
||
|
max_input_time = 600; Maximum amount of time each script may spend parsing request data
|
||
|
memory_limit = 256M; Maximum amount of memory a script may consume (128MB)
|
||
|
post_max_size = 100M
|
||
|
upload_max_filesize = 100M;
|
||
|
short_open_tag = Off
|
||
|
safe_mode = Off
|
||
|
magic_quotes_gpc = Off
|
||
|
magic_quotes_runtime = Off</pre>
|
||
|
|
||
9 years ago
|
<p><strong>Important:</strong> You need to set
|
||
|
your <em>date.timezone</em> setting to whatever your server's timezone is. For example, if your server is in the 'America/New_York' timezone,
|
||
|
set the date.timezone parameter to this value in your php.ini:</p>
|
||
15 years ago
|
|
||
8 years ago
|
<pre>
|
||
15 years ago
|
date.timezone = 'America/New_York'
|
||
8 years ago
|
</pre>
|
||
9 years ago
|
<br />
|
||
|
<p><strong>Note:</strong> <span class="text-muted">PHP 5.3.9 introduces a new setting "max_input_vars", which limits the number of elements you can send in one single form. If you are dealing with numerous users or very long learning paths (many items), make sure you set this setting higher than its default value of 1000.</span></p>
|
||
15 years ago
|
|
||
9 years ago
|
<p><strong>BSD and CentOS users:</strong> these php libraries have to be included during the PHP installation (php5 might have to be replaced by php in some instances):</p>
|
||
15 years ago
|
<ul>
|
||
5 years ago
|
<li>php-session: The session shared extension for php</li>
|
||
|
<li>php-mysqlnd (or php5-mysqli): The mysql shared extension for php</li>
|
||
|
<li>php-zlib: The zlib shared extension for php</li>
|
||
|
<li>php-pcre: The pcre shared extension for php</li>
|
||
|
<li>php-xml</li>
|
||
|
<li>php-json</li>
|
||
|
<li>php-mcrypt</li>
|
||
|
<li>php-iconv or php-mbstring (either one of them)</li>
|
||
|
<li>php-gd The graphics-generation extension for PHP</li>
|
||
|
<li>php-intl The international behaviours extension for PHP</li>
|
||
|
<li>php-exif</li>
|
||
15 years ago
|
</ul>
|
||
|
|
||
15 years ago
|
<p>You might also add the following php modules and packages:</p>
|
||
|
<ul>
|
||
5 years ago
|
<li>php-ctype</li>
|
||
|
<li>php-ldap</li>
|
||
|
<li>php-xapian</li>
|
||
|
<li>php-curl</li>
|
||
|
<li>php-xsl</li>
|
||
15 years ago
|
</ul>
|
||
15 years ago
|
<hr />
|
||
8 years ago
|
<h2><a name="3._Upgrade"></a>3. Upgrade</h2>
|
||
9 years ago
|
|
||
12 years ago
|
Before upgrading, we <b>heavily</b> recommend you do a full backup of the previous
|
||
9 years ago
|
Chamilo directories and databases. If you are unsure how to achieve this
|
||
9 years ago
|
please ask your hosting provider for advice <b>before</b> you continue further.<br /><br />
|
||
8 years ago
|
|
||
9 years ago
|
<div class="text-muted"> NOTE: For very heavy Chamilo databases, some of our official
|
||
11 years ago
|
providers have developed improved migration procedures that use more memory but
|
||
9 years ago
|
process the upgrades much faster. If this is the kind of thing you
|
||
11 years ago
|
need, we highly recommend you contact them (see reference below).</div>
|
||
8 years ago
|
<br />
|
||
9 years ago
|
<div class="text-muted"> NOTE: This version of Chamilo can only be used to upgrade
|
||
8 years ago
|
from earlier versions of Chamilo 1.9.*. You cannot use the normal
|
||
8 years ago
|
upgrade scripts from Chamilo 1.11 to upgrade from Chamilo 1.8.* or even Dok€os 2.0
|
||
9 years ago
|
(which was born after the split with Chamilo). If you need this, please contact one
|
||
|
of the Chamilo Association's <a href="https://chamilo.org/providers">official providers</a>)</div>
|
||
15 years ago
|
<p></p>
|
||
|
|
||
8 years ago
|
<h3>3.1 Upgrading from Chamilo 1.11.x (Minor version)</h3>
|
||
|
As this is only a minor version change from previous 1.11.* versions of Chamilo, the only thing you need to do is:
|
||
12 years ago
|
<ul>
|
||
9 years ago
|
<li> check that you haven't left any customised stylesheet or image <span class="text-muted">(if you have, make sure you keep a copy on the side*)</span></li>
|
||
8 years ago
|
<li> download the Chamilo 1.11 install package from the <a href="http://www.chamilo.org/download">Chamilo download page</a></li>
|
||
|
<li> unzip the new files of Chamilo 1.11 over the files of the older version
|
||
|
(or unzip the files in one folder and then copy the files from there to the
|
||
|
older version's directory).</li>
|
||
|
<li> clean your app/cache/twig directory: delete all the contents *in* this directory (do NOT remove the directory itself, only its contents!).
|
||
|
It will all be re-generated.
|
||
|
You can also delete the contents of this directory through the "Archive directory cleanup" option in the "System" box of the Administration page.</li>
|
||
|
<li> you're done! No other upgrade procedure is required</li>
|
||
|
</ul>
|
||
|
<h3>3.2 Upgrading from Chamilo 1.10.x</h3>
|
||
|
<ul>
|
||
|
<li> check that you haven't left any customised stylesheet or image <span class="text-muted">(if you have, make sure you keep a copy on the side*)</span></li>
|
||
|
<li> download the Chamilo 1.11 install package from the <a href="http://www.chamilo.org/download">Chamilo download page</a></li>
|
||
|
<li> unzip the new files of Chamilo 1.11 over the files of the older version
|
||
10 years ago
|
(or unzip the files in one folder and then copy the files from there to the
|
||
|
older version's directory). Note that you should remove the "home" and
|
||
|
"searchdb" directories from the package before you overwrite the previous
|
||
|
files.</li>
|
||
9 years ago
|
<li> clean your app/cache/twig directory: delete all the contents *in* this directory (do NOT remove the directory itself, only its contents!). It will all be re-generated. You can also delete the contents of this directory through the "Archive directory cleanup" option in the "System" box of the Administration page.</li>
|
||
8 years ago
|
<li>Go to your portal install page (main/install/) and follow the upgrade procedure</li>
|
||
12 years ago
|
</ul>
|
||
9 years ago
|
Please note that if you (unluckily) upgraded from any of the 1.9 versions to 1.10.0 against our recommendations, we
|
||
|
provide a patch script that should get most of it in order. The script is available here:<br />
|
||
|
<a href="https://raw.githubusercontent.com/chamilo/chamilo-lms/1.10.x/tests/scripts/fix_migrations_1.9.x_1.10.0.php">https://raw.githubusercontent.com/chamilo/chamilo-lms/1.10.x/tests/scripts/fix_migrations_1.9.x_1.10.0.php</a> or, if
|
||
|
you are using a development version of Chamilo, directly into you tests/scripts/ folder. You should place the file
|
||
|
in the /tests/scripts/ folder, then edit it to remove the "die();" line, then launch it from your browser (after
|
||
|
connecting to your Chamilo site as admin). You should also remove the scripts afterwards.<br />
|
||
|
This script is provided without warranty. Please *always* take a backup before you use it.
|
||
12 years ago
|
<br />
|
||
|
|
||
8 years ago
|
<h3>3.3 Upgrading from Chamilo 1.9.x</h3>
|
||
|
|
||
|
<p>Chamilo LMS 1.11.x comes with a new database structure in comparison to 1.9,
|
||
|
as was the case between 1.9 and 1.8.
|
||
|
Although the upgrade script takes the migration in charge, it might be generating
|
||
|
a very heavy load on your server during the upgrade, and will change your
|
||
|
database considerably, preserving the data as well as possible (we have tested
|
||
|
the procedure many times, but remember this is GNU/GPLv3 and we cannot be held
|
||
|
responsible for what would happen to your data without professional supervision).
|
||
|
This is why we *really* recommend you take a full backup of your system before
|
||
|
you upgrade.</p>
|
||
|
|
||
|
Also note that Chamilo LMS 1.10 unites all language files from the
|
||
|
main/lang/ directory into one single file by language.
|
||
|
If you have changed language files directly (instead of
|
||
|
using the recommended way: sub-languages), you should take a backup copy of
|
||
|
these changed translations before you upgrade. Sublanguages might also require
|
||
|
some manual work, but the upgrade procedure will not touch sublanguages directly.
|
||
|
<br /><br />
|
||
|
|
||
15 years ago
|
<ul>
|
||
9 years ago
|
<li> make sure you don't have tables from previous versions of Chamilo still hanging around. These can cause the upgrade to fail. In particular, tables from versions 1.8.* could have multiple tables for each course, resulting in many tables with the same prefix. Only tables without prefix or with a "c_" prefix exist in 1.9 and superior versions. Make sure none of these tables persist. Take a backup of your database (just in case) and delete these prefixed tables (drop table ...).</li>
|
||
9 years ago
|
<li> check that you haven't left any customised stylesheet or image <span class="text-muted">(if you have, make sure you keep a copy on the side*)</span></li>
|
||
8 years ago
|
<li> download the Chamilo 1.11 install package from the <a href="http://www.chamilo.org/download">Chamilo download page</a></li>
|
||
|
<li> unzip the new files of Chamilo 1.11 over the files of the older version (or unzip the files in one folder and then copy the files from there to the older version's directory)</li>
|
||
|
<li> make *absolutely sure* that the .htaccess file of version 1.11 is copied as well</li>
|
||
9 years ago
|
<li> make sure "AllowOverride All" is present in your Apache configuration, as interpreting the .htaccess files is very important for Chamilo to work (note that the Order-Allow directive has been replaced by "Require all granted" in Apache 2.4)</li>
|
||
15 years ago
|
<li> point your browser on your portal URL + main/install/</li>
|
||
9 years ago
|
<li> click <span style="font-style: italic;">Install</span>, then choose <span style="font-style: italic;">Upgrade from 1.9.*</span></li>
|
||
9 years ago
|
<li> once your portal is upgraded, clean your app/cache/twig directory: delete all the contents *in* this directory (do NOT remove the directory itself, only its contents!). It will all be re-generated. You can also delete the contents of this directory through the "Archive directory cleanup" option in the "System" box of the Administration page.</li>
|
||
15 years ago
|
</ul>
|
||
9 years ago
|
|
||
15 years ago
|
<br />
|
||
|
|
||
9 years ago
|
<span class="text-muted">* Styles and images are located in the main/css or main/img
|
||
15 years ago
|
directories. You can still recover them from your backup if you have made it.
|
||
15 years ago
|
Any modified style or image that uses the default style/image name will be
|
||
|
overwritten by the next step. To avoid loosing your customisations, always
|
||
|
ensure you copy the styles/images under a new name and use and modify the
|
||
|
copy, not the original. The original will always be overwritten by newer
|
||
14 years ago
|
versions. In Dok€os 1.8.5, we have changed the name of several CSS themes.
|
||
15 years ago
|
Backwards compatibility is ensured by the fact that an upgrade only adds the
|
||
|
new themes, but you should try and use these new themes rather than sticking
|
||
12 years ago
|
to the old ones which will be deprecated shortly (not maintained).</span>
|
||
15 years ago
|
<br />
|
||
|
|
||
|
<p></p>
|
||
|
|
||
|
<p>
|
||
|
<b>WARNING:</b><br />
|
||
|
|
||
9 years ago
|
Do not delete the previous Chamilo installation directory before installing
|
||
9 years ago
|
the new one. The upgrade process should take care of all unrequired folders.</p>
|
||
15 years ago
|
|
||
8 years ago
|
<h3>3.4 Upgrading from Chamilo 1.8.x</h3>
|
||
8 years ago
|
To upgrade from version of Chamilo prior to 1.9.0, you will need to first upgrade them to 1.9.10.x, then upgrade again (separately) to 1.11.x.
|
||
8 years ago
|
You can find the 1.9.10.x packages here: <a href="https://github.com/chamilo/chamilo-lms/releases">https://github.com/chamilo/chamilo-lms/releases</a>
|
||
15 years ago
|
|
||
8 years ago
|
<p></p>
|
||
|
<h3>3.5 Directories permissions when upgrading from 1.9.x</h3>
|
||
15 years ago
|
|
||
|
The following directories need to be readable, writeable and executable for the web server:
|
||
|
<ul>
|
||
9 years ago
|
<li>[chamilo]/main/lang/ (in order to delete unnecessary language files)</li>
|
||
|
<li>[chamilo]/courses/ (in order to move the courses files to the app/courses folder)</li>
|
||
|
<li>[chamilo]/archive/ (in order to remove unnecessary files or move them to app/cache/)</li>
|
||
|
<li>[chamilo]/home/ (in order to move files to app/home)</li>
|
||
|
<li>[chamilo]/app</li>
|
||
9 years ago
|
<li>[chamilo]/web</li>
|
||
|
<li>[chamilo]/vendor</li>
|
||
10 years ago
|
<li>[chamilo]/main/default_course_document/images/</li>
|
||
15 years ago
|
</ul>
|
||
15 years ago
|
On Linux, Mac OS X and BSD operating systems you can quick-fix this using the
|
||
12 years ago
|
<em>chmod 0777</em> command, but if you are unsure, we recommend you seek advice for
|
||
9 years ago
|
your own OS on <a href="https://chamilo.org/forum">our forum</a>.
|
||
15 years ago
|
In Windows, you may need to check the properties of the folders.
|
||
|
<p></p>
|
||
|
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
|
|
||
|
<h2><a name="4._Troubleshooting"></a>4. Troubleshooting</h2>
|
||
|
|
||
|
|
||
8 years ago
|
<p>If you have problems, go to the <a href="https://chamilo.org">Chamilo website</a> and ask a question on the
|
||
9 years ago
|
<a href="https://chamilo.org/forum">support forum</a>. Please read the previous messages first to see if there is
|
||
12 years ago
|
already an answer to your question.</p>
|
||
15 years ago
|
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
|
<h2><a name="5._Administration_section"></a>5. Administration section</h2>
|
||
|
|
||
9 years ago
|
<p>To access the Chamilo administration section, open browser, go to your Chamilo adress and log in with the admin user.
|
||
|
Then you will see a "Administration" tab in the webpage header. You can manage users, courses, sessions, portal look
|
||
|
and feel, homepage content, course categories etc. there </p>
|
||
15 years ago
|
|
||
|
<p></p>
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
|
<h2><a name="6._LDAP"></a>6. LDAP</h2>
|
||
|
|
||
|
<p>
|
||
|
<i>This part is optional, only organisations with an LDAP server will need to read this.</i><br />
|
||
15 years ago
|
An LDAP module is already provided in Chamilo, but it has to be configured to make it work.</p>
|
||
15 years ago
|
|
||
|
|
||
|
<h3><b>Compiling</b></h3>
|
||
|
|
||
|
<p>
|
||
|
Linux servers: It's possible that you have to recompile php with ldap support.
|
||
|
Newer distributions also allow downloading rpms for additional packages.</p>
|
||
|
|
||
|
|
||
15 years ago
|
<h3><b>Activating LDAP in Chamilo</b></h3>
|
||
15 years ago
|
|
||
9 years ago
|
<p class="text-muted">Note: Please check
|
||
|
the LDAP configuration settings inside Chamilo to learn the details.</p>
|
||
15 years ago
|
|
||
|
|
||
8 years ago
|
In [Chamilo folder]/app/config/configuration.php, around line 93, you'll find settings like the following: <br />
|
||
|
<pre>
|
||
|
// -> Uncomment the two lines below to activate LDAP AND edit main/inc/conf/auth.conf.php for configuration
|
||
|
// $extAuthSource["extldap"]["login"] = $_configuration['root_sys'].$_configuration['code_append']."auth/external_login/login.ldap.php";
|
||
|
// $extAuthSource["extldap"]["newUser"] = $_configuration['root_sys'].$_configuration['code_append']."auth/external_login/newUser.ldap.php";
|
||
|
</pre>
|
||
15 years ago
|
|
||
|
remove the // from the last two lines to activate LDAP.<br />
|
||
8 years ago
|
|
||
15 years ago
|
|
||
|
|
||
|
<h3><b>Settings</b></h3>
|
||
|
|
||
|
<p>
|
||
|
Ask the LDAP server admin for the settings:</p>
|
||
|
|
||
|
<ul>
|
||
|
|
||
|
<li>ldap server name</li>
|
||
|
|
||
|
<li>ldap server port (usually 389)</li>
|
||
|
|
||
|
<li>ldap dc</li>
|
||
|
</ul>
|
||
|
Since 1.8.5, you have to change the LDAP settings inside the "Portal
|
||
15 years ago
|
administration" panel, under "Chamilo configuration settings", section
|
||
15 years ago
|
"LDAP".
|
||
|
<br />
|
||
|
|
||
|
As an example, you should find the following kind of values:<br />
|
||
|
|
||
|
LDAP main server's address: "myldapserver.com"; // your ldap server<br />
|
||
|
|
||
|
LDAP main server's port: 389; // your ldap server's port number<br />
|
||
|
|
||
|
LDAP domain: "dc=xx, dc=yy, dc=zz"; //domain<br />
|
||
|
|
||
|
<br />
|
||
|
|
||
|
|
||
|
<h3><b>Teacher/student status</b></h3>
|
||
|
|
||
|
<p>
|
||
15 years ago
|
By default, Chamilo will check if the "employeenumber" field has a value. If it has, then Chamilo will
|
||
15 years ago
|
consider this user as being a teacher.<br />
|
||
|
|
||
|
If you want to change this behaviour, you can edit main/auth/ldap/authldap.php, function ldap_put_user_info_locally(),
|
||
|
and change the <em>if (empty($info_array[$tutor_field]))</em> condition to whatever suits you.<br />
|
||
|
|
||
|
You can also remove this check by removing the condition and leaving only the <em>$status = STUDENT;</em> line.</p>
|
||
|
|
||
|
|
||
|
<h3><b>Protected LDAP servers</b></h3>
|
||
|
|
||
|
|
||
|
<p>
|
||
|
Some LDAP servers do not support anonymous use of the directory services.<br />
|
||
|
In this case, you should fill in the appropriate fields in the
|
||
15 years ago
|
administration panel (e.g. "manager" and "mypassword") and Chamilo will
|
||
15 years ago
|
try to authenticate using these, or fall back to anonymous mode before
|
||
|
giving up.</p>
|
||
|
|
||
|
|
||
|
<h3>LDAP import into sessions</h3>
|
||
|
|
||
|
<p>There is a new set of scripts now that allow you to insert users
|
||
15 years ago
|
from LDAP directly into a Chamilo session. This, however, relies on a
|
||
15 years ago
|
set of static choices in the LDAP contact attributes.<br />
|
||
|
|
||
15 years ago
|
The fields used intensively by the Chamlio module are:<br />
|
||
15 years ago
|
</p>
|
||
|
|
||
|
<ul>
|
||
|
|
||
14 years ago
|
<li>uid, which is matched to the username in Chamilo</li>
|
||
15 years ago
|
|
||
14 years ago
|
<li>userPassword, which is matched to the user password, although
|
||
15 years ago
|
this part will only work for non-encrypted passwords for now, but it
|
||
|
shouldn't be necessary if using the LDAP server as authentication</li>
|
||
|
|
||
14 years ago
|
<li>ou should end with the year of the person registration or any
|
||
15 years ago
|
criteria you will use to filter users, so that they can be retrieved on
|
||
|
that criteria</li>
|
||
|
|
||
14 years ago
|
<li>sn is used as the lastname field in Chamilo</li>
|
||
15 years ago
|
|
||
14 years ago
|
<li>givenName is used as the firstname field in Chamilo</li>
|
||
15 years ago
|
|
||
14 years ago
|
<li>mail is used as the email field in Chamilo</li>
|
||
15 years ago
|
</ul>
|
||
|
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="9._WIRIS_mathematical_formulas"></a>7. Mathematical formulas with WIRIS</h2>
|
||
14 years ago
|
<p>Installing this plugin you get WIRIS editor and WIRIS CAS. <br/>
|
||
8 years ago
|
This activation will not be completed unless you have previously downloaded the <a href="http://www.wiris.com/plugins/ckeditor/download" target="_blank">PHP plugin for CKeditor WIRIS</a> and unzipped its contents into the main/inc/lib/ckeditor/editor/plugins/ckeditor_wiris/ directory. <br/>This is necessary because Wiris is proprietary software and its services are <a href="http://www.wiris.com/store/who-pays" target="_blank">commercial</a>. To make adjustments to the plugin, edit configuration.ini file or replace his content by configuration.ini.default Chamilo file.</p>
|
||
14 years ago
|
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="10._Xapian_fulltext_indexing"></a>8. Full-text indexation with Xapian</h2>
|
||
14 years ago
|
<p>
|
||
|
<em>Note</em>: This step will require a dedicated server or a virtual dedicated server as the packages involved are not available on most shared hosting solutions.<br />
|
||
|
On Debian or Ubuntu 10.04 and superior, you will simply need to install the php5-xapian package and restart your web server:
|
||
|
<pre>
|
||
|
sudo apt-get install php5-xapian
|
||
|
sudo /etc/init.d/apache2 restart
|
||
|
</pre>
|
||
7 years ago
|
<p>
|
||
11 years ago
|
Then go to your administration page -> Configuration settings -> Search
|
||
|
and enable the search tool. Follow the recommendations on the page to get the
|
||
|
complete indexing suite installed. Once you're done, all documents you import
|
||
14 years ago
|
into your Chamilo portal in a recognized format will be indexed and searchable.
|
||
10 years ago
|
Chamilo intermediate Administrators training (which you can ask any <a href="http://www.chamilo.org/en/providers">Chamilo's Official Provider</a> for) include a full review of the full-text search feature.</p>
|
||
9 years ago
|
<p class="text-muted">
|
||
10 years ago
|
Note: Xapian's licensing for the PHP extension is a bit different than what is necessary to enter the Debian repositories, so it has been excluded. You can, however, generate your own package by following the <a href="http://trac.xapian.org/wiki/FAQ/PHP%20Bindings%20Package">packaging instructions on Xapian's wiki</a>.
|
||
14 years ago
|
</p>
|
||
|
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="11._Chamilo_rapid_ppt_conversion"></a>9. Chamilo Rapid - PPT conversion system</h2>
|
||
14 years ago
|
<p>
|
||
|
<em>Note</em>: This step will require a dedicated server or a virtual dedicated server as the packages involved are not available on most shared hosting solutions.<br />
|
||
10 years ago
|
On Debian or Ubuntu 11.10 and superior, install LibreOffice v3 (or v4) and start it as a headless server:
|
||
14 years ago
|
<pre>
|
||
10 years ago
|
sudo apt-get install libreoffice screen
|
||
8 years ago
|
sudo adduser rapid
|
||
|
sudo adduser rapid www-data
|
||
|
screen
|
||
|
sudo -s
|
||
|
su - rapid
|
||
10 years ago
|
soffice --accept="socket,host=127.0.0.1,port=2002,tcpNoDelay=1;urp;" --headless --nodefault --nofirststartwizard --nolockcheck --nologo --norestore
|
||
|
CTRL+a, CTRL+d
|
||
14 years ago
|
</pre>
|
||
10 years ago
|
Please note that this will effectively launch LibreOffice in a "headless" mode (thanks to the --headless option), in a "headless" terminal (thanks to screen). You can later get back into your "headless" terminal by launching:
|
||
|
<pre>
|
||
|
sudo screen -r
|
||
|
</pre>
|
||
|
You can then go to your administration page -> <i>Chamilo Rapid</i> and set the host to "localhost" and the port to "2002". Save. Go to your course, learning path tool and see the new icon appeared. Import your PPT. This should work.
|
||
|
<em>Note</em>: Sometimes, this doesn't work out so easily. You can probably ask for the assistance of any system administrator around with a bit of Java and PHP experience, or you can always ask one of the Chamilo's Official Providers for assistance (ask for a guaranteed commercial contract). The above is *not* meant for production servers with a high load. You should get a real system administrator to look at it and develop init scripts, in a way that makes monitoring and relaunching feasable. If any sysadmin wants to contribute this, feel free to contribute it to Chamilo: send us an e-mail at info@chamilo.org.
|
||
10 years ago
|
<em>Note</em>: If you use LibreOffice 4, please note that version 4.2 (available in Ubuntu 14.04) has demonstrated to be more successfull at converting documents than version 4.1, which tended to crash when sending a document for conversion.
|
||
14 years ago
|
|
||
14 years ago
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="12._Setting_cron_up"></a>10. Setting chronological tasks</h2>
|
||
14 years ago
|
<p>
|
||
11 years ago
|
Since Chamilo 1.8.8, a few tasks need to be executed regularly in order to get
|
||
|
the best out of your server resources. One of such tasks (and the only one
|
||
|
around at the time of Chamilo 1.8.8) is the sending of internal messaging
|
||
14 years ago
|
notifications by e-mail, i.e. when you receive an e-mail from another person or
|
||
|
from a group inside the internal messaging system of Chamilo, if all e-mails are
|
||
11 years ago
|
sent immediately, then you might not have the chance to receive them at your
|
||
|
pace, once a day or even once a week. For cases like this you, as a Chamilo
|
||
14 years ago
|
administrator, should setup a cron process on the server to check the queue of
|
||
|
e-mails and send is timely.</p>
|
||
7 years ago
|
|
||
14 years ago
|
Setting up a cron task is easy and there are several ways to do it. We recommend
|
||
11 years ago
|
you have a look at the <a href="http://drupal.org/cron">Drupal documentation
|
||
14 years ago
|
for setting up cron</a> and define your own cron process as:
|
||
|
<pre>
|
||
14 years ago
|
35 * * * * wget -O - -q -t 1 http://campus.example.com/main/cron/run.php
|
||
|
</pre>
|
||
11 years ago
|
Make sure you have a look into run.php as maybe you want to change a few
|
||
14 years ago
|
settings there.
|
||
7 years ago
|
|
||
14 years ago
|
|
||
13 years ago
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="13._Changing_language_names_order"></a>11. Changing the language's firstname/lastname order</h2>
|
||
13 years ago
|
As Chamilo becomes more popular and crosses many borders now, it frequently happens that administrators want to re-order the firstname and lastname fields in tables, and also on which field it is sorted first.<br/><br />
|
||
9 years ago
|
This can easily be modified by editing the app/config/configuration.php file, finding the following section, uncommenting the PHP lines and adapting it to your language:<br />
|
||
|
<pre>// Custom name_order_conventions
|
||
|
//$_configuration['name_order_conventions'] = array(
|
||
|
// 'french' => array('format' => 'title last_name first_name', 'sort_by' => 'last_name')
|
||
|
//);</pre><br />
|
||
13 years ago
|
Feel free to change this to<br />
|
||
9 years ago
|
<pre>// Custom name_order_conventions
|
||
|
$_configuration['name_order_conventions'] = array(
|
||
8 years ago
|
'french' => array('format' => 'first_name last_name', 'sort_by' => 'last_name')
|
||
|
);
|
||
|
</pre>
|
||
|
<br />
|
||
13 years ago
|
for example. The effect should be immediate.
|
||
7 years ago
|
<br />
|
||
9 years ago
|
Please note that, although Chamilo allows you to define its position, the "title" field does not exist at this time, so no need to worry about it.
|
||
|
|
||
15 years ago
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="14._Improving_files_download"></a>12. Improving files download efficiency</h2>
|
||
11 years ago
|
File download can be very slow when passing through a PHP script to control permissions. One solution to this
|
||
|
is to use the X-Sendfile header, which depends on a module on the webserver. <a href="http://stackoverflow.com/a/3731639/1406662">Check http://stackoverflow.com/a/3731639/1406662 for more details on implementing Sendfile</a>.
|
||
|
Chamilo LMS 1.9.8 (and following versions) supports the X-Sendfile headers, but requires a specific line of configuration to be
|
||
|
added to configuration.php:
|
||
|
<pre>
|
||
|
$_configuration['enable_x_sendfile_headers'] = true;
|
||
|
</pre>
|
||
|
If you have issues with files taking a long time to download, make sure you reconfigure your webserver and add this line. You should see an notable difference in download time.
|
||
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="15._Videoconference"></a>13. Videoconference</h2>
|
||
10 years ago
|
<p>
|
||
8 years ago
|
Chamilo supports the connection to two different videoconference servers: BigBlueButton (versions 0.81, 0.9 and 1.0) and OpenMeetings.<br />
|
||
10 years ago
|
While BigBlueButton seem easier to install, more clearly documented and more
|
||
|
esthetically finished, some users have manifested that OpenMeetings
|
||
|
consumes less bandwidth, is less restrictive in terms of running environments
|
||
|
and offers more tools and connectors.<br />
|
||
|
The decision is up to you, but in any case you will have to install a
|
||
|
videoconference server separately from the normal Chamilo LMS installation
|
||
|
process.<br />
|
||
|
You will find the <a href="http://docs.bigbluebutton.org/install/install.html">installation guide for BigBlueButton here</a>. Once installed,
|
||
|
issue a "bbb-conf --secret" on the command line to get the parameters to
|
||
|
indicate in the "Videoconference" plugin in Chamilo (platform settings page).<br />
|
||
|
This should make an additional "Videoconference" tool icon appear in every course.<br />
|
||
|
</p>
|
||
9 years ago
|
<hr style="width: 100%; height: 2px;" />
|
||
7 years ago
|
<h2><a name="16._Rewrite"></a>14. Rewrite</h2>
|
||
9 years ago
|
<p>
|
||
8 years ago
|
Chamilo LMS 1.10 is the first version to require the web server to allow redirections of requests (and so 1.11 does as well).<br />
|
||
9 years ago
|
For Apache, this is done through enabling the Rewrite module and either allowing overrides (through .htaccess) or adding a specific configuration section to the VirtualHost defined for Apache.<br />
|
||
|
For Nginx, this is done through specific redirection rules in the corresponding virtual host (server clause).<br /><br />
|
||
|
To make sure this isn't too complex for anyone, we recommend a configuration below to help you out in both cases.
|
||
|
Please note that using .htaccess is the easiest way but might affect your server load considerably,
|
||
|
given .htaccess files are interpreted on *every* request, while a configuration block in your VirtualHost
|
||
|
section is compiled at configuration reload time.
|
||
|
<h3>Apache + .htaccess</h3>
|
||
|
To enable .htaccess on Apache, you just need to check 1 thing: In a <Directory> block of the root folder of Chamilo, ensure the following lines are present:
|
||
|
<pre>
|
||
8 years ago
|
<Directory />
|
||
9 years ago
|
AllowOverride All
|
||
|
Order allow,deny
|
||
|
allow from all
|
||
8 years ago
|
</Directory>
|
||
|
</pre>
|
||
9 years ago
|
or, if you are working with Apache 2.4, that syntax changed a little and looks more like this:
|
||
|
<pre>
|
||
8 years ago
|
<Directory />
|
||
9 years ago
|
AllowOverride All
|
||
|
Require all granted
|
||
8 years ago
|
</Directory>
|
||
9 years ago
|
</pre>
|
||
|
<h3>Apache RewriteRules</h3>
|
||
|
<pre>
|
||
8 years ago
|
<LocationMatch "/.git*">
|
||
9 years ago
|
order deny,allow
|
||
|
deny from all
|
||
|
</LocationMatch>
|
||
|
|
||
|
<Directory ~/.>
|
||
|
AllowOverride None
|
||
|
Options -Indexes
|
||
|
</Directory>
|
||
|
|
||
|
<Directory "/var/www/chamilo">
|
||
|
RewriteEngine On
|
||
|
RewriteCond %{QUERY_STRING} ^id=(.*)$
|
||
6 years ago
|
RewriteRule ^certificates/$ certificates/index.php?id=%1 [L]
|
||
|
RewriteRule ^courses/([^/]+)/?$ main/course_home/course_home.php?cDir=$1 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/index.php$ main/course_home/course_home.php?cDir=$1 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/scorm/(.*([\.js|\.css|\.png|\.jpg|\.jpeg|\.gif]))$ app/courses/$1/scorm/$2 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/scorm/(.*)$ main/document/download_scorm.php?doc_url=/$2&cDir=$1 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/document/certificates/(.*)$ app/courses/$1/document/certificates/$2 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/document/(.*)$ main/document/download.php?doc_url=/$2&cDir=$1 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/upload/course_home_icons/(.*([\.js|\.css|\.png|\.jpg|\.jpeg|\.gif]))$ app/courses/$1/upload/course_home_icons/$2 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/upload/([^/]+)/(.*)$ main/document/download_uploaded_files.php?code=$1&type=$2&file=$3 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/work/(.*)$ main/work/download.php?file=work/$2&cDir=$1 [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/course-pic85x85.png$ main/inc/ajax/course.ajax.php?a=get_course_image&code=$1&image=course_image_source [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/course-pic.png$ main/inc/ajax/course.ajax.php?a=get_course_image&code=$1&image=course_image_large_source [QSA,L]
|
||
|
RewriteRule ^courses/([^/]+)/(.*)$ app/courses/$1/$2 [QSA,L]
|
||
|
RewriteRule ^session/(\d{1,})/about/?$ main/session/about.php?session_id=$1 [L]
|
||
|
RewriteRule ^course/(\d{1,})/about/?$ main/course_info/about.php?course_id=$1 [L]
|
||
8 years ago
|
RewriteRule ^badge/(\d{1,}) main/badge/issued.php?issue=$1 [L]
|
||
6 years ago
|
RewriteRule ^skill/(\d{1,})/user/(\d{1,}) main/badge/issued_all.php?skill=$1&user=$2 [L]
|
||
|
RewriteRule ^badge/(\d{1,})/user/(\d{1,}) main/badge/issued_all.php?skill=$1&user=$2 [L]
|
||
8 years ago
|
RewriteRule ^main/exercice/(.*)$ main/exercise/$1 [QSA,L]
|
||
9 years ago
|
RewriteRule ^main/newscorm/(.*)$ main/lp/$1 [QSA,L]
|
||
6 years ago
|
RewriteRule ^service/(\d{1,})$ plugin/buycourses/src/service_information.php?service_id=$1 [L]
|
||
|
RewriteRule ^lti/os$ plugin/ims_lti/outcome_service.php [L]
|
||
|
RewriteRule ^([^/.]+)/?$ user.php?$1 [L]
|
||
8 years ago
|
RewriteRule ^(tests|.git) - [F,L,NC]
|
||
9 years ago
|
</Directory>
|
||
7 years ago
|
|
||
|
AddType application/font-woff .woff .woff2
|
||
|
<IfModule mod_expires.c>
|
||
|
ExpiresActive On
|
||
|
ExpiresByType application/font-woff "access plus 1 month"
|
||
|
</IfModule>
|
||
9 years ago
|
</pre>
|
||
|
<h3>Nginx</h3>
|
||
|
Nginx doesn't support .htaccess rules, so you have no other option than to apply the following rules (note that your PHP backend configuration may vary).
|
||
|
These are only the redirection rules to be placed inside a server{} block, as other settings might differ from one installation to another.
|
||
|
<pre>
|
||
9 years ago
|
# Add your own "server {" header here with listen, server_name, access_log, error_log, index, root and error_page params
|
||
|
|
||
|
charset utf-8;
|
||
|
|
||
9 years ago
|
location @rewrite{
|
||
8 years ago
|
rewrite ^certificates/$ certificates/index.php last;
|
||
|
rewrite ^/courses/([^/]+)/$ /main/course_home/course_home.php?cDir=$1 last;
|
||
|
rewrite ^/courses/([^/]+)/index.php$ /main/course_home/course_home.php?cDir=$1 last;
|
||
9 years ago
|
rewrite ^/courses/([^/]+)/scorm/(.*)$ /main/document/download_scorm.php?doc_url=/$2&cDir=$1 last;
|
||
8 years ago
|
# Alternatively, you can choose to give direct access to all SCORM files, which is much faster but less secure
|
||
|
# rewrite "^/courses/([^/]+)/scorm/(.*)$" /app/courses/$1/scorm/$2 break;
|
||
8 years ago
|
|
||
8 years ago
|
rewrite "^/courses/([^/]+)/document/certificates/(.*)$" /app/courses/$1/document/certificates/$2 last;
|
||
9 years ago
|
rewrite ^/courses/([^/]+)/document/(.*)$ /main/document/download.php?doc_url=/$2&cDir=$1 last;
|
||
7 years ago
|
rewrite ^/courses/([^/]+)/upload/([^/]+)/(.*)$ /main/document/download_uploaded_files.php?code=$1&type=$2&file=$3 last;
|
||
9 years ago
|
rewrite ^/courses/([^/]+)/work/(.*)$ /main/work/download.php?file=work/$2&cDir=$1 last;
|
||
8 years ago
|
rewrite ^/courses/([^/]+)/(.*)$ /app/courses/$1/$2 last;
|
||
|
rewrite ^/session/([^/]+)/about/?$ /main/session/about.php?session_id=$1 last;
|
||
6 years ago
|
rewrite ^/course/([^/]+)/about/?$ /main/course_info/about.php?course_id=$1 last;
|
||
8 years ago
|
rewrite ^/badge/(\d+) /main/badge/issued.php?issue=$1 last;
|
||
8 years ago
|
rewrite ^/skill/(\d+)/user/(\d+)$ /main/badge/issued_all.php?skill=$1&user=$2 last;
|
||
|
rewrite ^/badge/(\d+)/user/(\d+)$ /main/badge/issued_all.php?skill=$1&user=$2 last;
|
||
8 years ago
|
rewrite ^/main/exercice/(.*)$ /main/exercise/$1 last;
|
||
|
rewrite ^/main/newscorm/(.*)$ /main/lp/$1 last;
|
||
|
rewrite ^/service/(\d+)$ /plugin/buycourses/src/service_information.php?service_id=$1 last;
|
||
8 years ago
|
rewrite "^/main/upload/users/(.*)/(.*)/my_files/(.*)$" /app/upload/users/$1/$2/my_files/$3 last;
|
||
8 years ago
|
|
||
8 years ago
|
try_files $uri /index.php$is_args$args;
|
||
9 years ago
|
break;
|
||
|
}
|
||
|
|
||
9 years ago
|
location / {
|
||
|
try_files $uri @rewrite;
|
||
|
}
|
||
|
|
||
9 years ago
|
location /main {
|
||
8 years ago
|
rewrite ^/main/admin/?$ /main/admin/index.php last;
|
||
9 years ago
|
}
|
||
|
|
||
9 years ago
|
location ~ \.php$ {
|
||
|
client_max_body_size 20M;
|
||
8 years ago
|
try_files $uri @rewrite;
|
||
9 years ago
|
|
||
|
fastcgi_pass unix:/var/run/php5-fpm.sock;
|
||
|
fastcgi_split_path_info ^(.+\.php)(/.*)$;
|
||
|
include fastcgi_params;
|
||
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
||
|
fastcgi_param HTTPS off;
|
||
|
}
|
||
|
|
||
|
# Serve static files directly
|
||
7 years ago
|
location ~* \.(png|jpe?g|gif|ico|js|css|mp3|swf|flv|mp4|ogg|woff|woff2)$ {
|
||
|
expires 30d;
|
||
9 years ago
|
access_log off;
|
||
|
rewrite ^/courses/([^/]+)/course-pic85x85.png$ /app/courses/$1/course-pic85x85.png last;
|
||
|
rewrite ^/courses/([^/]+)/course-pic.png$ /app/courses/$1/course-pic.png last;
|
||
|
try_files $uri @rewrite;
|
||
|
}
|
||
|
location ~ ~\.(ht|git){
|
||
|
deny all;
|
||
|
}
|
||
|
location ^~ /tests/ {
|
||
|
deny all;
|
||
|
}
|
||
|
</pre>
|
||
9 years ago
|
<h3>Apple on OS X servers</h3>
|
||
7 years ago
|
<div>
|
||
9 years ago
|
Scott Steven reports that Apache on OS X requires specific actions<br />
|
||
|
<ul>
|
||
|
<li>First, make sure you have the .htaccess file present at the root of your Chamilo folder</li>
|
||
|
<li>Get to your Apache"s HTTPd.conf file and configure your domain and the fact that mod_rewrite is loaded</li>
|
||
|
<li>In your Apple Server app, Advanced Settings, check the box to allow .htaccess</li>
|
||
|
</ul>
|
||
|
Alternatively, you can find the settings file for your domain in Apple's settings folder under
|
||
|
/Library/Server/Web/Settings to update it manually.<br />
|
||
|
You cannot, however, only allow .htaccess files in the main httpd.conf file, as OS X will override it with the
|
||
|
domain-specific configuration file.
|
||
7 years ago
|
</div>
|
||
6 years ago
|
<h3>IIS</h3>
|
||
|
<div>
|
||
|
User @ullfindsmit on Github was kind enough to provide this IIS configuration after testing it based on our
|
||
|
configurations above. This has not been tested by the Chamilo team, but the rules look legit:<br /><br />
|
||
|
<pre>
|
||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||
|
<configuration>
|
||
|
<system.webServer>
|
||
|
<rewrite>
|
||
|
<rules>
|
||
|
<rule name="rule 1v" stopProcessing="true">
|
||
|
<match url="^certificates/$" />
|
||
|
<action type="Rewrite" url="/certificates/index.php?id=%1" />
|
||
|
</rule>
|
||
|
<rule name="rule 2v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/?$" />
|
||
|
<action type="Rewrite" url="/main/course_home/course_home.php?cDir={R:1}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 3v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/index.php$" />
|
||
|
<action type="Rewrite" url="/main/course_home/course_home.php?cDir={R:1}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 4v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/scorm/(.*)$" />
|
||
|
<action type="Rewrite" url="/main/document/download_scorm.php?doc_url=/{R:2}&cDir={R:1}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 5v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/document/certificates/(.*)$" />
|
||
|
<action type="Rewrite" url="/app/courses/{R:1}/document/certificates/{R:2}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 6v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/document/(.*)$" />
|
||
|
<action type="Rewrite" url="/main/document/download.php?doc_url=/{R:2}&cDir={R:1}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 7v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/upload/([^/]+)/(.*)$" />
|
||
|
<action type="Rewrite" url="/main/document/download_uploaded_files.php?code={R:1}&type={R:2}&file={R:3}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 8v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/work/(.*)$" />
|
||
|
<action type="Rewrite" url="/main/work/download.php?file=work/{R:2}&cDir={R:1}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 9v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/course-pic85x85.png$" />
|
||
|
<action type="Rewrite" url="/main/inc/ajax/course.ajax.php?a=get_course_image&code={R:1}&image=course_image_source" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 10v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/course-pic.png$" />
|
||
|
<action type="Rewrite" url="/main/inc/ajax/course.ajax.php?a=get_course_image&code={R:1}&image=course_image_large_source" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 11v" stopProcessing="true">
|
||
|
<match url="^courses/([^/]+)/(.*)$" />
|
||
|
<action type="Rewrite" url="/app/courses/{R:1}/{R:2}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 12v" stopProcessing="true">
|
||
|
<match url="^session/(\d{1,})/about/?$" />
|
||
|
<action type="Rewrite" url="/main/session/about.php?session_id={R:1}" />
|
||
|
</rule>
|
||
|
<rule name="rule 13v" stopProcessing="true">
|
||
|
<match url="^badge/(\d{1,})" />
|
||
|
<action type="Rewrite" url="/main/badge/issued.php?issue={R:1}" />
|
||
|
</rule>
|
||
|
<rule name="rule 14v" stopProcessing="true">
|
||
|
<match url="^skill/(\d{1,})/user/(\d{1,})" />
|
||
|
<action type="Rewrite" url="/main/badge/issued_all.php?skill={R:1}&user={R:2}" />
|
||
|
</rule>
|
||
|
<rule name="rule 15v" stopProcessing="true">
|
||
|
<match url="^badge/(\d{1,})/user/(\d{1,})" />
|
||
|
<action type="Rewrite" url="/main/badge/issued_all.php?skill={R:1}&user={R:2}" />
|
||
|
</rule>
|
||
|
<rule name="rule 16v" stopProcessing="true">
|
||
|
<match url="^main/exercice/(.*)$" />
|
||
|
<action type="Rewrite" url="/main/exercise/{R:1}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 17v" stopProcessing="true">
|
||
|
<match url="^main/newscorm/(.*)$" />
|
||
|
<action type="Rewrite" url="/main/lp/{R:1}" appendQueryString="true" />
|
||
|
</rule>
|
||
|
<rule name="rule 18v" stopProcessing="true">
|
||
|
<match url="^service/(\d{1,})$" />
|
||
|
<action type="Rewrite" url="/plugin/buycourses/src/service_information.php?service_id={R:1}" />
|
||
|
</rule>
|
||
|
<rule name="rule 19v" stopProcessing="true">
|
||
|
<match url="^([^/.]+)/?$" />
|
||
|
<action type="Rewrite" url="/user.php?{R:1}" />
|
||
|
</rule>
|
||
|
<rule name="rule 20v" stopProcessing="true">
|
||
|
<match url="^(tests|.git)" ignoreCase="true" />
|
||
|
<action type="Rewrite" url="/-" />
|
||
|
</rule>
|
||
|
</rules>
|
||
|
</rewrite>
|
||
|
</system.webServer>
|
||
|
</configuration>
|
||
|
</pre>
|
||
|
</div>
|
||
8 years ago
|
|
||
7 years ago
|
<h2><a name="17._Git_Upgrade"></a>15. Upgrading from Git</h2>
|
||
|
If you have sufficient experience with Git and have installed your initial Chamilo portal
|
||
8 years ago
|
from the Git version, you might want to upgrade from 1.9.x to 1.11.x using Git directly.<br />
|
||
9 years ago
|
Here are a few tips that might help you:<br />
|
||
|
<ul>
|
||
|
<li>Get into your Chamilo Git repository</li>
|
||
|
<li>Make sure you have no additional elements that were not commited (git status/git stash)</li>
|
||
|
<li>If you have issues, you can always save your code somewhere else and ask Git to put you exactly at the most recent 1.9.x stage ("git pull"/"git reset --hard origin/1.9.x")</li>
|
||
8 years ago
|
<li>Once you're sure you have a "clean" local Chamilo repository, create a 1.11.x branch with "git checkout -b 1.11.x"</li>
|
||
|
<li>In the new branch, download all code from the 1.11.x branch upstream: "git pull origin 1.11.x"</li>
|
||
|
<li>If you never used composer or used it only a few times in the past, you might need to update it (rm -rf ~/.composer/vendor; composer clear-cache) before trying the following command</li>
|
||
9 years ago
|
<li>Update composer: "composer update" (you might need to give a Github token here)</li>
|
||
|
<li>Change permissions on folders app, web, main/lang and main/default_course_document/images</li>
|
||
|
<li>Go to your portal install page (main/install/) and follow the upgrade procedure</li>
|
||
7 years ago
|
</ul>
|
||
15 years ago
|
<p>
|
||
15 years ago
|
<br />
|
||
|
<br />
|
||
15 years ago
|
Contact address<br />
|
||
|
Mail: info@chamilo.org<br />
|
||
15 years ago
|
<br />
|
||
|
</p>
|
||
|
<hr />
|
||
|
</div>
|
||
|
|
||
|
<hr />
|
||
9 years ago
|
<a href="http://validator.w3.org/check?uri=referer"><img src="//www.w3.org/Icons/valid-xhtml10-blue" alt="Valid XHTML 1.0 Transitional" style="margin: 1em; float: right;" height="31" width="88" /></a>
|
||
14 years ago
|
<a href="http://jigsaw.w3.org/css-validator/">
|
||
9 years ago
|
<img src="//jigsaw.w3.org/css-validator/images/vcss-blue" style="margin: 1em; float: right;" alt="Valid CSS" />
|
||
14 years ago
|
</a>
|
||
14 years ago
|
</body>
|
||
13 years ago
|
</html>
|