Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
Number of replies: 35

Hello 

I am a beginner in Moodle.

I have a project to use it in rural schools ,with few students ,where they don't have internet .

The idea is to install moodle on a local server and have the students connect through a wireless network to the platform.

As the budget is limited, I thought about using a Rapsberry Pi4, but that board  is not available in the market for some time.

I have thought of using instead, the Orange Pi5 which is much more powerful than the Pi 4.

Will it be possible to use it?

For schools or colleges with more students I would like to use a NAS from QNAP company. 

Same query, is it possible?

Best regards

Average of ratings: -
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Brett Dalton -
Picture of Moodle HQ Picture of Particularly helpful Moodlers
Hugo, some idea of the number of users would be useful Concurrenty will be a big issue as will memory, you might want to look for a platform where memory isn't as tight as the Pi's or split the database and web server to different boxes at a min. Its all doable but perfomance will not be great with more than a small number of users logged in at the same time.

If you are looking at running this on a super tight budget I would also strongly suggest some students and teachers education on using small and minmal images, videos content may be problematic or not an option, and avoid using quizzes where you know you will have a large number of users hitting the system at the same time as that is known to case problems.
Average of ratings: Useful (2)
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Yes, the shortage of Raspberry Pi is a shame. Otherwise there is a "turn-key" device called MoodleBox https://moodlebox.net/. But don't let the Raspberry Pi flag-ship model 4 B deceive you. MoodleBox run on Pi 3 A+, 3 B, 3 B+ and even on Zero 2 W!

It is a project separate from moodle.org with their own community forum https://discuss.moodlebox.net/.

If you target whole schools, you are going to have performance problems. The built-in access point in the MoodleBox can support only about 25 wireless connections at a given time. You can reach more by adding external access points, connecting to a cabled network, etc. But don't forget, R Pi was made to be an embedded device, not a server!
Average of ratings: Useful (3)
In reply to Visvanath Ratnaweera

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
Thanks

These communities are very small and their schools have no more than 20 students per course , in the worst case.
I read on the Moodle website that for every 50 users 1 GB of memory is required, in our case, we are not going to reach that amount of students, at least in these communities.
It is a good idea to separate the servers , one WEB and the other for the contents.
Although the budget is limited, if we could adjust it to meet the minimum hardware requirements recommended for this application, but we could not invest in servers for more professional applications, such as those using INTEL XEON processors or something like that.
I was comparing the specs of the Orange Pi5 with the Rapsberry PI4 and from that point of view it is far superior, it has 8 cores, up to 32 GB of RAM, Gigabit port, Debian 11 support, etc.

Best of all, it is available in the market starting at $80, so I thought it could be a good option and hence the query.

Another option would be a NAS as a web and database server.

Best regards
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
From just a quick scan of the Orange Pi web site and forum listings, I would say that it is a pretty safe bet that you can get some form of Linux and Moodle to work on an Oragne Pi5.

I kick myself every time I think about only getting two of the Pi4's back when they first came out. I've been so sick with various aliments for the past two months, that I have not done much playing around with small board computers, but think I will add to my arsenal of development servers and get at least one Orange Pi5. Maybe more. 😁
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Yes, this path can be traveled in either direction: start with an application, a use-case scenario and find the technology or start with a technology and find the use-case(s). It is not clear to me which way you are facing.

Moodle and the tall software stack below it are all Free and Open Source. (Well not all, but the LAMP/LEMP path is.) You can install (package) them in all sorts of hardware. Or go for a packaged solution. The pros and cons are obvious. The packaged one requires less time. It is a positive thing for some, unacceptable for others, because they miss the fun of making the thing!
In reply to Visvanath Ratnaweera

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -

Thank you for your comments

It seems that the only way out of the doubt will be to install and test Moodle on the hardware of my choice.

Initially, regardless of the performance of the server with respect to the number of concurrent users, my main concern is whether I can install and run Moodle on both types of hardware (Orange Pi5 or NAS). Then would come the tests to evaluate the performance with respect to the number of users.

QNAP NAS allow to create virtual machines and support some versions of operating systems, from windows to linux, so from that point of view, it should work with Moodle.

Best regards

In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
Because I love playing with tech hardware, I bought an 8GB RAM Orange Pi 5. It DOES run Moodle as I have almost finished setting up a QA Testing server with MariaDB and PHP 8.1.2, for Moodle 4.2. There are a couple of nice features that it has, that the Raspberry Pi does not. First is a built in power switch. It also has an SSD slot for M.2 M-KEY Socket Expansion Slot. Seems you can use an SSD there or plugin a special WiFi module. You might be able to buy a USB WiFi, but I'm not sure. NOTE: I am a little hazy on this as they just supply a picture but limited text about what you see.

