我想知道是否有任何方法来find一个积极运行的进程(如Apache或Nginx)的tcp so_sndbuf。 我知道tcp_wmem设置了默认值,但是我不知道我正在使用的服务器程序是否设置了它们自己的。 我的目的是,我试图设置初始窗口(IW)(请参阅此链接为什么)的TCP连接。 我从google看了这篇文章 ,他们build议把你的tcp_wmem默认值改成MSS * IW。 不过,我担心,程序可能会设置自己的so_sndbuf而不是使用tcp_wmem,所以我想仔细检查。 我正在使用Linux内核2.6.18-194.26.1.el5(CentOS)。
我有nginx的下面的configuration文件。 问题是所有的stream量都会进入上游的clustera。 如何将nginxconfiguration为仅将example.com的stream量发送到clustera,其余的则发送到clusterb? user www-data; worker_processes 1; error_log /var/log/nginx/error.log; pid /var/run/nginx.pid; events { worker_connections 1024; } http { include /etc/nginx/mime.types; log_format cache '\n*** $remote_addr [$time_local] ' '[$upstream_cache_status] $upstream_response_time ' '$host "$request" ($status) $body_bytes_sent ' '"$http_referer" "$http_user_agent" ' 'Cache-Control: $upstream_http_cache_control ' 'Expires: $upstream_http_expires ' ; access_log /var/log/nginx/access.log cache; sendfile on; keepalive_timeout 65; gzip on; gzip_vary on; […]
我已经设置了一个域名在amazon ec2上运行,运行ubuntu 11.04,nginx和php5-fpm。 域名工作的很好,我已经build立了自己的网站 – 可用的configuration文件和sym – 链接到网站启用。 我通过sudo apt-get install phpmyadmin安装了phpmyadmin并按照说明操作。 然后我把它添加到我的/etc/nginx/nginx.conf文件的上面,并重新启动了nginx。 server { listen 80; server_name phpmyadmin.domain.com; location / { root /usr/share/phpmyadmin; index index.php; } #make sure all php files are processed by fast_cgi location ~ \.php { # try_files $uri =404; fastcgi_index index.php; fastcgi_pass 127.0.0.1:9000; include fastcgi_params; fastcgi_split_path_info ^(.+\.php)(/.+)$; fastcgi_param PATH_INFO $fastcgi_path_info; […]
我正在尝试为我的nginx_request插件( http://exchange.munin-monitoring.org/plugins/nginx_request/version/2 )聚合munin图表( http://munin-monitoring.org/wiki/aggregate_examples ) 我有的configuration是: [lb1.domain.com] address 192.168.170.112 use_node_name yes [lb2.domain.com] address 192.168.174.9 use_node_name yes [TRAFFIC;Aggregated] update no contacts no nginx_requests.graph_title nGinx requests nginx_requests.graph_vlabel nGinx requests per second nginx_requests.draw LINE2 nginx_requests.graph_args –base 1000 nginx_requests.graph_category nginx nginx_requests.label req/sec nginx_requests.type DERIVE nginx_requests.min 0 nginx_requests.graph_order outputrequest nginx_requests.outputrequest.sum \ lb1.domain.com:nginx_request.request \ lb2.domain.com:nginx_request.request 我也尝试了一些不同的configuration设置,但图表不起作用。 有人可以帮我find正确的configuration设置
我的服务器运行ubuntu 64bit,nginx,php-fpm。 一切正常。 但几天后。 浏览器显示“没有指定input文件”。 我重新启动php-fpm之后。 一切运行良好。 但是这种情况一再发生。 所以我必须重新启动php-fpm几天。 任何人都知道有什么问题? nginx -V输出 sshadmin@ubuntu:~$ nginx -V nginx: nginx version: nginx/0.9.7 nginx: built by gcc 4.4.3 (Ubuntu 4.4.3-4ubuntu5) nginx: TLS SNI support enabled nginx: configure arguments: –user=www –group=www –prefix=/usr/local/nginx –with-http_stub_status_module –with-http_ssl_module –with-http_gzip_static_module
我正在为nginx + apache进行testing设置。 我有nginx监听端口80,端口8080上的apache。Nginx设置为处理静态内容,Apache有dynamic内容处理(至less直到我们可以升级到PHP 5.3)。 我的apache设置工作正常,这里是nginx的服务器部分: server { listen 80; server_name mediocregopher-test; index test.php; location ~ \.php$ { proxy_pass http://127.0.0.1:8080; } location ~ /\.ht { deny all; } location / { root /var/www/html; } } 问题是,当有人请求“mediocregopher-test:80 /”时,我的索引页面(test.php)需要被代理到apache为“127.0.0.1:8080/test.php”。 有了这个设置,这不会发生。 我对nginx相当陌生,但是我环顾四周,找不到任何可以解决这个问题的设置(尽pipe问题太简单了,看起来像是这样)。 有什么build议么? 我使用nginx 1.0.1,如果这是相关的。
我即将把一个高stream量的网站移植到VPS上的Drupal v6.x(也许是7.x)。 我以Ubuntu的名义对Linux有一些经验。 当然,我可以在一个托pipe的VPS包中继电器。 我怎么想select最好的设置。 我select的VPS软件包包含以下软件和硬件: CentOS 5 CPU:1 Ghz(1核心) 内存:512 MB 磁盘:40 GB Raid 6 现在我想知道最好的configuration是什么。 我的意思是作为基本的networking和邮件服务器,但也是我应该做的caching。 我在Drupal.org上阅读了很多信息,还有一个名为Pressflow的软件包,它是针对高stream量网站的Drupal优化版本。 有人提到这些名字: memcache(在Linux上的caching模块?) nginx(某种web服务器更像apache?) 清漆(在Linux上的caching模块?) 我明白他们是什么,但他们如何适合在一张照片? 所以基本上我正在寻找一个可以清理图片的人。
我有一个使用phpMyAdmin 3.4.1导入20mb sql dumo的问题。 正如你在这里看到的那样,max scipt的执行时间有很大的值。 在Apache日志中,我看到以下内容: [Thu Jul 14 16:28:37 2011] [error] [client 195.64.203.162] Premature end of script headers: php, referer: http://hosting-rus.ru/mysql/phpMyAdmin341/db_import.php?db=jbs3&server=1&token=141da7abe59b0f8f53b3ce32fd6f9ead [Thu Jul 14 16:28:37 2011] [debug] mod_deflate.c(615): [client 195.64.203.162] Zlib: Compressed 624 to 377 : URL /php-bin/php/mysql/phpMyAdmin341/import.php, referer: http://hosting-rus.ru/mysql/phpMyAdmin341/db_import.php?db=jbs3&server=1&token=141da7abe59b0f8f53b3ce32fd6f9ead 而现在我不知道如何解决这个500错误,同时导入SQL转储。 你可以帮帮我吗? TIA!
我们希望将我们所有的服务器从lighttpd切换到nginx,但是当Web服务器迁移正常时,静态文件服务器迁移是灾难性的。 我们结束了长达10秒的加载图片的延迟,使用这个configuration与nginx: 主要configuration: https : //gist.github.com/1089283 现场示例: https : //gist.github.com/1089276 有4个站点,每天大约有12万个访问者,消耗大量stream式video和video。 我们有一个提示是重新启动nginx后,加载图片总是非常快。 CPU或内存消耗总是非常小,所以我们虽然关于磁盘。 我们试图调整文件描述符的限制,但没有改变任何东西。 我们切换回lighttpd,我们又恢复了业务,几乎是瞬间的图片加载。 我们知道我们做错了什么,但是什么? 只需要维护一个服务器就可以了,而且nginx比lighttpd更容易设置。 您在这里看到的configuration文件是针对专用于静态文件和videostream的虚拟机上的nginx(使用mp4插件进行编译)。
我可以问一下你的出口,看看这个nginx反向代理和静态资产服务器的Rails 3.1后端预编译资产? 我本来希望所有的文件都能够被压缩,但是没有一个是通过这种方式来的。 nginx.conf: worker_processes 1; events { worker_connections 1024; } http { include mime.types; keepalive_timeout 65; include /usr/local/nginx/conf/sites-enabled/*; } / site.conf启用站点-; ssl_certificate /usr/local/nginx/conf/certs/site.com.crt; ssl_certificate_key /usr/local/nginx/conf/certs/site.com.key; server { listen 443 ssl; listen 80; server_name staging.site.com; gzip on; gzip_types text/plain text/css application/x-javascript image/png image/jpeg; location /assets { root /home/site/www/staging.site.com/current/public; expires 15d; } location / { proxy_pass […]