NOTE: DO *NOT* USE THIS METHOD TO INSTALL A MOODLE SERVER ON UBUNTU. THIS IS AN EXAMPLE OF TRIAL AND ERROR, AND THE METHOD IS NOT USEFUL FOR LONG TERM INSTALLATIONS. INSTALL MOODLE FROM THE UBUNTU REPOSITORY (“sudo apt-get install moodle”) OR FROM THE CVS REPOSITORY, BUT DO NOT MIX THE METHODS! (sorry for yelling
- Install stock Ubuntu Server (7.04)
- Check the option for a LAMP server (if it shows)
- edit /etc/apt/sources.list and comment out the cd (sudo nano +4 /etc/apt/sources.list)
- set /etc/network/interfaces to static
iface eth0 inet static
address 192.168.1.42
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1 - add openssh-server (sudo apt-get install openssh-server)
- stop and start the interface to bring up the new ip (sudo ifdown eth0; sudo ifup eth0)
- switch to ssh managment (ssh user@192.168.1.42)
- edit /etc/apache2/ports.conf to listen on a good port (this is only necessary because i run a different server on port 80. If this were set up for SSL, you would change ports.conf to listen on 443.
- sudo apt-get update; sudo apt-get upgrade; sudo apt-get dist-upgrade (look at using unattended upgrade package)
- sudo /etc/init.d/mysql reset-password (set the root password for mysql)
- add a database and user to mysql for moodle
mysql -u root -p
create user moodle identified by ‘PASSWORD’;
create database moodle;
grant all on moodle.* to moodle;
exit - sudo apt-get install moodle (enter the following information)
Apache2
MySQL
localhost
root
PASSWORD
moodle
PASSWORD - sudo nano +16 /etc/moodle/config.php (change this to the static ip to allow access from your ssh computer)
- sudo nano +12 /etc/moodle/apache.conf (remove the # on line 12 to allow access from outside localhost)
- restart apache, sudo apache2 -k restart
- go through the web browser setup (this writes the tables!)
- Log into the adming for the site and convert all the data in your database to Unicode using our migration script. Click here to run the migration script now!
- DELETE /var/www/apache-default
- apt-get remove moodle, it leaves the /etc/moodle files and the database entries.
- cd /var/www
- sudo apt-get install cvs
- login to the CVS repository
cvs -d:pserver:anonymous@eu.cvs.moodle.org:/cvsroot/moodle login
No password for anonymous, so just hit the Enter button. - sudo cvs -z3 -d:pserver:anonymous@eu.cvs.moodle.org:/cvsroot/moodle co -r MOODLE_19_STABLE moodle
- when you go back to the web browser, it will start a new migration script. teh only thing i had to change was the data location from /var/moodledata to /var/lib/moodle
- this created a directory called moodle in the www files. do “sudo nano index.php” to create a redirector
- open up /etc/moodle/apache.conf, comment out the alias, and change the directory match to /var/www/
- log back in to the web page and run updates
- sudo a2enmod ssl
- sudo apt-get install ssl-cert
- sudo mkdir /etc/apache2/ssl
- sudo /usr/sbin/make-ssl-cert /usr/share/ssl-cert/ssleay.cnf /etc/apache2/ssl/apache.pem
- edit cp the default site enabled to your new name and edit for *.443, also add (in the ## area in the middle)
SSLEngine on
SSLCertificateFile /etc/apache2/ssl/apache.pem
SSLProtocol all
SSLCipherSuite HIGH:MEDIUM - sudo a2ensite [sitename]
- change /etc/apache2/ports.conf to 443
click continue through a few pages…
change the country name
probably should run clam on startup… must have it installed first!
set the smtp (if needed)
max editing time..i like 60 – i hate to lose my work!
enable stats
meta http-equiv=”refresh” content=”0;url=/moodle”
- http://docs.moodle.org/en/Upgrading
- To update, just go into the Moodle root directory and update to the new files: cvs update -dP
- To update to a new version type in the following and change 18 to whatever newest version upgrade number is cvs -Q update -dP -r MOODLE_18_STABLE
Incoming search terms:
- remove moodle from ubuntu
- uninstall moodle ubuntu
- setting up moodle on ubuntu
- install moodle ubuntu
- moodle unicode ubuntu
- ubuntu moodle ssl
- how to uninstall moodle from ubuntu
- remover moodle do ubuntu
- setting up a moodle server
- ubuntu server moodle install
If the moodle ubuntu package is ever updated, it may overwrite files in your cvs install.