# Unknown directive "uwsgi\_pass"

**URL:** <https://www.ruby-forum.com/t/unknown-directive-uwsgi-pass/197826>\
**Category:** NGINX\
**Created:** [October 20, 2010, 9:28pm UTC](https://www.ruby-forum.com/t/unknown-directive-uwsgi-pass/197826 "2010-10-20T21:28:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![okkezSS](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/o/85f322/32.png) [@okkezSS](https://www.ruby-forum.com/u/okkezSS)\
**Post date:** [October 20, 2010, 9:28pm UTC](https://www.ruby-forum.com/t/unknown-directive-uwsgi-pass/197826/1 "2010-10-20T21:28:30Z")

</div>

Hello,

I’m new to nginx. We are migrating from Apache to Nginx and I’m having  
this problem when I tried to configure Nginx, uwsgi and django.

[emerg]: unknown directive “uwsgi\_pass” in /etc/nginx/nginx.conf:156  
configuration file /etc/nginx/nginx.conf test failed

I’m using nginx-0.7.67-1.fc13.x86\_64 on Fedora. I have uwsgi installed  
and running.

Any insight on what I did wrong?

Thanks in advance.

Yan Huang

---

<div class="post-metadata">

**Author:** ![Yan\_Huang](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/e9bcb4/32.png) [@Yan\_Huang](https://www.ruby-forum.com/u/Yan_Huang)\
**Post date:** [October 21, 2010, 12:45am UTC](https://www.ruby-forum.com/t/unknown-directive-uwsgi-pass/197826/2 "2010-10-21T00:45:23Z")

</div>

On Wed, Oct 20, 2010 at 03:27:28PM -0400, Yan Huang wrote:

Hi there,

> I’m new to nginx. We are migrating from Apache to Nginx and I’m having  
> this problem when I tried to configure Nginx, uwsgi and django.
> 
> [emerg]: unknown directive “uwsgi\_pass” in /etc/nginx/nginx.conf:156  
> configuration file /etc/nginx/nginx.conf test failed

That strongly suggests that the nginx you are using does not include  
the uwsgi module.

> I’m using nginx-0.7.67-1.fc13.x86\_64 on Fedora. I have uwsgi installed  
> and running.

The srpm at

ftp://mirror.switch.ch/pool/2/mirror/fedora/linux/updates/13/SRPMS/nginx-0.7.67-1.fc13.src.rpm

doesn’t mention uwsgi at all, as far as I can see.

> **[GitHub - nginxinc/nginx-wiki: ARCHIVED -- Source for the now archived NGINX Wiki...](https://github.com/nginxinc/nginx-wiki)**
>
> ARCHIVED -- Source for the now archived NGINX Wiki section of https://www.nginx.com

has some references at the end. One says that the uwsgi module was  
included in nginx from 0.8.40. It describes how to add it to an 0.7  
series build.

Another is from April and is titled “Running Django with Nginx and  
uWSGI”. It might be interesting.

> Any insight on what I did wrong?

Just using an nginx which doesn’t speak the uwsgi protocol.

You’ll have to find-or-build an 0.7 one with the extra module included,  
or else find (or build) a recent 0.8 version, which will include uwsgi  
by default.

Good luck with it,

## f

Francis D. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)
