Why I won't pay annually for a VPS in the future

Why I won't pay annually for a VPS in the future

by James Steerpike -
Number of replies: 22

I started an earlier thread about sharing a VPS. I was thinking – should I pay $240 or $480 a year for my VPS? And how can I lower that cost?

IT changes fast and there is an alternative. Pay by the hour for a server. There are real advantages in cost and flexibility.

I opened an account with DigitalOcean and selected the bottom range “droplet” – 1vCPU and 1vCPU virtual machine. This is less than 1c an hour and capped at $5 a month and was fine for setting up my course. I installed Debian LAMP and Moodle and then hit a problem. I am living in China and run a VPN all the time. My new Moodle site was visible with my VPN taking me outside the Great FireWall but without a VPN it was not visible for my students. I had been assigned a blocked IP address.

Normally you submit a ticket and ask for a new IP address. Instead I created a snapshot – a copy of my droplet – and created a new droplet from the snapshot which came with a new IP address. All was fine with access and I now had two virtual machines going at 2c a minute billed. I destroyed the original droplet and was back to my original billing.

I snapshotted again and now I can create new droplets, each with a new IP address, from my Moodle install. This time I can allocate more resources - 2GB and 4GB and my cost is still under 10c an hour for three VM. I can run an intro to Moodle with a 2GB droplet in my first class and depending on performance, in my next class can point them to the 1 or 4 GB instance. I can then destroy what I don't need and run with a machine tested to be not too big and not too small – and one that can be easily upgraded.

In my upcoming holiday, I can snapshot again, destroy my virtual machine and pay pennies per month for storing my snapshot. Come the new term, create a new droplet.

I won't go back to annual billing.


Average of ratings: Very cool (3)
In reply to James Steerpike

Re: Why I won't pay annually for a VPS in the future

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Moving to Lounge...
In reply to Howard Miller

Re: Re: Why I won't pay annually for a VPS in the future

by Ken Task -
Picture of Particularly helpful Moodlers

Ok, this is related ... me thinks ... and thinking outloud ...

Is it time to have a forum for alternative cloud hosted Moodles?

One thing would suggest to James ... include in your profile a description of how you are hosted.  Question you might have with a moodle module and it's behavior/function ooohhh say in the area of 'Search' in DigitalOcean's droplets might different than RackSpace hosted boxen.

'SoS', Ken

Average of ratings: Coolest thing ever! (1)
In reply to James Steerpike

Re: Why I won't pay annually for a VPS in the future

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
I'm also a happy user of Digital Ocean.

However, some businesses hate not knowing what the bill is going to be. This sort of "pay as you go" arrangement can be a hard sell.
Average of ratings: Very cool (2)
In reply to Howard Miller

Re: Re: Why I won't pay annually for a VPS in the future

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
I'm also a happy user of Digital Ocean (with my own personal money).
I suspect some people are put off using them because of the emphasis of support for developers as if it might not be good for every day hosting. This is not the case. I did have an AWS account but I cancelled it.
Average of ratings: Very cool (3)
In reply to James Steerpike

Re: Why I won't pay annually for a VPS in the future

by Ken Task -
Picture of Particularly helpful Moodlers

See others have chimed in ... cool ratings indicate you might be onto something.   Before I dive into one myself ... realize it's new and maybe not fully explored yet ... but ...

Have the ability to install any 'handy tools'?
For example, while I do most things via cli, for overall server admin like Webmin.  Webmin is perl based.   Another, MySQL tuner and another Logwatch.

Goes upwards, but what about backwards?   DB config and tweaks.
Tweaks to mysql config for InnoDB metrics have to still allow the
system enough memory to handle whatever. Tweaked upwards due to usage would stay that way on droplet manipulations.  Moving a droplet downwards wouldn't go into DB config.

example of config for 5.7 ... innodb_buffer_pool comments in config file:

# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M

In running tuner:
[OK] Maximum reached memory usage: 175.8M (2.25% of installed RAM)
[OK] Maximum possible memory usage: 338.9M (4.34% of installed RAM)
[OK] Overall possible memory usage with other process is compatible with memory available

Yes, know am playing 'devils advocate' ... some what ... and that configs are not set in stone ... but one would need to be aware of adjustments to be made moving back downwards, me thinks.

Guess I need to acquire one and see for myself. :|  But do believe services like DigitalOcean provides are the way of the entire 'remotely hosted' industry.

'SoS', Ken

Average of ratings: Coolest thing ever! (1)
In reply to Ken Task

Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
Checking through my spam emails as I attempt to get Moodle to send out mail., DigitalOcean are offering $50 in credit to new signups on a referral.
Full disclosure - As soon as you’ve spent $25 with DO, I get $25 in credit.
Message me and I will send you a referral link. The more the merrier.
Average of ratings: Coolest thing ever! (1)
In reply to James Steerpike

Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
Some details of what I am running:
Hardware: basic droplet at 1 vCPU and 1 Gb of RAM, $5 a month subscription.
Software: Used the LAMP from the marketplace image. Loads with Apache 2.4.29, MySqL 5.7.23, PHP 7.2 on Ubuntu 18.04.

Configuration:
  • Installed the PHP extensions required for Moodle
  • Logged on to SQL and created a Moodle database and user
  • Created the Moodledata directory
  • Used GIT to get Moodle3.7 stable
  • Set up the file permissions
  • Set up Moodle through the browser.
(Easiest and quickest install I have ever done)

Location of class: South China
Location of server: Singapore

