Question

Problems with nginx and moodle

Hello there, im new on digitalocean. I am tring to install moodle 3.9. on the server but i have problems with the nginx server, it wont start, theres an error but i cant find it. Ive followed these instructions to step by step for installing moodle, but on the last step where i make the last changes on the server configuration file and when i wanna restart the nginx service then im getting an error. These instructions: https://websiteforstudents.com/how-to-install-moodle-on-ubuntu-20-04-18-04-with-nginx-and-lets-encrypt/

Can please someone help me or give me an advice how to solve this problem?

P.S. ive uploaded some screenshots about the problem and what kind of settings i have.

Hope i solve this soon.

ScreenShots are uploaded on imgbb.com: https://ibb.co/b3CxR8D https://ibb.co/mDPgDCd https://ibb.co/sHhfC1k https://ibb.co/VS34BPf https://ibb.co/zhRWNph https://ibb.co/KNV9NVR https://ibb.co/Jdbh3NS https://ibb.co/jGxPpvw https://ibb.co/bgT621f https://ibb.co/WG1Byzs https://ibb.co/R0NDrJ2 https://ibb.co/44pr0KH https://ibb.co/416JFyw https://ibb.co/wSd9Fp8


Submit an answer


This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Bobby Iliev
Site Moderator
Site Moderator badge
November 16, 2020
Accepted Answer

Hi there @pa3k,

From the first image, I can see that you have Apache installed as well. Note that you can have only one service listening on the same port. So it is not possible to have Apache and Nginx running on the same ports.

What you need to do is stop and remove Apache completely and only run Nginx.

For more information on how to troubleshoot common Nginx problems, I could suggest going through this answer here:

https://www.digitalocean.com/community/questions/how-to-troubleshoot-common-nginx-issues-on-linux-server

Regards, Bobby

Hi @pa3k,

in case you haven’t found a working solution yet, I suggest you try out the 1-click Moodle installation from DO Marketplace!

We’re maintaining it up-to-date with the latest Moodle version and support it all the way through.

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Featured on Community

Get our biweekly newsletter

Sign up for Infrastructure as a Newsletter.

Hollie's Hub for Good

Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

Become a contributor

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

Welcome to the developer cloud

DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

Learn more