One down side I have noted is that the Orange Pi support forums are a joke compared to what you see here at Moodle. I have not found any useful info when using their search. When I just looked through the forum top level, there are a number of what looked to be very useful forums. However, when I went in them, invariably they were full of entries that absolutely have nothing to do with the Orange Pi hardware. I guess they don't have any moderators.
Average of ratings: Useful (2)
In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
This is good news

From the beginning I thought that if the Moodlebox works well with the Rapsberry Pi and has been very successful, there should be no problem to run Moodle on the ORANGE Pi 5, if it is known that some of its specifications are superior to the RP. Is this comparison correct?

I still have another question and it is very important.

Is it possible to estimate what would be the maximum user traffic that could support the ORANGE Pi5? Again, taking Moodlebox as a reference.

Indeed, the Orange Pi forum is not very useful. A few weeks ago I asked a question and I never got an answer.

Regards
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Brett Dalton -
Picture of Moodle HQ Picture of Particularly helpful Moodlers
its not really possible to easily estimate that. I will be extremely dependent on the volume of content, types of content (text only vs images vs video), number of quizzes, size of the quizzes etc etc. it will also be very dependent on the storage you use as well, network storage will perform far far slower than an SSD locally for example
In reply to Brett Dalton

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -

I understand

What information would go if I install an SSD in the ORANGE PI?

Regards

In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

"From the beginning I thought that if the Moodlebox works well with the Rapsberry Pi and has been very successful, there should be no problem to run Moodle on the ORANGE Pi 5, if it is known that some of its specifications are superior to the RP. Is this comparison correct?"

Basically, the answer is yes, with the noted limitation that the Orange Pi5 comes in various models some of which include WiFi and some that do not. The one I bought does not have it included, but since I am usually the only user, it doesn't really matter to me.

In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -

I think that the WIFI option is not important in this case, but the RAM is.

Is 8 GB enough ? Or better to upgrade to 16 GB?

 I have also read that it is advisable to implement a WEB server and a database server separately.

 In this project there will be few users (less than 20 students). Do you consider necessary to use two servers? Could I use the Orange PI 5 for both services?

Regards

In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
I went with what I could order quickest, which was the 8GB, but should be enough for a small site. If I had found a 16GB that was not going to take at least a month to arrive, I probably would have gotten that. Being just a developer I almost never have more logged in, than the different types of browsers I have installed on my desktop, which is currently five.

I will say, my first years of using Moodle 1.4 up to Moodle 1.9, ran just fine for a max of 17 users with both WEB server and DB on the same 66MHz, 4 GB RAM server. Of course neither component compares to what is in use today, but I would still try both on the same computer first as you could always separate them later. The reason is that performance is much better with both components on the same computer, than that you get when having to pass the DB data through the network.
Average of ratings: Useful (1)
In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
AL, I'm so glad you said, "my first years of using Moodle 1.4 up to Moodle 1.9, ran just fine for a max of 17 users with both WEB server and DB on the same 66MHz, 4 GB RAM server." I remember Moodle 1.6 and 1.9. They were incredibly efficient.

Hugo, ever heard of “Premature optimization is the root of all evil”?
Average of ratings: Useful (2)
In reply to Visvanath Ratnaweera

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
The content of the message is indeed very true.
I also believe that every day you learn something new, I thank you for sharing your experience.
In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -


Al is very important your advice, it is better to have everything in a single PC, at least in this project (few users), I will adopt it. 

thanks

Average of ratings: Useful (1)
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

As an added note, I went ahead and got another Orange Pi 5, this one with 16GB of RAM, but still without WiFi. I also got two Samsung SSD 256GB Nvme M.2 internal solid state drives, one for each Pi.

It did not take very long to get the Orange Pi 1.1.4 Jammy operating system installed along with Apache2, MariaDB, phpMyAdmin, and the master branch of Moodle installed and running. I forgot to look but it was somewhere around an hour to complete the setup.

 I needed another QA Testing server and I must stay that so far I have been pretty impressed with the performance of both Pi's. Without actually measuring yet, the Orange Pi 5's do definitely seem to outperform the Raspberry Pi 4's.

Had to measure so just went and ran the Bench mark but at the moment, I am comparing apples raspberries and oranges. They're not running the same Moodle versions and both are giving me cURL errors, but the OP score was 70 points and RP score was 310. Quite a difference!

Average of ratings: Useful (2)
In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
Hello

Sorry but I'm a bit confused with the tests.

What version of Moodle did you install on the OP and RPi4?

Are the test results definitive, RPi4 is superior to the OP?

Because indeed the difference is quite high.

Regards
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

Hi Hugo,

Sorry, I was not more clear in what I typed. The Raspberry Pi 4 was running the latest Moodle 4.1.2+ on the full ARM server version of Ubuntu 22.04 LTS.

