Welcome! Log In Create A New Profile

Advanced

NGINX + mounted CIFS

B0hdan Turkynewych
August 11, 2010 05:10PM
Здравствуйте

Перед тем, как сюда обратиться, я проверил доступную мне документацию,
и опции конфигурации - проблема не решилась апдейтом с 0.7.67 до 0.8.49.

Описание: примонтированная директория по CIFS, около 1000 файлов и папок,
выполнение ls занимает около десяти секунд. При обращении к Nginx (
секция server )
получаю ответ нулевой длины, если рефрешнуть страницу - через 3 или 5
попыток контент
отображается, скачивание по уже готовым ссылкам проходит без
каких-либо затруднений.
При проксировании на самого себя - nginx 0.0.0.0:80 -> 127.0.0.1:8088
рефреш отображает
500 Internal Server Error несколько раз, потом все нормально.

Релевантные строки конфигурации:

# Required for CIFS/NFS shares
sendfile off;
tcp_nopush off;

open_file_cache max=16384 inactive=300s;
open_file_cache_valid 300s;
open_file_cache_min_uses 1;
open_file_cache_errors off;

upstream shareserver {
server 127.0.0.1:8008 max_fails=5 fail_timeout=60s;
}

location /share {

proxy_pass http://shareserver;
proxy_cache_valid 5m;
proxy_connect_timeout 300;
proxy_read_timeout 300;
proxy_send_timeout 300;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-FORWARDED_PROTO https;
proxy_set_header HTTPS on;

}

server {
listen 127.0.0.1:8008;
include share.conf;
}


Далее - содержимое share.conf:

charset koi8-r;

rewrite ^/share/(.*)$ /$1? last;

location / {

root /mnt/lmn;
# No alias here
#alias /mnt/lmn;
autoindex on;
autoindex_exact_size off;
autoindex_localtime on;
auth_basic "Authorization required";
auth_basic_user_file /etc/nginx/share.passwd;



}


Заранее благодарен.
C Уважением, Богдан Туркиневич






WBR, Bohdan Turkynewych AKA Gh0st
_______________________________________________
nginx-ru mailing list
nginx-ru@nginx.org
http://nginx.org/mailman/listinfo/nginx-ru
Subject Author Posted

NGINX + mounted CIFS

B0hdan Turkynewych August 11, 2010 05:10PM

Re: NGINX + mounted CIFS

Maxim Dounin August 11, 2010 08:32PM

Re: NGINX + mounted CIFS

B0hdan Turkynewych August 12, 2010 02:08AM

Re: NGINX + mounted CIFS

Maxim Dounin August 12, 2010 02:02PM

Re: NGINX + mounted CIFS

B0hdan Turkynewych August 13, 2010 03:20PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 189
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready