How to install Moodle on Ubuntu 14.04

This document describes how to install and configure Moodle on Ubuntu 14.04. Moodle (acronym for Modular Object-Oriented Dynamic Learning Environment) (stylised in lower-case as moodle) is a free software e-learning platform, also known as a Learning Management System, or Virtual Learning Environment (VLE). As of June 2013 it had a user base of 83,008 registered and verified sites, serving 70,696,570 users in 7.5+ million courses with 1.2+ million teachers. Equipped with a horde of smart features such as virtual quizzes, assignment submission, wiki, grading, IM services, and online discussion boards, Moodle enables a seamless online learning experience for end-users. 也, by virtue of being a modular software, it is capable of enhanced functionality through customized plugins.

1 初步说明

本教程是基于Ubuntu 14.04 服务器, so you should set up a basic Ubuntu 14.04 服务器安装之前您继续使用此教程. 该系统应该有一个静态IP地址. 我用 192.168.0.100 as my IP地址 in this tutorial and server1.example.com 作为主机名.

2 Install Apache/MySQL/PHP

We require Apache, MySQL and PHP before Moodle installation. I will be using root credentials, if you are doing installation with any other user just prefix sudo before all commands:

apt-get -y install apache2 mysql-client mysql-server php5

You will be asked to provide a password for the MySQL root user - this password is valid for the user [email protected] 以及 [email protected], so we don't have to specify a MySQL root password manually later on:
New password for the MySQL "root" user: <-- yourrootsqlpassword
Repeat password for the MySQL "root" user: <-- yourrootsqlpassword

Moodle require some more packages we will install them as follows:

apt-get -y install graphviz aspell php5-pspell php5-curl php5-gd php5-intl php5-mysql php5-xmlrpc php5-ldap git-core

I will be using 混帐 utility for downloading Moodle so I have installed git-core.

3 Download Moodle

Now we will download Moodle as follows:

CD /选择
git clone git://git.moodle.org/moodle.git
cd moodle
git branch -a
git branch --track MOODLE_27_STABLE origin/MOODLE_27_STABLE
git checkout MOODLE_27_STABLE

Next we need to copy the Moodle content to the /无功/ www / html等 as:

cp -R /opt/moodle /var/www/html/
mkdir /var/moodledata
chown -R www-data /var/moodledata
chown -R www-data /var/www/html/moodle
搭配chmod -R 777 /var/moodledata
搭配chmod -R 0755 /var/www/html/moodle

We need to change the default storage engine to innodb

纳米/etc/mysql/my.cnf

Give values at the end of the file as:

[...]
#Basic settings for moodle
default-storage-engine = innodb

4 数据库初始化

We need a database for Moodle, I will create the database for the Moodle as follows:

MySQL的ü根 - P

在这里,我们要添加 database=moodledb user=moodleuserpassword=moodlepassword

CREATE DATABASE moodledb DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,CREATE TEMPORARY TABLES,DROP,INDEX,ALTER ON moodledb.* TO [email protected] IDENTIFIED BY 'moodlepassword';

进一步向前迈进:

FLUSH PRIVILEGES;
出口

重新启动服务

服务重新启动的Apache2
服务重新启动mysql的

3 Web installation of Moodle

Now we will proceed with the Moodle web-installation. Open a browser of your choice and open the link http:192.168.0.100/moodle/install.php

[...]

点击放大

Select your language and press 下一个

点击放大

Change the value of Data directory/var/moodledata 下一个

点击放大

下一个

点击放大

Give the values at the time of creation of the database, in my case it was as follows:

Database host : 本地主机
Database name : moodledb
Database user : moodleuser
Database password : moodlepassword
table prefix : mdl_ (or any valaue of your choice)
Database port : 3306
Unix socket : It will remain blank.

给值后按 下一个

点击放大

继续

点击放大

继续

点击放大

继续

点击放大

Now create an admin user for Moodle, you can use any value as per your choice. In my case I am using:
Username : 管理
New password : [email protected]
First name : Srijan
Surname : Kishore
EMail : [email protected]

All other field I will be using its default value, ofcourse you can change it later.

点击放大

Update profile

点击放大

Give any name as per your choice, I am using a test name as:

Full site name : Test-moodle
Short name for site : 测试
Self registration : 禁用

After giving the values press Save changes

点击放大

Now go to Site Administration-->服务器-->System Paths and define the paths as follows:

Path to du : /usr/bin/du
Path to aspell : /usr/bin/aspell
Path to dot : /usr/bin/dot

保存更改.

Now we are done with the installation part of Moodle, We can access the Moodle page at http://192.168.0100/moodle/login/index.php 如下:

点击放大

Your credentials will be 用户名=管理密码=[email protected].
Next page will be the default welcome page.

点击放大

Now we can add courses and use Moodle as per our requirement. Congratulations! You now we have a fully functional Moodle instance on our Ubuntu 14.04 🙂

一个响应

发表评论

本网站使用的Akismet,以减少垃圾邮件. 了解您的意见如何处理数据.

我们使用cookies来给你最好的在线体验. 通过同意你接受使用cookies按照我们的Cookie政策.