# Moodle

**URL:** <https://www.ruby-forum.com/t/moodle/202930>\
**Category:** NGINX\
**Created:** [February 9, 2011, 5:16am UTC](https://www.ruby-forum.com/t/moodle/202930 "2011-02-09T05:16:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dubstep](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/cdc98d/32.png) [@dubstep](https://www.ruby-forum.com/u/dubstep)\
**Post date:** [February 9, 2011, 5:16am UTC](https://www.ruby-forum.com/t/moodle/202930/1 "2011-02-09T05:16:54Z")

</div>

Hi

Anyone experienced running Moodle under Nginx instead of Apache?

If yes,

1. how to get fastest possible Moodle access under Nginx?
2. I thought Nginx doesn’t handle dynamic pages well?
3. Can I do away with Apache then?

Frankie Kam  
[http://scm.moodleace.com](http://scm.moodleace.com)

Posted at Nginx Forum:

> **[Moodle](https://forum.nginx.org/read.php?2,173417,173417#msg-173417)**
>
> Hi Anyone experienced running Moodle under Nginx instead of Apache? If yes, 1) how to get fastest possible Moodle access under Nginx? 2) I thought Nginx doesn't handle dynamic pages well? 3) Can I do away with Apache then? Frankie Kam

---

<div class="post-metadata">

**Author:** ![frankiekam](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/e9a140/32.png) [@frankiekam](https://www.ruby-forum.com/u/frankiekam)\
**Post date:** [February 9, 2011, 5:20am UTC](https://www.ruby-forum.com/t/moodle/202930/2 "2011-02-09T05:20:03Z")

</div>

On Tue, Feb 8, 2011 at 8:15 PM, frankiekam [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Hi
> 
> Anyone experienced running Moodle under Nginx instead of Apache?

Moodle runs just fine (as fine as it can, I am not a fan)

> If yes,
> 
> 1. how to get fastest possible Moodle access under Nginx?

I don’t think it requires anything special off the top of my head. If  
it supports friendly URLs, then you’d need to add in whatever rewrite  
for that.

> 1. I thought Nginx doesn’t handle dynamic pages well?

nginx doesn’t handle it, it proxies the FastCGI request off. I  
recommend PHP-FPM. I have used this combo for years, and Moodle  
underneath that as well for probably going on two years now.

> 1. Can I do away with Apache then?

Yes.

---

<div class="post-metadata">

**Author:** ![frankiekam](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/e9a140/32.png) [@frankiekam](https://www.ruby-forum.com/u/frankiekam)\
**Post date:** [February 9, 2011, 5:53am UTC](https://www.ruby-forum.com/t/moodle/202930/3 "2011-02-09T05:53:59Z")

</div>

On 9 Fev 2011 04h15 WET, [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Hi
> 
> Anyone experienced running Moodle under Nginx instead of Apache?
> 
> If yes,
> 
> 1. how to get fastest possible Moodle access under Nginx?
> 2. I thought Nginx doesn’t handle dynamic pages well?

Neither does Apache. What handle the dynamic pages is the PHP  
interpreter living under the table that Apache with mod\_php provides.

> 1. Can I do away with Apache then?

Yes. I had to enable cgi.fix\_pathinfo to get it work. I dit it through  
a php.ini file in the root directory of the site.

Could be something with my config. Moodle is an app I know quite  
badly, also the client was in a hurry to get the site migrated  
completely to Nginx. I didn’t had much time to try different  
approaches. This one was working, hence…

— appa