In Moodle
Loaded up 370 users in eight user groups to a single course
Created a 6 question quiz ( 3 Multichoice 1 TrueFalse, 1 Short answer). 4 questions have an enbedded picture, resized and saved for web using Irfanview for fast load. A quiz would be an activity I would like to do in class and is considered resource heavy.

I ran my load test three time with three different classes with one class showed 43 online out of a class of 50. Students were told to wait so all could do the quiz together.
Students had to
  • Log on and change their initial password.
  • Navigate to the quiz
  • Complete and submit the quiz
The result:
Fast and responsive. No delay experienced at all -even with more than 40 users doing a quiz at once. CPU never cracked 33%
I did manage to cause a database overload – by waiting for around 15 students to finish the quiz and doing a countdown to push the “submit” button at once. Once the error message was dismissed, all could submit. An unfair test – only a very large number of students would normally cause such a spike.

At least for my purposes, I can run Moodle in class with 50 students for $5 a month. I may find as the database expands I have a slow down but I do have a starting point.

Average of ratings: Coolest thing ever! (2)
In reply to James Steerpike

Re: Re: Why I won't pay annually for a VPS in the future

by Matt Bury -
Picture of Plugin developers
Hi,
I use Digital Ocean too.
What do you use to handle emails? I've installed a local MTA before but have had issues with users getting emails marked as spam, even with the correct DNS server settings.
Thanks in advance smile
In reply to Matt Bury

Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
I haven't got that far yet. Hoping to use an external service.
Average of ratings: Coolest thing ever! (1)
In reply to James Steerpike

Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
Update: Tried to set up a SMTP through Yandex and got the same problem. Don't want to install a mail server ;_(
Average of ratings: Coolest thing ever! (1)
In reply to James Steerpike

Re: Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by Matt Bury -
Picture of Plugin developers
I use Exim - Small, lightweight, easy to use. I only use it to send Moodle notifications & messages, doesn't accept any incoming emails (localhost only), with SPF DNS record set appropriately. It used to work but email servers are becoming stricter to prevent spam, which is a good thing, but that makes it more difficult to get an MTA to work properly. I suspect that finding a good external SMTP service is probably the easiest solution.
Average of ratings: Cool (1)
In reply to Matt Bury

Re: Re: Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
Right. I have password reset emails working from my droplet.
I have a yandex.com mail account and I have used their domain service to send messages ending with my domain name. The setup of the email points to the yandex smtp server but the smtp username is on my domain. Presumably the sender and domain match so not marked as spam.
Should this be a new thread?
Don't know much about Exim but using an external service should be less trouble.
Average of ratings: Coolest thing ever! (1)
In reply to James Steerpike

Re: Re: Re: Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by Matt Bury -
Picture of Plugin developers
As far as I understand it, if you haven't already done so, you may need to update the SPF record on your DNS server account to include the yandex email server. So when an email server gets an email claiming it's from your domain & it checks your DNS SPF record, it gets the yandex mail server included as one of the accepted domains. At least that's how I think it works. Does anyone know more about this?
In reply to Matt Bury

Re: Re: Re: Re: Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
Yes, did that. I will write up a better explanation later today.
Average of ratings: Coolest thing ever! (1)
In reply to James Steerpike

Re: Re: Re: Re: Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by Matt Bury -
Picture of Plugin developers

It seems that every year or so, sending emails from your own server gets more difficult. Setting up DKIM (digitally signing your emails) on your server now seems to be necessary to not get flagged as spam by most of the big email services. And the implementations are getting stricter too.

In reply to Matt Bury

Re: Re: Re: Re: Re: Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
I put a new thread up on installation for the cname change.
In reply to James Steerpike

Re: Re: Why I won't pay annually for a VPS in the future

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
40 users doing a quiz is a nice 'rule of thumb' test.
Average of ratings: Coolest thing ever! (2)
In reply to Marcus Green

Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
I was surprised by the result but again today the server performed flawlessly. That performance at that price makes ideas of sharing and downsizing redundant.
Average of ratings: Very cool (3)
In reply to James Steerpike

Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
What is surprising? The do-it-yourself men get it cheaper than the people who need help.
Average of ratings: Coolest thing ever! (1)
In reply to Visvanath Ratnaweera

Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -
True. But after my quick install I decided to install again without any of the shortcuts I usually made. In the past I have rushed in too quickly to have Moodle up and installed on a server that was not really set up properly.
Even with a 1-click LAMP that has compatible PHP and MySQL there was plenty to do. I wanted to use ssh keys to prevent password stealing, letsencrypt so I could force https, virtual hosts so I can run Wordpress from the same IP address, PHPMyAdmin to simplify database admin, an email address using my domain name, scripts to back up.......
Doing it yourself certainly saves money but requires time and patience. For me, configuring servers feels like doing crossword puzzles. Others may prefer a less time consuming approach.
Average of ratings: Cool (1)
In reply to James Steerpike

Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Well, if your definition of "installing Moodle" is that broad, you need to switch to virtual appliances or containerization.
;-X
In reply to Visvanath Ratnaweera

Re: Re: Re: Re: Why I won't pay annually for a VPS in the future

by James Steerpike -

Where does installing Moodle start? To me, it begins with a clean install of Linux. With a start at the same point, the steps to install are always the same and are as close to foolproof as any install can be.

There are two types of Moodle installs - the try-things-out install and the production install. This installation will have users so it needs to be as secure, as robust and as fast as it needs to be. Even with all that, it needs timely and reliable backups.  Whatever method you use, you still need to understand your system.

For a try-things-out install I would not do all of these things. Since I want my play environment to be as close as possible to my production server, I will be trying one of Windows 10 newer features - the Linux subsystem.