July 18, 2011 11:46AM
we are a video hosting company and storing files in mp4 format. we have another server, its litespeed and handle nearly 1gbit connection succesfully. slow but it is responsing requests at least. but this new server (nginx) cant handle requests. if bw usage hit the 150-200mbit its going down. actually not down, just doesnt response any http request. we tried and also hired someones and they tried but no success. this is the last chance. is there anybody knows what the problem?

here is the nginx.conf
******************************************************************************************************************************************
#user nobody;
worker_processes 8;
worker_rlimit_nofile 20480;

error_log /var/log/nginx/error.log info;

#pid logs/nginx.pid;


events {
worker_connections 768;
use epoll;
}


http {
server_name_in_redirect off;
server_names_hash_max_size 2048;
include mime.types;
default_type video/mp4;
server_tokens off;
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
# '$status $body_bytes_sent "$http_referer" '
# '"$http_user_agent" "$http_x_forwarded_for"';

#access_log logs/access.log main;

sendfile on;
tcp_nopush on;
tcp_nodelay on;
connection_pool_size 256;

#keepalive_timeout 0;
#keepalive_timeout 300;

#gzip on;

server {
listen 80;
server_name localhost;

#charset koi8-r;

#access_log /var/log/nginx/access.log combined;

location / {
root /home/username/public_html;
index index.php index.html index.htm;


location ~* \.(mp4)$ {
expires max;
add_header Pragma public;
add_header Cache-Control "public, must-revalidate, proxy-revalidate";
}

# location ~ \.flv {
# accesskey on;
# accesskey_hashmethod md5;
# accesskey_arg "key";
# accesskey_signature "mypass$remote_addr";
# flv;
# }

# location ~ \.mp4 {
# accesskey on;
# accesskey_hashmethod md5;
# accesskey_arg "key";
# accesskey_signature "mypass$remote_addr";
# mp4;
# types {
# video/mp4 mp4;
# }
# }


location /nginx_status {
stub_status on;
access_log off;
allow all;
#deny all;
}

}

#error_page 404 /404.html;

# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}

# proxy the PHP scripts to Apache listening on 127.0.0.1:80
#
#location ~ \.php$ {
# proxy_pass http://127.0.0.1;
#}

# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
location ~ \.php$ {
root /home/cdn1280/public_html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /home/username/public_html$fastcgi_script_name;
include fastcgi_params;
}

# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
}
******************************************************************************************************************************************

and nginx -v


nginx: nginx version: 1.0.4


our server has 1tb hdd and 12gb ram and 8core cpu and 1gbit line
Subject Author Posted

very poor performance for serving static files

asdasd77 July 18, 2011 11:46AM

Re: very poor performance for serving static files

zls July 18, 2011 12:32PM

Re: very poor performance for serving static files

Maxim Dounin July 18, 2011 12:46PM

Re: very poor performance for serving static files

asdasd77 July 19, 2011 03:39AM

Re: very poor performance for serving static files

Maxim Dounin July 19, 2011 05:08AM

Re: very poor performance for serving static files

asdasd77 July 19, 2011 05:42AM

Re: very poor performance for serving static files

Maxim Dounin July 19, 2011 07:54AM

Re: very poor performance for serving static files

asdasd77 July 19, 2011 08:15AM

Re: very poor performance for serving static files

locojohn July 19, 2011 06:35PM

Re: very poor performance for serving static files

asdasd77 July 20, 2011 03:29AM

Re: very poor performance for serving static files

Igor Sysoev July 20, 2011 03:36AM

Re: very poor performance for serving static files

asdasd77 July 20, 2011 04:22AM

Re: very poor performance for serving static files

Igor Sysoev July 20, 2011 04:54AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 181
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