The Orange Pi 5 was running the master branch code of Moodle, that in a couple of weeks will be released as Moodle 4.2.0, using the Orange Pi ARM server operating system Jammy 1.1.4. I am pretty sure that it might be based on Ubuntu as all the bits and pieces of code I have looked at, are all in the same place and work the same way.

I ran the plugin, Moodle Benchmark, which you can get and install from here: https://moodle.org/plugins/report_benchmark

Note that when looking at the resulting Benchmark Score, that LOWER is better. So the Orange Pi score of 70, is MUCH MUCH better than the Raspberry Pi score of 310. Note that the first run for both was slightly better than four more runs on both Pi's. (Just ran benchmark on the OP two times and the first was 84, which is very good, but the second, was a 58!)

For the past couple of months, when I could work, I have been using the Raspberry Pi 4 setup as my development server, but with the Orange Pi being so much faster, yesterday I started transferring all my development code to it. Just need to do a database dump from the RP4 and import to the OP5.

Attachment OrangePi5bm1.png
In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
Thanks for your explanation

Now if I understand the result of the tests, I thought that the higher the rating was better, that's why I was confused.

Indeed, the difference is very big between the two SBCs

Do you think that even with 8 GB of RAM the ORANGE Pi 5 will be superior to the PI4?

I apologize if my question is not correct, I know very little about operating systems, and even worse about Linux, but will it be better to use Debian than Ubuntu?

Regards
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

Do you think that even with 8 GB of RAM the ORANGE Pi 5 will be superior to the PI4? - Yes I do as I have everything setup and working fine on both my original 8GB Orange Pi 5 and my 16 GB one. Granted, yesterday when I loaded up my dev site the Benchmark scores went up on average to about 115, but that is still about three times better the the Pi4 scores.

... but will it be better to use Debian than Ubuntu? - I don't know. I have not used Debian, that I can remember, in a long time. I think it just mainly comes down to your personal preference as at their heart, they are both Linux, with a few differences that each set of maintainers have added. My personal preference was Centos but it seems to be changing to Stream, which is why I have temporarily moved my development setup to a SBC. I needed to move everything so I could rebuild my main server and replace the old 500GB SSD with a new 2 TB SSD. Then I got sick and had eye infections and the whole process has drug on to the point I have not even started the rebuild, plus other projects and needed updates to my plugins keep intruding.

Average of ratings: Useful (1)
In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -

I'm sorry you are sick

According to the benchmark scores you kindly shared with me, the OP would not only be useful for running Moodle, but also for other projects, and best of all , it's available

For example, at the moment, I need to configure a DHCP server to install an entertainment platform for users on a local wireless network in passengers  buses.

This cover with heat sink included seems to be very useful too. 

OP aluminum case with enclosure

I hope you recover your health very soon

Best regards



Attachment Aluminum case.jpg
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by AL Rachels -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

Thanks for your concern. I have been getting better.

I would imagine that for the DHCP server, you could probably go with any of the smaller and cheaper Pi's, using ones from Raspberry or Orange sources. It's been done already by others and you might be able to get more info by doing a DuckDuck Go or Google search.

I thought about using that same cover, but have decided to build my own dog bone tower that will let me stack both of my Orange Pi 5's and both of my Raspberry Pi's.

Average of ratings: Useful (1)
In reply to AL Rachels

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
With the result of your tests, I would like to evaluate the performance of the OP in some additional applications I have for this year. However, for the DHCP server project, it is a good suggestion to use the smaller Pi.

Regards
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators

> I read on the Moodle website that for every 50 users 1 GB of memory is required,

Source please?

Is it possible that you overlooked a word, a critical one? Namely, that it is about _concurrent_ users as in:

The term "concurrent users" is used to mean those users for whom the server is actively doing something . It may by processing a webpage written in PHP, querying the database or simply transferring a file. (see also Wikipedia Concurrency). Strictly speaking we mean the number of active web server processes (each of which consume memory) and also the number of database connections.

Source https://docs.moodle.org/401/en/Performance_FAQ#How_do_you_define_.22concurrent_users.22.3F.

In reply to Visvanath Ratnaweera

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
I have understood that the terms parallelism and concurrency are synonyms, apparently I have been wrong.

So far I have thought it more convenient to assume the worst case scenario for sizing the hardware (server). For example, if there are 20 students in a class, it could be the case that the teacher asks all the children to open some video (480 p resolution) from the database server on their mobile phones, while explaining the content. In this case, there would be 20 users connected simultaneously reviewing the same content (streaming).

That is the scenario I am referring to with concurrent users.

As I mentioned from the beginning, in these rural schools the courses are of few students (no more than 20) and generally do not have laptops or PCs, most of them only have a mobile phone.

Therefore, the kids will connect to the Moodle server through a local wireless network with enough bandwidth to serve these few students.

From my point of view, the most critical in this project, are the server specifications, that is, what are the minimum resources needed (RAM, cores, processor frequency, etc.)

Regards
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
> I have understood that the terms parallelism and concurrency are synonyms, apparently I have been wrong.

Understood What? Still the sources for earlier statement are missing. If these understandings are not in Moodle Docs, there is nothing for me to discuss.

> So far I have thought it more convenient to assume the worst case scenario for sizing the hardware (server).

No harm in looking at the worst case scenario. (I assume that you know this is the worst case scenario  in those classrooms.)

> if there are 20 students in a class, it could be the case that the teacher asks all the children to open some video (480 p resolution) from the database server on their mobile phones, while explaining the content.

Sure it is feasible. The only thing, Moodle does not save the uploaded files in a database, they are in a directory structure in the computers file system, which Moodlers call Repository or moodledata.

> In this case, there would be 20 users connected simultaneously reviewing the same content (streaming).

True. The server will be "streaming" (it is no real streaming, rather the clients successively downloading) 20 files in parallel.

> That is the scenario I am referring to with concurrent users.

Then it is not the same as what we understand: https://docs.moodle.org/401/en/Performance_FAQ#How_do_you_define_.22concurrent_users.22.3F.

> From my point of view, the most critical in this project, are the server specifications, that is, what are the minimum resources needed (RAM, cores, processor frequency, etc.)

Not from my point of view. By clever choice of the web server (Nginx, x-send-file, etc.) you can minimize the load on the server during pure file transfer. That is exactly what MoodleBox does.

But that won't be the end of the problems. The next bottleneck will show up. I have never "streamed" 20 videos from a Raspberry Pi but expect the wi-fi to break. Wireless is a shared media with lot of loss. But don't take my word for it, you have to test, or ask in the relevant forums. moodle.org is too Moodle-centric for that, go to the forums related to your hardware, Raspberry Pi forums if R Pi, to https://discuss.moodlebox.net/ if MoodleBox, etc.

In reply to Visvanath Ratnaweera

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
I apologize, I forgot to mention where I found the information.

In one of the searches for information about Moodle, on the internet, I found this explanation.

An estimate guideline states that you should be prepared to have 1 GB of RAM on your Moodle server for every 50 concurrent users. Or 20 MB of RAM per student at a minimum (the more to spare the better). Check out all of the recommended hardware/software needs at http://docs.moodle.org/en/Installing_Moodle#Hardware.

Since the name of Moodle appears in this link, I thought that the explanation about the amount of RAM was official, and that's where my confusion with the term concurrent came from.

thanks
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
> An estimate guideline states that you should be prepared to have 1 GB of RAM on your Moodle server for every 50 concurrent users. Or 20 MB of RAM per student at a minimum (the more to spare the better). Check out all of the recommended hardware/software needs at http://docs.moodle.org/en/Installing_Moodle#Hardware




Could you pl. point me your quote there?

Coming to that section, did you really believe the numbers there?
===
  • Disk space: 200MB for the Moodle code, plus as much as you need to store content. 5GB is probably a realistic minimum.
  • Processor: 1 GHz (min), 2 GHz dual core or more recommended.
  • Memory: 512MB (min), 1GB or more is recommended. 8GB plus is likely on a large production server
===

Similarly, a saying "1 GB per 50 users" or something like that reveberates here. Talk to its inventor: https://moodle.org/mod/forum/discuss.php?d=171116#p750390.
smile

In reply to Visvanath Ratnaweera

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
I made the mistake of not accessing the link and assumed that the text had been extracted from the Moodle web site.

As I indicated at the beginning, I have just learned about Moodle and I think it is exactly what I need for my project, at the beginning I started researching in several websites about the platform, where I found a lot of information that ended up confusing me, that's why I decided to subscribe to the community. It is definitely the only sure way to understand what is related to hardware and software.

Thank you for helping me
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
I think you've done enough reading. The next step is the practice. Install and run Moodle in DIY style, on your own hardware. Whether PC architecture, ARM or any other NAS thing doesn't matter. If you want to be able to move from one to the other, advice to take Linux as the OS.
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
"Best of all, it is available in the market starting at $80, so I thought it could be a good option and hence the query.

Another option would be a NAS as a web and database server."

Support is an essential, arguably the most important ingredient in offering service using Moodle. Those technologies are not directly supported. You are better off getting a generic computing platform and finding out what works for you. Moodle and performance are very much an "it depends" sort of thing. That is a very frustrating answer but it is reality.
Average of ratings: Useful (1)
In reply to Marcus Green

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Hugo Casal -
Hello Mr Green

I understand and appreciate your response

I will evaluate all options

Best Regards
In reply to Hugo Casal

Re: Is it possible to install and run moodle on an Orange Pi5 or on a QNAP NAS?

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
Thanks for posting your original question and please keep posting here as it can help others make their decisions. Also, good luck in your research.