Nginx error : open failed 2 no such file or directory

Mapper Uno lists at
Thu Oct 9 19:28:26 UTC 2014


I've written a small nginx module that serves files (with some extra
functionality).  When I access the files through HTTP POST,  I get below

[error] 2971#0: *184 open()
failed (2: No such file or directory), client:, server:
localhost, request: "POST /1/3/49123876 HTTP/1.1", host:

HTTP client uses  URI as  1/3/49123876.  And the call is routed to my
module correctly, however, the nginx log shows  above error. I'm not
sure why is nginx trying to look into
/home/user/build/default/main/nginx/ ....

The module functions correctly and serves the files that are requested,
however, why would I see above error then.

Here is my nginx config:  Please note  'my_pass' directive for my module
that handles the request.

            worker_processes 1;
            master_process off;
            daemon off;
            error_log stderr notice;

            events {
                worker_connections 256;

            http {
                default_type application/octet-stream;
                keepalive_timeout 60;

                client_body_in_single_buffer on;
                client_body_buffer_size 20m;
                client_max_body_size 20m;

                server {
                    listen 9000;
                    server_name localhost;
                    location / {
                        my_pass /home/ubuntu/mugen_config.json;

$ nginx -V
nginx version: ngx_openresty/
TLS SNI support enabled
configure arguments:

Posted via

More information about the nginx mailing list