First, I was really thrilled to be able to get open edX running thanks to Tutor. It’s amazing how tutor has made this possible for me and my small startup company, given how little I know about server admin. It’s now running on a 4GB RAM, 2 CPU DigitalOcean droplet.
However, when I actually started building courses, I quickly found out that it was on the verge of being unusable. Regularly getting 504 timeouts, and just really slow load times loading a page in studio.
I checked out docker stats
and saw that tutor_local_elasticsearch_1 is using 1.22 GB memory, which is over 30% of the total memory available. Is this expected? No-one is searching for anything as I’m the only one using the site.
I expect that paying double and getting a 8GB / 4 CPU droplet would solve this, but we can’t afford that at the moment. This is going to be a closed course with under 10 simultaneous users at any time. According to what I read here, it may be possible to reduce memory requirements. That page is on the very edge of my ability to comprehend, but it seems like reducing the number of workers for the LMS, CMS, and xqueue might be able to help.
Here is what I have tried so far, in ~/.local/share/tutor/config.yml:
RUN_FORUM: false
OPENEDX_CMS_UWSGI_WORKERS: 1
OPENEDX_LMS_UWSGI_WORKERS: 1
ELASTICSEARCH_HEAP_SIZE: "0.5g"
I then did a reboot using tutor local reboot
. It does seem snappier now, which is great. However, when I run docker stats
, I still see elasticsearch is using 1.2GB. While search is an important feature, I would turn it off if this was massively slowly down the system. So I’ve got a few questions:
- Is trying to reduce memory available to elasticsearch a good idea?
- Why didn’t
ELASTICSEARCH_HEAP_SIZE: "0.5g"
in my config seem to do anything? I also tried"500mb"
, thentutor local restart elasticsearch
, but to no avail. - Is it a mistake to set the UWSGI workers to 1?
- Does anyone have any other suggestions to get the platform running smoothly on this ‘minimum spec’ hardware, considering there will be very few concurrent users?