Quantcast
Channel: Installing and upgrading help
Viewing all articles
Browse latest Browse all 46915

Re: Install 2.5.5 on GoDaddy VPS

$
0
0
by Ken Task.  

Your reason for going VPS is negated IF you continue to use the older (non-VPS) methods of installing/updating and upgrading Moodle.   Time for your 'basic knowledge' to up a rung!

First, hope you have an appropriate plan for the VPS:

GoDaddy VPS hosting Plans
Offers CentOS (6.4), Fedora (14), or Windows (2008)

"CentOS Version 6.4 is the operating system of choice for those looking for a highly stable version of Linux that offers enterprise-level reliability."

http://www.godaddy.com/hosting/vps-hosting.aspx

It's LTS (long term support which means
CentOS-6 updates until November 30, 2020
http://wiki.centos.org/FAQ/General#head-fe8a0be91ee3e7dea812e8694491e1dde5b75e6d

Not true of Feodra and certainly NOT Windows

One of the reasons in going VPS is one does't have the restrictions of a shared plan, although one could restrict themselves by purchasing the 'economy package' ... 1 Gig RAM, 40 GB storage ... example.

Here's the **REAL** advantage ...
one can install Moodle, update Moodle and upgrade Moodle via git.

http://docs.moodle.org/26/en/Git_for_Administrators

Yes, it's a learning curve, but once over the hump you'll be glad you spent the time and it will be time well spent.

Assumes CentOS 6.x and a typically installed and configured AMP stack (Apache/MySQL/PHP with git installed via yum.

Installing Moodle via git:

Create the DB for Moodle:

mysql -u [root] -p[password]

from the mysql> prompt:

create database moodle character set utf8 collate utf8_unicode_ci;

\q to quit mysql

Install Moodle via git:

login as root

cd /var/www

mkdir moodledata

chown apache:apache moodledata

git clone git://git.moodle.org/moodle.git html
cd html
git branch -a
git branch --track MOODLE_25_STABLE origin/MOODLE_25_STABLE
git checkout MOODLE_25_STABLE

cd html/admin/cli/

php install.php

This last script will prompt for those items seen in the Web based install.

Once completed make sure everything is readable by apache user:

cd /var/www/html/

chown apache:apache * -R

Hit the site with browser.   Login.  Enjoy!

Example: updating a Moodle 2.5.x that was installed via git to the highest most secure version of 2.5.5 is as simple as the following commands:

1st backup site:

mysqldump -u [user] -p[password] moodle > /home/backup/moodlebackup-$(date +%Y%m%d%-H%M%S).sql
tar -cvf /home/backup/moodlecode-$(date +%Y%m%d%-H%M%S).tar /var/www/html
tar -cvf /home/backup/moodledata-$(date +%Y%m%d%-H%M%S).tar /var/www/moodledata

Now update the site:
cd /var/www/html/
php admin/cli/maintenance.php --enable
git pull
php admin/cli/upgrade.php --non-interactive
php admin/cli/cron.php
php admin/cli/purge_caches.php

Hit the site with browser and login as admin level user.
Go to Notifications and acquire the plugin updates - if there are any.

The above two routines could be put into an executable script in /usr/local/bin/
belonging to and executable by root user ONLY.
The 1st called 'backup'.
The 2nd called 'updatemoodle'.

Once those scripts are in place and made executable by root user, to update a Moodle now it's just two commands as root user:

backup [ENTER]

and when that's ifinished

updatemoodle [ENTER]

Done!

'spirit of sharing', Ken


Viewing all articles
Browse latest Browse all 46915

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>