Using AWS for Moodle

Using AWS for Moodle

by Edilberto Solis, Jr. -
Number of replies: 10
Good morning Sir, 


I initially installed moodle via bitnami in Amazon marketplace using t2.micro and 10GiB EBS. I only have 1 EC2 Instance and 1 EBS Volume paired to that instance. 

Not yet setting up the auto-scaling , loading balancing and elastic ip.


What can you recommend in order to accommodate/stable performance for at most 150 - 200 concurrent users?  

User Count: at most 3000

What type of instance? and EBS volume? 

What type of set-up?  

1 EC2 instance for application/web server and 1 EC2 instance for database? 

1 EC2 instance for application then use 1 RDS instance for database? 

or just 1 EC2 instance for both of them?


Do I also need to cancel my subscription from bitnami via Amazon Marketplace then install moodle fresh or I can stick with my subscription with bitnami to make these upgrades?


Difference between using Moodle via bitnami in AWS and manual installation? (Advantages and Disadvantage)

I hope you can help me! 

More power.


Average of ratings: -
In reply to Edilberto Solis, Jr.

Re: Using AWS for Moodle

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Firstly, I would *definitely not* use Bitnami to install Moodle. You/we have no idea how it works and it becomes very hard to provide support here. Only ever install Moodle from code you have downloaded here. 

Will you have 150-200 concurrent users from day one? It's better to start with a smallish system and monitor closely. It's a while since I have used Amazon but we used to use their database service and it does work pretty well. You still need to take proper backups though as it can go wrong. 

In reply to Howard Miller

Re: Using AWS for Moodle

by Edilberto Solis, Jr. -

yes sir.

I have just tried moodle using bitnami.


Is it okay to use windows server 2016 for installing moodle?

planning to use windows server. 


For the concurrent user, yes sir.

But I will start with their t2.micro instance.

and will separate my db from moodle/moodledata.

In reply to Edilberto Solis, Jr.

Re: Using AWS for Moodle

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Windows is ok... lots of people do us it. 

However, you will get more support using Linux if you have a choice. 

In reply to Edilberto Solis, Jr.

Re: Using AWS for Moodle

by Eduard TC -

Hi Edilberto,

If you want you can check this elastic beanstalk environment config. This way you can forgot the Server maintenance forever ;) 

I used it but have no performing tests

-> https://github.com/Tulkis/aws-ebs-moodle

Hope it helps!

Regards,

Eduard. 

In reply to Eduard TC

Re: Using AWS for Moodle

by Tawfik Daim -

Hi Eduard

I love the idea, didn't know about this option before but it seems brilliant in my case where I could have 1000's of students and possibly increasing more an more.

So if I can setup this option and grow as my students grow. 

Only comments when I first looked at the link you gave it seems was done for WordPress so does it work exactly for Moodle

In reply to Tawfik Daim

Re: Using AWS for Moodle

by Eduard TC -

Hi Tawfik,

Yes I used the wordpress documentation and adapt it to moodle, only some changes made like moodle data directory mount.

Regards,

Eduard.

In reply to Eduard TC

Re: Using AWS for Moodle

by Julian Pool -

How would you go about updating the moodle framework to a newer version, whilst keeping your current configuration?

In reply to Julian Pool

Re: Using AWS for Moodle

by Ron Meske -
Picture of Particularly helpful Moodlers

Hi Julian,

I am assuming you are referring to upgrading a Moodle install on a AWS configuration using auto-scaling.  The procedure isn't much different then upgrading a single server.

Though I have not used auto-scaling for Moodle, the approach I would take is:

  1. Change the configuration of auto-scaling to 1 EC2
  2. Put Moodle into Maintenance mode
  3. Make a backup of Moodle install and data.  Exactly how depends on your configuration.  You just want to be able to restore everything back to the way it was should something break.  Snapshots are usually a simple solution.
  4. Perform the Moodle upgrade and test thoroughly.
  5. Create a new AMI to be used for auto-scaling
  6. Modify your auto-scaling config to use the new AMI
  7. Start up a new EC2 instance with that AMI
  8. Place the new EC2 in the auto-scaling group and remove the old one
  9. Adjust your auto-scaling group back to the number of EC2 instances you need

Again, the above is a general guideline and you will want to verify all the steps are correct for your particular install.

Just an FYI - The configuration I use has a  single medium EC2, RDS to offload the database functions, and a Load Balancer to offload SSL.  This easily handles between 25-50 users being signed on at once.  I have not really monitored to determine exactly home many concurrent connections this handles or if I really need the RDS or Load Balancer.

Hope this helps.

Ron

Average of ratings: Useful (2)
In reply to Edilberto Solis, Jr.

Re: Using AWS for Moodle

by Rafael Franco Castro -

HI Edilberto,


I have created a Cloud formation template for deploying moodle, that creates an ec2 instance, and rds instance and a s3 bucket as well as installing and performing the initial moodle config, seciyng 3 diferent environment sizes and modifying the instance types acordingly.

at its current state it deploys in the default VPC and uses a the default Security groups, so it is not the safest config when it comes to networking, so you would need top perform some extra changes to harden the security of the infrastructure. it does save a lot of time and poking around for the initial setup of Moodle, this is a work in progress so you can expect to se some changes and improvements, that beign said you can find the template here https://github.com/ELRuncho/MoodleCloudFormation

the template is calle moodlestack.yaml you might find other files, I usually use those for testing small parts of new features.

I hope this helps you and someone else who is looking to deploy Moodle quickly in AWS

In reply to Edilberto Solis, Jr.

Re: Using AWS for Moodle

by Greg Rudl -

I have a demo moodle site running on t2.micro--how do you upgrade to a newer moodle version?